From patchwork Tue Jul 3 13:04:09 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 140960 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp1199914ljj; Tue, 3 Jul 2018 06:59:38 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcx78kJ6UmRYwhTfg9PsNTf4hCrG0dPG6IkOrVX7sVsqXkeOyRxxRNGsUtVN6nyxYWpyJgz X-Received: by 2002:a63:ec14:: with SMTP id j20-v6mr7505777pgh.28.1530626377912; Tue, 03 Jul 2018 06:59:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530626377; cv=none; d=google.com; s=arc-20160816; b=jbZx2svGiXSwy6bPJYS03zc+LUJtpSP6sbOYb7nlhnThwScCrWlxISZYWpOovrbblH ar068bCvVAbzU408d0V9ZPR+p8B18Vo/Lt865NPvTgnKd8/9z2myqjjhgY5Em3L+ueon 2CWVJE7NBZyc9cQvgL6rQgsBRQer7sA0F0/e9SA8lan5eB0agDekS0aK0S9kyOKY4QUY aYjnA0BkPjrTOQWZxrOwcjSnRghEzy/hwmlVlCIryCV6FnUU+R00KTAL79S7rUzhIU5B h6MziiQi9gJ3wvHFU2eCNONL/+Jhxj+fq5V1KNUKiCyEKjkXLILoIY379DAF+arQBRXL fL7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:dkim-signature :delivered-to:arc-authentication-results; bh=JhNKOlsAxnuv7Q6qkRA05Pq9bXYormYf/OmKt7YS6MA=; b=cYx8oX+Ir/thMoynoDqzUTcp/Y4Hu5hZz54L7l8ehDk6V8EJYlPBWR/aSfBBNPNrMh 8rn6APC4Kpf8Cz8eI2cA5sbdGfz3NyHZj8jjRqw2IhIMVJb2+w2dEN0dg1vaXmAaRdXZ U04EY66RoFWeEFfN4n+f7kt0/drJsyzuFzqWXF7AndOnNNDc5edEyFEZiM47pO6YhgiP uGpe3NE3U+ILeIfOfo1I/i/wa/sOBgMy+3aq6a9coDDKVrHihJWOsY3Jj2jO+yzYh0pr FmKCehcfMlVF4Uziv3U741yU3oqOA75tTqzYX88M3Ct1ZpY7KoLGxSvzmNFWDEx9dixX grMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=woMNV01a; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id n3-v6si1230853pld.146.2018.07.03.06.59.37; Tue, 03 Jul 2018 06:59:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=woMNV01a; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 31B32789F4; Tue, 3 Jul 2018 13:59:34 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by mail.openembedded.org (Postfix) with ESMTP id 6C9937889F for ; Tue, 3 Jul 2018 13:04:17 +0000 (UTC) Received: by mail-wm0-f66.google.com with SMTP id 69-v6so2190681wmf.3 for ; Tue, 03 Jul 2018 06:04:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id; bh=qR81l8ZnEmAHZVFcVmlJmvsgOjk/1pg1H6lIYyH7SJg=; b=woMNV01abe172L9UslsOr5kVUncGmDoQYTb7SyqU70uF7NyaojsaWxIAntGGnj0dKA Fd0GXZkVeOA3p9XRJltbVX3Xf7N3x+fxWnQwVmsXOG92PTLb3mnrqV5QIyFvFCRRd/b9 V6Gqtxntydx9/uxOvT945/E64b/AUnEVdqeIJKv6V7Qw1bj26lkJ/Zmu5zYexGNeDVTv qi+ARbZpe505fz0FAHtxxat8cWHEN4DIe8noRs5raHo1gWV4rLGecu/nN/PcDX3AJGSO I4ySx7HvZ59XNUw75N9oaM/o3LjxjXLkWN3be/Rx6KI3yzIY3rnoNmyp3vpnfceEP9Ds cGxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=qR81l8ZnEmAHZVFcVmlJmvsgOjk/1pg1H6lIYyH7SJg=; b=AOA7ztTBsvXtoVrUxAv1NIhEAbc+DoAthH8sYJu0eWdjv5Gqq2Tg9iiyf2SjW/B6Ht M/sLBQhO80WFJB03KjdkhO7qfSBoVfoPp9G1EBchylJnATkUpIARI0xDa0vzzuU6bmFA 9iUevClshfhwkyUhYBf7y2lUYx1JFCjCrE43unyLN5nbacMFlUr59UeNHeC5avBKuuCW azD6LmtEBq+DXT88SPGEQ//Zdz4tnAnX8y6qTKupwZaETXkDPULg4YXbbwKpOHiZbxXL g+VpjMarpIRXbs9Q4pK/DGxi+KgONeFk5X+nX59+vn/Tbmd8+DSNj5/igArG8gbAUYNs Ra5g== X-Gm-Message-State: APt69E1xkAmSs0Q2v/esFa72SrvMGzDS77tN6eHXBFGYHIsF0Wgit9TR dYiKSP/Oa5B2mo/Lp9WU6CgScJI3 X-Received: by 2002:a1c:9350:: with SMTP id v77-v6mr11175799wmd.146.1530623057723; Tue, 03 Jul 2018 06:04:17 -0700 (PDT) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id j9-v6sm1863006wrr.52.2018.07.03.06.04.16 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Jul 2018 06:04:16 -0700 (PDT) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Tue, 3 Jul 2018 14:04:09 +0100 Message-Id: <20180703130412.26102-1-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 Subject: [OE-core] [PATCH 1/4] meson: various class improvements X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org - Ensure that the PACKAGECONFIG arguments are always in EXTRA_OEMESON - Log the arguments that are being passed in do_configure. - Do verbose builds so the compile logs are useful for debugging build problems Signed-off-by: Ross Burton --- meta/classes/meson.bbclass | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/classes/meson.bbclass b/meta/classes/meson.bbclass index e572344bd20..c36b634b43d 100644 --- a/meta/classes/meson.bbclass +++ b/meta/classes/meson.bbclass @@ -35,7 +35,7 @@ MESON_LINK_ARGS = "${MESON_TOOLCHAIN_ARGS} ${LDFLAGS}" MESON_HOST_ENDIAN = "bogus-endian" MESON_TARGET_ENDIAN = "bogus-endian" -EXTRA_OEMESON += "${PACKAGECONFIG_CONFARGS}" +EXTRA_OEMESON_append = " ${PACKAGECONFIG_CONFARGS}" MESON_CROSS_FILE = "" MESON_CROSS_FILE_class-target = "--cross-file ${WORKDIR}/meson.cross" @@ -85,6 +85,7 @@ EOF CONFIGURE_FILES = "meson.build" meson_do_configure() { + bbnote Executing meson ${EXTRA_OEMESON}... if ! meson ${MESONOPTS} "${MESON_SOURCEPATH}" "${B}" ${MESON_CROSS_FILE} ${EXTRA_OEMESON}; then cat ${B}/meson-logs/meson-log.txt bbfatal_log meson failed @@ -118,11 +119,11 @@ meson_do_configure_prepend_class-native() { do_compile[progress] = "outof:^\[(\d+)/(\d+)\]\s+" meson_do_compile() { - ninja ${PARALLEL_MAKE} + ninja -v ${PARALLEL_MAKE} } meson_do_install() { - DESTDIR='${D}' ninja ${PARALLEL_MAKEINST} install + DESTDIR='${D}' ninja -v ${PARALLEL_MAKEINST} install } EXPORT_FUNCTIONS do_configure do_compile do_install From patchwork Tue Jul 3 13:04:10 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 140961 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp1202024ljj; Tue, 3 Jul 2018 07:01:01 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfYPFEhBW9moz+w+aNPTxy821hz6HvR5o2bySbcYRmKHAe5KJt98yD8s5RnQT5EIjU0q16I X-Received: by 2002:a17:902:18a:: with SMTP id b10-v6mr18683977plb.62.1530626461186; Tue, 03 Jul 2018 07:01:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530626461; cv=none; d=google.com; s=arc-20160816; b=HeBxYwtnkF85vcnLhXZLFM+NPSt9W3p4uoGGjuSjPU2CEPxMfeXXWLqgEWAVZ62vCL JqrJZfk9KtjdBTH9NOj02jgktDywtSv2faR9INpf3RLBWhS9fpOgK+QMeK77qYeT6urT PdinkhBN/5HIUYoTbhpM3hjQOfIVyZ8G1B0lxVe73cpJ4tyRRYeFWW8JK9gM0iy69xuG u7oLq3YcbdlmNJt1c7JZSPrbzg7aWQ4l8CffBJtRV2gfMr0ota3tYAkKLvy8t2hu7/jP VNLwoe78HHg0GPxHAI3ybyD1TrRvNuRs4sYxZfi6g5MP4PWc7MdewEofDL2089gjZKLo LHUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to:arc-authentication-results; bh=6KCFpeZlSXfw35OIkNWVqwRJshTiARnTzjp8w4V4zUA=; b=QIWgtTuaK+GGh/4wtDq8rYkeHWVs4BBnvb95D40K2NL6jrMZep9vs7Jle2tBxNgYzI oBpykeGch8Wxd91I5nU3/Mv28+0MnwWyqs07HdIFgQcfRbdZQ2pUIJlEdTN4dzryNXRE 0/0Jh5oih2ohrE0LT6c1wzuIks7/FcO6RE1rrtdlKhJqdYO24lgpZMjpmFTjyvcz+G82 zJz3v6q/zRYv/dKekFoymcEXUrH/GhrIYIjzvMrlQRVSwkliYnlX7o0RXe0z0ZDdwB7o X9oD1QPgmRRlym7Fd7ZdxkJpSFBuwG6DOGKfu1F97Ys/V2RLWnrtaXJ6yoiI4aEwksfx aNuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=IJaM9GNf; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id bb12-v6si1102473plb.328.2018.07.03.07.01.00; Tue, 03 Jul 2018 07:01:01 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=IJaM9GNf; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 754E578B03; Tue, 3 Jul 2018 14:00:58 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm0-f52.google.com (mail-wm0-f52.google.com [74.125.82.52]) by mail.openembedded.org (Postfix) with ESMTP id 95F327889F for ; Tue, 3 Jul 2018 13:04:18 +0000 (UTC) Received: by mail-wm0-f52.google.com with SMTP id n17-v6so2212423wmh.2 for ; Tue, 03 Jul 2018 06:04:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references; bh=KmuSQY2Muzs1YcL0rmDm3MqbS00CZ0FRGQ4KqrDwpq4=; b=IJaM9GNfNmXlppgL8d3Am4wEziKF41zYogA2h8bOsXU83AwWQvry5W5H1sGVAf86yY mbpp7dBCQHa6lPe5lrTDkYtod9tM2DCk0yjyL3TtzVEDY3Rq60qzuRg6WqpUuvrNhEEs nWXA6H6cVspckgXTVc4WAgL0VqHJfRWSfA85OrDcXy2nvD7I78WGHBdslGpCR7stQZ4B 2brdlJrjzu/20w4KElbHIDs2j3uBqBnMKMsME+chbegYNUFd2idtv5bEyjPLrs4jgLgG ae3qDlE5ktqu667tB0ndqH9kGlRqTZaPb0VeOAHsoPyA/2ONkxlMXtNbW0EgaMZLyfBq BzPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=KmuSQY2Muzs1YcL0rmDm3MqbS00CZ0FRGQ4KqrDwpq4=; b=ZVaGlx3bVh0cX39fdd87bYgvMyraYdN1zKBY0HAKW4IWdgayzNebNsM24IpNzKRgZJ rLc+DhpUhMmJtvpjJKCHNOB7hKjvf8Epb6RwMvuxn+z85dxRVVmRUsVqCKIpzAgVNhCI WZC8v9Yf6X+LMzYscqivt83Q+t7W/RFT00jInSIQOjrgE++w2uC77Q1LMSJLFJvxtLhJ T+5JPD8+HbKAGIYEfSRweS8c1qcyzG15p/9zXepUoKcntLgDaEBZjZBnlEZIJnmUVhLD jpQ3Rh+wAESf1feJh9U7xDfA+l3eqR9tjnoxMrtgL8mLgINkKcbc+z0tnUsXUk4gzzwq Z/ow== X-Gm-Message-State: APt69E3FSoRut9EWEOkVQUEUfS1Ozbuv/BJuqTkL2go4/N0mfsRXbGGm yBsq7NZv3cYqw2kH6NDfnl2kC9P3 X-Received: by 2002:a1c:69c6:: with SMTP id z67-v6mr8444194wmh.159.1530623058994; Tue, 03 Jul 2018 06:04:18 -0700 (PDT) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id j9-v6sm1863006wrr.52.2018.07.03.06.04.17 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Jul 2018 06:04:18 -0700 (PDT) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Tue, 3 Jul 2018 14:04:10 +0100 Message-Id: <20180703130412.26102-2-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180703130412.26102-1-ross.burton@intel.com> References: <20180703130412.26102-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 2/4] meson: map architecture to correct values in cross file X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org The cross file specifies the host/target cpu_family, which should be one of a defined set of values[1] but if it isn't Meson won't complain and instead recipes may behave unexpectedly. [1] http://mesonbuild.com/Reference-tables.html#cpu-families Signed-off-by: Ross Burton --- meta/classes/meson.bbclass | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/classes/meson.bbclass b/meta/classes/meson.bbclass index c36b634b43d..d615a84cfb0 100644 --- a/meta/classes/meson.bbclass +++ b/meta/classes/meson.bbclass @@ -45,6 +45,18 @@ def meson_array(var, d): items = d.getVar(var).split() return repr(items[0] if len(items) == 1 else items) +# Map our ARCH values to what Meson expects: +# http://mesonbuild.com/Reference-tables.html#cpu-families +def meson_cpu_family(var, d): + import re + arch = d.getVar(var) + if arch == 'powerpc': + return 'ppc' + elif re.match(r"i[3-6]86", arch): + return "x86" + else: + return arch + addtask write_config before do_configure do_write_config[vardeps] += "MESON_C_ARGS MESON_CPP_ARGS MESON_LINK_ARGS CC CXX LD AR NM STRIP READELF" do_write_config() { @@ -70,13 +82,13 @@ gtkdoc_exe_wrapper = '${B}/gtkdoc-qemuwrapper' [host_machine] system = '${HOST_OS}' -cpu_family = '${HOST_ARCH}' +cpu_family = '${@meson_cpu_family('HOST_ARCH', d)}' cpu = '${HOST_ARCH}' endian = '${MESON_HOST_ENDIAN}' [target_machine] system = '${TARGET_OS}' -cpu_family = '${TARGET_ARCH}' +cpu_family = '${@meson_cpu_family('TARGET_ARCH', d)}' cpu = '${TARGET_ARCH}' endian = '${MESON_TARGET_ENDIAN}' EOF From patchwork Tue Jul 3 13:04:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 140962 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp1204094ljj; Tue, 3 Jul 2018 07:02:15 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcNP1Qm8scxeZquS78R3jcXswseSHqRuweG+P6croX91YkkmW50OwlB9viKRGh/9WPiwDob X-Received: by 2002:a17:902:b581:: with SMTP id a1-v6mr5847967pls.338.1530626535845; Tue, 03 Jul 2018 07:02:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530626535; cv=none; d=google.com; s=arc-20160816; b=pTk+wN0xSGmfHKxQUmqXHbrVnkn176D84VzCVBsgflkbiCB8MrY1lQELGGZyH5wGdU 97rEJ2HB5OsxpYYPectKUH47o2stlTLcEjx6jooCxIdFQhoFSCt7xGXunsb3hWxGiiPc TWk5M7El1LubpA7x+SKR+OdhPa29MZL2vP+X5CUbMRAg8gjbZYpFKvdfjggIR5lccuOg 4pbFAKKeDpM8w+VMYhMzaQfzy/RxBrRO0Pf3pctKYF8rgdOgRvRvob9EnQ3APcT+MTkL HGVe0Uw3B+YbNFSYP1wlb1mSt4GYFP7Y6/Mp6MMtqaZWdiWQR8a6mhwOuG5Ya+iVjIkD JqFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to:arc-authentication-results; bh=FEIZOzkRSu31nJ51EuRDc/pSsabVJxGwCj59r4mAxjE=; b=ygN+SVbe3bFYUnsD6XC6JytzCbcTnMxSF04swa5Xs/9UJ+pI0YukGOpNMNdvj4XkDh Q5vNuG/kiSJtEQ5MZo7sE6l0JjtZ3Zc+nbRV4RDpA4hh6lyKHpeGe41TsQH5kM4NwkiD PW9qVMjcrpXm8rDZtqL4SGepgHnm73AU6Hr7NKntCaZfKYO2vfO0SjIomuhR/Wry3qVm syI4xTGYN3+ZJM08hAXOBRmtlouQ5ZF05Pi/+VETx4I9n0ahcq6cT0vWhChUJTK8QdOi Hdwg6RTECtrRhlcYM+HTuJ7I1yJUjBCyLuMgnJySVyQmqbX8VTb1OMiH8gwogvR+XWR3 hkEA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=LBmP0MHa; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id t8-v6si1243468pfi.221.2018.07.03.07.02.15; Tue, 03 Jul 2018 07:02:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=LBmP0MHa; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 318B278B03; Tue, 3 Jul 2018 14:02:12 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm0-f51.google.com (mail-wm0-f51.google.com [74.125.82.51]) by mail.openembedded.org (Postfix) with ESMTP id ECA2A7889F for ; Tue, 3 Jul 2018 13:04:19 +0000 (UTC) Received: by mail-wm0-f51.google.com with SMTP id w16-v6so2262049wmc.2 for ; Tue, 03 Jul 2018 06:04:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references; bh=Tvimj9c2h3ghRXeh8Oqtv+6VJsSZ6/qyEA9I/fj9ieg=; b=LBmP0MHaJ9KVgC9BLEhy3QECgqLMG+7bMs7duNwRN9j3K17CYLOt7PvNDlNzZvlemz gMoHNRjh3Zi6aiZNx2hBhgSbMD1wPbIz6RDTnHJnfjAw0olAANFE1i4BDTyPcLmTpKtl gn94sOQFkGA3ryEmx4sWI4BEQ+lp46sHS+wXbvExbbIRrCmKymDM3FRwK1CUpeeEONym jSU1SDFkOmwT1LBgcQpq7nif6GtrTcCxaqQBtggyAwF9xe/527rnfx+axNxXhP4EAU3n gOXNLSfDkwZHusTpWX8/Vij+gi9rInbzsQ6qJFLqZlpVynd6G2MC6Y45Sfu6/AS3Rzjj veRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=Tvimj9c2h3ghRXeh8Oqtv+6VJsSZ6/qyEA9I/fj9ieg=; b=S7dpamozeMPAGidAQZXCxk+FpuyGQ1tUB8urJbpONNP4WFZyULoyun2MT8ByjaKEeJ Ji8RmUI190EWdFTT13Fu/eellD9bROoI8/jABdWE9Cu05SBb5mf0vve9BR6U7ZD9bILV /ZYmjUCdMcD6LKc32+rg6sJ8QnYCSMEsoTpHw0gY0Hi7ScNaEFNdKW6W5S8bUY675+A5 5G2SalcBLqvDaVAraVcZqNQXE6LVGltA+hj50chNYZF1jyaY1MoY4AUAFOEnHO0qTa9Q ejypDiU0k/1/8sHnGRTkoyi1CyF5vAab9D9uPCGvgvC5EwyNdjeElSTUZTn71u55ZZep QWfw== X-Gm-Message-State: APt69E0KZaatwPosQ7JPEesq1Fp2zBoV8ouOVV2nVAua5SalHQR/n6JF 3nRDEurgdydZ1l3nEMsGar8Dy4zt X-Received: by 2002:a1c:cf81:: with SMTP id f123-v6mr10545585wmg.83.1530623060239; Tue, 03 Jul 2018 06:04:20 -0700 (PDT) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id j9-v6sm1863006wrr.52.2018.07.03.06.04.19 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Jul 2018 06:04:19 -0700 (PDT) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Tue, 3 Jul 2018 14:04:11 +0100 Message-Id: <20180703130412.26102-3-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180703130412.26102-1-ross.burton@intel.com> References: <20180703130412.26102-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 3/4] meson: validate cpu_family X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Meson has a defined list of known CPU families but these are not currently validated, so mistakes in cross files or new architectures are not noticed. Backport a patch from upstream which warns on unknown architectures, but tweak it to fatally error instead. When we upgrade to Meson 0.47 the first half of this patch can be dropped. Signed-off-by: Ross Burton --- meta/recipes-devtools/meson/meson.inc | 1 + .../meson/meson/validate-cpu.patch | 118 +++++++++++++++++++++ 2 files changed, 119 insertions(+) create mode 100644 meta/recipes-devtools/meson/meson/validate-cpu.patch -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-devtools/meson/meson.inc b/meta/recipes-devtools/meson/meson.inc index 4c113dcaf73..b278d33b72e 100644 --- a/meta/recipes-devtools/meson/meson.inc +++ b/meta/recipes-devtools/meson/meson.inc @@ -11,6 +11,7 @@ SRC_URI = "https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${P file://0003-native_bindir.patch \ file://0004-Prettifying-some-output-with-pathlib.patch \ file://0005-Set-the-meson-command-to-use-when-we-know-what-it-is.patch \ + file://validate-cpu.patch \ " SRC_URI[md5sum] = "1698f6526574839de5dcdc45e3f7d582" diff --git a/meta/recipes-devtools/meson/meson/validate-cpu.patch b/meta/recipes-devtools/meson/meson/validate-cpu.patch new file mode 100644 index 00000000000..8bdb204ab04 --- /dev/null +++ b/meta/recipes-devtools/meson/meson/validate-cpu.patch @@ -0,0 +1,118 @@ +Validate the passed CPU family (US: backport) and turn the upstream warning to +an error (US: inappropriate). + +Upstream-Status: Backport +Signed-off-by: Ross Burton + +From 456f7ea48503731d50a2b7287a0f198b73b4fe61 Mon Sep 17 00:00:00 2001 +From: Ross Burton +Date: Wed, 20 Jun 2018 13:45:44 +0100 +Subject: [PATCH 1/2] Validate cpu_family (#3753) + +* environment: validate cpu_family in cross file + +* run_unittests: add unittest to ensure CPU family list in docs and environment matches + +* run_unittests: skip compiler options test if not in a git repository + +* environment: validate the detected cpu_family + +* docs: add 32-bit PowerPC and 32/64-bit MIPS to CPU Families table + +Names gathered by booting Linux in Qemu and running: + +$ python3 +import platform; platform.machine() + +Partial fix for #3751 +--- + mesonbuild/environment.py | 24 ++++++++++++++++++++++++ + 1 file changed, 24 insertions(+) + +diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py +index 6920b8d6..091d92dc 100644 +--- a/mesonbuild/environment.py ++++ b/mesonbuild/environment.py +@@ -72,6 +72,22 @@ from .compilers import ( + + build_filename = 'meson.build' + ++known_cpu_families = ( ++ 'aarch64', ++ 'arm', ++ 'e2k', ++ 'ia64', ++ 'mips', ++ 'mips64', ++ 'parisc', ++ 'ppc', ++ 'ppc64', ++ 'ppc64le', ++ 'sparc64', ++ 'x86', ++ 'x86_64' ++) ++ + # Environment variables that each lang uses. + cflags_mapping = {'c': 'CFLAGS', + 'cpp': 'CXXFLAGS', +@@ -210,6 +226,10 @@ def detect_cpu_family(compilers): + pass + return 'x86_64' + # Add fixes here as bugs are reported. ++ ++ if trial not in known_cpu_families: ++ mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % trial) ++ + return trial + + def detect_cpu(compilers): +@@ -1021,6 +1041,10 @@ class CrossBuildInfo: + res = eval(value, {'__builtins__': None}, {'true': True, 'false': False}) + except Exception: + raise EnvironmentException('Malformed value in cross file variable %s.' % entry) ++ ++ if entry == 'cpu_family' and res not in known_cpu_families: ++ mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % value) ++ + if self.ok_type(res): + self.config[s][entry] = res + elif isinstance(res, list): +-- +2.11.0 + + +From 202e0199d3ffd2637f4dbee08f8351520f7dde3b Mon Sep 17 00:00:00 2001 +From: Ross Burton +Date: Tue, 3 Jul 2018 13:59:09 +0100 +Subject: [PATCH 2/2] Make CPU family warnings fatal + +--- + mesonbuild/environment.py | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py +index 091d92dc..67177c1f 100644 +--- a/mesonbuild/environment.py ++++ b/mesonbuild/environment.py +@@ -228,7 +228,7 @@ def detect_cpu_family(compilers): + # Add fixes here as bugs are reported. + + if trial not in known_cpu_families: +- mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % trial) ++ raise EnvironmentException('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % trial) + + return trial + +@@ -1043,7 +1043,7 @@ class CrossBuildInfo: + raise EnvironmentException('Malformed value in cross file variable %s.' % entry) + + if entry == 'cpu_family' and res not in known_cpu_families: +- mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % value) ++ raise EnvironmentException('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % value) + + if self.ok_type(res): + self.config[s][entry] = res +-- +2.11.0 + From patchwork Tue Jul 3 13:04:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 140963 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp1206047ljj; Tue, 3 Jul 2018 07:03:28 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLprLsMIA7mkO7BwNM14NgqO3gWqwaB88H4hUZMN76ZfTQIedvd288LeN+8WYGshO3maplJ X-Received: by 2002:a17:902:581:: with SMTP id f1-v6mr30094453plf.48.1530626608636; Tue, 03 Jul 2018 07:03:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530626608; cv=none; d=google.com; s=arc-20160816; b=ni2+t6u1tD0Zc3Csc1/iBmAHhK9TmFkhA0dfPerbf4HRvYP7VdN0bFF4iRNtr9Ju3N LXLk1JNBzBKXPcPK96mb5jsMKqEfIKlXlJ1afh4Urdvu6ISFzstAhQiAas8qLHhhD2jK AS3M4GjhxoQPRMq8zViWTu9Uc6IWjOMVaXS66Uzf5CF9E+e1QQYFWC/3rsE+flJpUGFZ 6/cwtEZbaxIhHaOIZ5DosI/T8NcUV5Scte+ODyO4itx/YyB5yb6jW9KDWDr7WtrleGLy DzDRWnahSUSRAi+h3Q87kgaM+Wr5Qyakpp9kALpOUPtAoDsliruBfs0u613/ppfHf6kv OJeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to:arc-authentication-results; bh=Plu2bnh9J4h67YL7AUOJKqXs0PN3z0MJssgH4Jvp2FQ=; b=zDPAbjMgCE293dCDCtbu8oiNCcWm+9dzyiYu6yMsukKmsAfzGBj7eR8op0e9Xc4GUu toQVjUD11rcM/o7LdV9pN+u4d+q3dDiBzIh7lIriDqQ0rjjrVyXCk4NHKTQdjb6amZLn fW72358UM3s4g2Vu3kkQAc2WH/LzWTBR6XmOwCbSnR4BIuGPmseiGYjDZK8z88NQpOhL K+TjMtsCo1AaZAaR8mPoek8rGgF9mdwQOIk9VmahcoSV1/XV3g+b8fMs0tcJ5HKpHmnp LzHuuU7VBjpNPrOXOLqTGZsOEIvqmQ9bT1Ci6uvGKBR4IUJ/qpl1IlmfvrxibsuaEyY6 dMEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Vo4COn5d; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id x15-v6si1239191pfk.25.2018.07.03.07.03.28; Tue, 03 Jul 2018 07:03:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=Vo4COn5d; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 7132478B04; Tue, 3 Jul 2018 14:03:25 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47]) by mail.openembedded.org (Postfix) with ESMTP id 6DA8D78AD3 for ; Tue, 3 Jul 2018 13:04:21 +0000 (UTC) Received: by mail-wm0-f47.google.com with SMTP id w16-v6so2262139wmc.2 for ; Tue, 03 Jul 2018 06:04:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references; bh=eJLzobHC50kHb1qGvs8laHYwb3xnhZq58U9uOUlDQAk=; b=Vo4COn5d7HP952sLjZvKLR5MZ+4JujMQ1QvWyXYEX53t7UWo0MVFI+7mwsoVJj3VuN JTmGvbzszcJ+auvGwAQ40JcaNyv+1c/sbgRrPyTAyceXR9L78g8cn5rn6SpNcjHg7BoL NjOAAzOWn9G4oySqOairBqsEY+cH5ZmiWp63Q8MAy5vPQyyBMPkaViEVdNC5gtgPWm3x oGP+Gk2pjYCqL3ontFmpl9H2QPjrV57aiEOSiW1tLjx6a77fCsyAiSUOHOwPOYIico5g XG8dLRJJufY1tZzova1r1WAhu1TR6cY6kYxuus99FAoP5vVOOz11CV/VaPlXHRrxwdfL J3pA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=eJLzobHC50kHb1qGvs8laHYwb3xnhZq58U9uOUlDQAk=; b=DVXzyHRfLmkgVIX2F440M1FAN4J0bPRBRVYJKkh/BNpSegRLazy/0W06/fmH5cg48S 8HkKrnwAH/KOCK8nj/x1GFHeFQ7OBTf9NfNc+d7lLKzXS3VZH0459gVDn8gXv4wdv/OE n2YismDqsEdkHF1W2ALs0fFmafGe8BscQqOmOzEll8UYDT1dPghSD0k73R6T2eN17Xof EDLbd37cDfRh810JuN/n5nWVhFhlu+Xt1IgMw2H1DxJImJ7ic4p4f73/FILmdlynBN2Y knArUaCdjMJDZPx7V9AioFjXjNb+dlIYaJkeL4rlIO/K1ddOMHN5ogy1KEE/dJoLeIWE G3BA== X-Gm-Message-State: APt69E2HobA3PtukpTdIb92BrwOqgL6JTa6BjVw9aeDHx+1F4LEgozzD F6ZEoPxuKp3BFA1IWXhOWW4jSg3l X-Received: by 2002:a1c:f009:: with SMTP id a9-v6mr11231819wmb.104.1530623061689; Tue, 03 Jul 2018 06:04:21 -0700 (PDT) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id j9-v6sm1863006wrr.52.2018.07.03.06.04.20 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Jul 2018 06:04:20 -0700 (PDT) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Tue, 3 Jul 2018 14:04:12 +0100 Message-Id: <20180703130412.26102-4-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180703130412.26102-1-ross.burton@intel.com> References: <20180703130412.26102-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 4/4] libdrm: port to Meson X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Drop the patch to install tests as the Meson build allows this. Drop the patch to disable cunit as this predates recipe-specific-sysroots and isn't required anymore. As Meson always builds the test suite (instead of building before running it), add a patch to fix compilation with musl. Signed-off-by: Ross Burton --- ...ac-Allow-explicit-enabling-of-cunit-tests.patch | 53 ---------------------- .../recipes-graphics/drm/libdrm/installtests.patch | 25 ---------- meta/recipes-graphics/drm/libdrm/musl-ioctl.patch | 35 ++++++++++++++ meta/recipes-graphics/drm/libdrm_2.4.92.bb | 22 ++++----- 4 files changed, 44 insertions(+), 91 deletions(-) delete mode 100644 meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch delete mode 100644 meta/recipes-graphics/drm/libdrm/installtests.patch create mode 100644 meta/recipes-graphics/drm/libdrm/musl-ioctl.patch -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch b/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch deleted file mode 100644 index 40bebc0f50c..00000000000 --- a/meta/recipes-graphics/drm/libdrm/0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch +++ /dev/null @@ -1,53 +0,0 @@ -From e6bd4205b0b546afe991ae6f72256645f4404ad4 Mon Sep 17 00:00:00 2001 -From: Jussi Kukkonen -Date: Mon, 5 Sep 2016 14:41:37 +0300 -Subject: [PATCH libdrm] configure.ac: Allow explicit enabling of cunit tests - -Add --with-cunit to make it easier to do reproducible builds. Default -is still to probe cunit and build opportunistically. - -Signed-off-by: Jussi Kukkonen -Upstream-Status: Submitted [mailing list] ---- - configure.ac | 14 ++++++++++++-- - 1 file changed, 12 insertions(+), 2 deletions(-) - -Index: libdrm-2.4.91/configure.ac -=================================================================== ---- libdrm-2.4.91.orig/configure.ac -+++ libdrm-2.4.91/configure.ac -@@ -163,6 +163,12 @@ AC_ARG_ENABLE(install-test-programs, - [Install test programs (default: no)]), - [INSTALL_TESTS=$enableval], [INSTALL_TESTS=no]) - -+AC_ARG_WITH([cunit], -+ [AS_HELP_STRING([--with-cunit], -+ [Build tests that use cunit (default: auto)])], -+ [], -+ [with_cunit=auto]) -+ - dnl =========================================================================== - dnl check compiler flags - AC_DEFUN([LIBDRM_CC_TRY_FLAG], [ -@@ -411,7 +417,7 @@ else - AC_DEFINE(HAVE_RADEON, 0) - fi - --if test "x$AMDGPU" != xno; then -+if test "x$with_cunit" != xno -a "x$AMDGPU" != xno; then - # Detect cunit library - PKG_CHECK_MODULES([CUNIT], [cunit >= 2.1], [have_cunit=yes], [have_cunit=no]) - # If pkg-config does not find cunit, check it using AC_CHECK_LIB. We -@@ -436,7 +442,11 @@ if test "x$AMDGPU" = xyes; then - AC_DEFINE(HAVE_AMDGPU, 1, [Have amdgpu support]) - - if test "x$have_cunit" = "xno"; then -- AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests]) -+ if test "x$with_cunit" = "xyes"; then -+ AC_MSG_ERROR([Could not find cunit library but --with-cunit was given]) -+ elif test "x$with_cunit" = "xauto"; then -+ AC_MSG_WARN([Could not find cunit library. Disabling amdgpu tests]) -+ fi - fi - else - AC_DEFINE(HAVE_AMDGPU, 0) diff --git a/meta/recipes-graphics/drm/libdrm/installtests.patch b/meta/recipes-graphics/drm/libdrm/installtests.patch deleted file mode 100644 index ec1fb0236e4..00000000000 --- a/meta/recipes-graphics/drm/libdrm/installtests.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 5c6eb43c2f6e7f2ee7c25c92e42f4e4403fa0527 Mon Sep 17 00:00:00 2001 -From: Jussi Kukkonen -Date: Tue, 21 Feb 2017 14:37:52 +0200 -Subject: [PATCH] tests: also install test apps - -Upstream-Status: Inappropriate [configuration] - -Signed-off-by: Yu Ke -Signed-off-by: Jussi Kukkonen ---- - tests/Makefile.am | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/tests/Makefile.am b/tests/Makefile.am -index 0355a92..b4882cd 100644 ---- a/tests/Makefile.am -+++ b/tests/Makefile.am -@@ -45,3 +45,4 @@ TESTS = \ - check_PROGRAMS = \ - $(TESTS) \ - drmdevice -+bin_PROGRAMS = $(check_PROGRAMS) --- -2.1.4 - diff --git a/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch b/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch new file mode 100644 index 00000000000..e3d6c5b8537 --- /dev/null +++ b/meta/recipes-graphics/drm/libdrm/musl-ioctl.patch @@ -0,0 +1,35 @@ +Upstream-Status: Submitted +Signed-off-by: Ross Burton + +From 46c0fd6c827a8cb4d04e067bf04fab579ac4712e Mon Sep 17 00:00:00 2001 +From: Ross Burton +Date: Mon, 18 Jun 2018 15:07:03 +0100 +Subject: [PATCH] tests/nouveau/threaded: adapt ioctl signature + +POSIX says ioctl() has the signature (int, int, ...) but glibc has decided to +use (int, unsigned long int, ...) instead. + +Use a #ifdef to adapt the replacement function as appropriate. +--- + tests/nouveau/threaded.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/tests/nouveau/threaded.c b/tests/nouveau/threaded.c +index 3669bcd3..e1c27c01 100644 +--- a/tests/nouveau/threaded.c ++++ b/tests/nouveau/threaded.c +@@ -36,7 +36,11 @@ static int failed; + + static int import_fd; + ++#ifdef __GLIBC__ + int ioctl(int fd, unsigned long request, ...) ++#else ++int ioctl(int fd, int request, ...) ++#endif + { + va_list va; + int ret; +-- +2.11.0 + diff --git a/meta/recipes-graphics/drm/libdrm_2.4.92.bb b/meta/recipes-graphics/drm/libdrm_2.4.92.bb index 2b3bf4f83d2..347090cd5f2 100644 --- a/meta/recipes-graphics/drm/libdrm_2.4.92.bb +++ b/meta/recipes-graphics/drm/libdrm_2.4.92.bb @@ -11,23 +11,19 @@ PROVIDES = "drm" DEPENDS = "libpthread-stubs libpciaccess" SRC_URI = "http://dri.freedesktop.org/libdrm/${BP}.tar.bz2 \ - file://installtests.patch \ - file://0001-configure.ac-Allow-explicit-enabling-of-cunit-tests.patch \ - " - + file://musl-ioctl.patch" SRC_URI[md5sum] = "f9b00d985f82d0be6ecc20c799acc89e" SRC_URI[sha256sum] = "e9e48fdb4de139dc4d9880aa1473158a16ff6aff63d14341367bd30a51ff39fa" -inherit autotools pkgconfig manpages +inherit meson pkgconfig manpages + +EXTRA_OEMESON = "-Dvalgrind=false \ + -Dcairo-tests=false \ + -Dinstall-test-programs=true \ + -Domap=true \ + -Detnaviv=true" -EXTRA_OECONF += "--disable-cairo-tests \ - --without-cunit \ - --enable-omap-experimental-api \ - --enable-etnaviv-experimental-api \ - --enable-install-test-programs \ - --disable-valgrind \ - " -PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native" +PACKAGECONFIG[manpages] = "-Dman-pages=true,-Dman-pages=false,libxslt-native xmlto-native" ALLOW_EMPTY_${PN}-drivers = "1" PACKAGES =+ "${PN}-tests ${PN}-drivers ${PN}-radeon ${PN}-nouveau ${PN}-omap \