From patchwork Mon Jan 7 16:38:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154911 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674253ljp; Mon, 7 Jan 2019 08:38:40 -0800 (PST) X-Google-Smtp-Source: AFSGD/Vxh+dj2lkktD2sY0oqB2jomSPcTFsDnMejGj7Y0P5H8QDZPLHwtd6YrmuZA6y/B079JIw4 X-Received: by 2002:a62:1f53:: with SMTP id f80mr63586094pff.92.1546879120285; Mon, 07 Jan 2019 08:38:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879120; cv=none; d=google.com; s=arc-20160816; b=u4C1C0iQKmzEv1bMbyQgnfZcxAH/ZnMc9fyiDBnXsFWzhowJg4oJVxVw8d2t5nHg45 UIk853G2Ixjr/NOixZ3kYvkbzh0jdwwE99vpUbrJaGRy6tw+3JI040W3ESIbsgijqmNC 1ZidqQiEjdruYQvMnhlHAqdWFl3txUsVRyv7KbMN2SPNjHZMasfGxaZsH9YzXUrzJK/d VVJTArSJwQzj9DZxTArYjPsYbwCum6p+cJxI4yBIVtqnVxvPKrDGME2GWSoAkhU7RD+h vgPPHx+JxiJZ5uor9C9EIAnh+WsRNfRKluMM+5czWA7kYGVQPH+Is7++lCYyxzSwIkK8 hACA== 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; bh=DOIylwE94+smpoOixEHWH1FWAmh9/xB3G49Bn8yRpYU=; b=NrtoCIuMxlNwR+aMUrZ5SiQrlPGlALypimJZoEz/eadjQBTnkRgK49W5jrhc+K1kHi lV6x4RJ3F6fkj+qU8kMemFEC5whzBNQlqieOGp+L9c0ciH3BY+MJZnCqx5Ne/08p070u bOxad0UepvWEgsbb99YxiFe12LrvHnk4BfAwGgojFIDgckGhLn2jzPd8QhcjF3PWUGXh 7IKNOJZUTueMOWJQqCiXGNajaDH+FWuLjGn3mJcyKFyXdaC2mJjD/G9cMGd498sCm8CH C6RxroiJYFUuHdKvw9RFSPuKdBfhrv7l2NNhH6eBbzFtFIG/g0vzhuoLkwh+WpTjPzJX gLjg== 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=nNdvGDa7; 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 191si8416434pgf.41.2019.01.07.08.38.39; Mon, 07 Jan 2019 08:38:40 -0800 (PST) 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=nNdvGDa7; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id D9C307BEDE; Mon, 7 Jan 2019 16:38:35 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f67.google.com (mail-wm1-f67.google.com [209.85.128.67]) by mail.openembedded.org (Postfix) with ESMTP id 81D727BEE1 for ; Mon, 7 Jan 2019 16:38:33 +0000 (UTC) Received: by mail-wm1-f67.google.com with SMTP id t200so1562322wmt.0 for ; Mon, 07 Jan 2019 08:38:34 -0800 (PST) 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=xOqOokdSA3G6gE6deJVc5BJTH8VrrgNcgc4ng4UA9q8=; b=nNdvGDa7Gh2qAhjMFhOoxsWG9T5OPoEoGyPSpKOR6+u2mBaKbGO3AyiCuXv8qnjNqE eEG/dQJ/h3PLTbatIc2Z+FxUwdEffrKpRf6296kPHARmdbOjNcNWdU8zHsEwCOHkMC78 Y7v7j/DHHpdYO/1MCd1gHqMlr9za9ibgvEehnm2PKzmP5wVI65hxB8shefwA4AFweYLx uV7Ems6QTd5bdRCsCY48mCMHYeA3eH6T+JmSXSA0YGbozcajmTCxUXwTmCgOpBfnflhr PxYbpw0Wj4Lw9PSMDt+rao38jmsGg9Z52YczMHmjtqpjdIaL3CX/ljoblaM+zkJpVU2d aisw== 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=xOqOokdSA3G6gE6deJVc5BJTH8VrrgNcgc4ng4UA9q8=; b=ru8I3Yw0w7dRYcwHgAobXHeP7z7SPJqU9TiQf+srvZ8ifXCelfGNep4gPjqCs9YXrv FtBXOpPwQPGyfks6+qf/P6hDi9mClhbopnCwHGJogEl+zZvm8zmkIXnybmm7FPLHUfiq u9mpSdIqooxE6g8RTAK1kUUB6CoGVp92XK11D9v5vZsLrPgtnckDo6okcKF2uCJ7t3of peDhmwnVjcT2h26j9bRm4oB3HQseFFETmQnOrSJZQU1BSblqXTwuIR/UXxcso++hq5BI q/usmlilamxt+00p82UsR5UP9G5ywuI2ce2g4oUdxggZ9LyjBLmO4s5NaBec02yvWIWg xcwg== X-Gm-Message-State: AJcUukfNSeBnhUH1POoEaqp4RD0GESb+rJ+3aGbXv32ygU2jbWFwrTc3 1Fm/CiecLhNkNUjufiH8ftC8SIRIEaA= X-Received: by 2002:a1c:7706:: with SMTP id t6mr8689601wmi.57.1546879113671; Mon, 07 Jan 2019 08:38:33 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.32 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:32 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:17 +0000 Message-Id: <20190107163823.31816-1-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 Subject: [OE-core] [PATCH 1/7] toolchain-scripts: run post-relocate scripts for every environment 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 SDKs for multilib configurations have multiple environment scripts, so re-arrange the post-relocate hook invocation so that it runs the post-relocate hooks after sourcing each environment script. Signed-off-by: Ross Burton --- meta/classes/toolchain-scripts.bbclass | 46 +++++++++++++++++----------------- 1 file changed, 23 insertions(+), 23 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/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass index 6d1ba69473a..1a2ec4f3b29 100644 --- a/meta/classes/toolchain-scripts.bbclass +++ b/meta/classes/toolchain-scripts.bbclass @@ -128,30 +128,30 @@ toolchain_create_post_relocate_script() { touch $relocate_script cat >> $relocate_script <&2 - exit \$status - fi - done - rm -rf "${SDKPATHNATIVE}/post-relocate-setup.d" + # Source top-level SDK env scripts in case they are needed for the relocate + # scripts. + for env_setup_script in ${env_dir}/environment-setup-*; do + . \$env_setup_script + status=\$? + if [ \$status != 0 ]; then + echo "\$0: Failed to source \$env_setup_script with status \$status" + exit \$status + fi + + for s in ${SDKPATHNATIVE}/post-relocate-setup.d/*; do + if [ ! -x \$s ]; then + continue + fi + \$s "\$1" + status=\$? + if [ \$status != 0 ]; then + echo "post-relocate command \"\$s \$1\" failed with status \$status" >&2 + exit \$status + fi + done + done + rm -rf "${SDKPATHNATIVE}/post-relocate-setup.d" fi EOF } From patchwork Mon Jan 7 16:38:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154912 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674507ljp; Mon, 7 Jan 2019 08:38:59 -0800 (PST) X-Google-Smtp-Source: ALg8bN6FynTNLL97skTJbITyMLoGfflosMhIXNqbcvLNoVoz4XBjZViyCwx1bumvZm2k5kPn7DN1 X-Received: by 2002:a63:d818:: with SMTP id b24mr29948953pgh.174.1546879139543; Mon, 07 Jan 2019 08:38:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879139; cv=none; d=google.com; s=arc-20160816; b=LoqPV/jx+/ezUQu1g6tq+NYL/fHkp0/WD0UOUrzCc2hD0H1CMwvIQKlG7cvMDZyLJa jbfqcV5mGHfsJQJfQHfepVfrG1JN4b8Vew0yTZGFPxhBgKmHgVuMuQdwX9l0FskFyZB/ pyY7TFR++kNi74aOnI8LrulKsc/b2GUNW2MDF6MmSAdHrFcbxdMsX3CbRyKeYc+aWZHj SIqbxoPqZ2sNogZ5s5eCqF66aN4bj/juhio/c/Te8APkifyoD3vganksZvPAMkMKPJEe w5muB4gUSH3hDSD9iuDesUr6ZGD9Pq9VaIotS9qRKF1iwcnASpcRw9njwGFyZGZZ/Jrs z7Nw== 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; bh=wEOrXEqMfRkJbwgp4JxtEDbu/oJjXJll+K/O6Y1+V0E=; b=QdbHsqRFn2BSEUU26rT9XkgydUK1Ipnm7caASwNWTxKJl8nH6wd4MfG/ImHMTRcVzZ B1f+8HC63Z9eq/ATM9ZbZ9XmmyT8tBgM7eelnzwRLbXuaampCeKy9cVsUsWLUDykNdUe NZYqWvMGYCgy4/O5uGEA7Bob2Z1F7z9egPNqIrPwdL12Hx8h8FwBDmhL2J89A5yqKHP2 SjrCoYYn1y/hlkwN/EGOYchbbNjpUCSak5TCzkq/srHsm/Z9dhbGozlWoOiZ7XOwxTb+ VHRIULxvR6S0a/rkCDUywKnzNeUwm/UlvYKGrAg584QMl+djs7juOlHrJPNKnjNoS9nn MDYQ== 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=AnNTR0CF; 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 4si64864371pfg.280.2019.01.07.08.38.59; Mon, 07 Jan 2019 08:38:59 -0800 (PST) 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=AnNTR0CF; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id E74F37BF0F; Mon, 7 Jan 2019 16:38:56 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wr1-f54.google.com (mail-wr1-f54.google.com [209.85.221.54]) by mail.openembedded.org (Postfix) with ESMTP id 70C7C7BEE1 for ; Mon, 7 Jan 2019 16:38:34 +0000 (UTC) Received: by mail-wr1-f54.google.com with SMTP id r10so1065656wrs.10 for ; Mon, 07 Jan 2019 08:38:35 -0800 (PST) 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=KcT5hiZaJ5mqj6bj8rFqNKTWG33mc5itbB+cUY3dh/c=; b=AnNTR0CFFsvx1vj6NOgt4ZwXkPjo0pE8oahJsqqmrm1LTGl+YKTGNQFJiYM8z1jMvb QLUTB3f0Vtq+YLJLm2ILK9ZqH7vHIqNwZf/yBEaXCjjPak23AqiqPyw7zuYWeRHJV6dU oI7x7hzZSH/zsZtbnH7kaWd81xZV5IdXADHLoBH88BjXHue3HE4VteSdS9Iu29LXwVrx dvoxt8vhvc+uHtXaaXo1blVNPMeVCUPIi8q6PT+qJSubVLMt/NuuE3QJ5Zzpnb2592Tn JSCvTIYK7sDSu7VOXa1v5Yd6bS8r8uppTxWdr1hlz2Pbfo7refqyktj7u4JwMPYMNujy rUlg== 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=KcT5hiZaJ5mqj6bj8rFqNKTWG33mc5itbB+cUY3dh/c=; b=Hv/d9Xxl/etxgQrvWqCpZi7qEjHZg7eUfHETbcg9W4HRS460hZn2RC7xAyrCsP/Z38 3GcwYOUnVXeZOlWWo4PBNlg17lKfxDYs2wATA+slAzWAxoteFiUeLK00jkNCmMBSMdMz G1G/ZM8iODb9jJqnkhj8tLptTPX5CqAZPkCEBmk7SYuREgMtsjj29LxOwhPFlRiUoYXq DRSWUYaPBImPxWL0jVALVGYmPlQ2RgCGYF4Qg3BgX5WNDQGOwJBbixXK3JIVHZ3SqgWq WO5YrrZ+efSG3ahmkrtbA8QadLEi2ZPcVppQdzZVBN3YC8neoVk9sqbkiAxkidTfVY/2 /QVA== X-Gm-Message-State: AJcUukfsMa+EdBEcPcEwQfd2p1cWtuJ4AHQ1wK8V/k8whDQPExsonx5M HlyucRR9TCmuAtCOPUaBlOfYIcEVEm4= X-Received: by 2002:adf:f1cb:: with SMTP id z11mr44768728wro.35.1546879114726; Mon, 07 Jan 2019 08:38:34 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.33 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:34 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:18 +0000 Message-Id: <20190107163823.31816-2-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 2/7] meson: use a sensible default for libdir when cross-compiling 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 If --libdir isn't passed to Meson a default is used, but as this default value changes depending on the host (whether it is Debian-like, or has /usr/lib64) this isn't appropriate for cross builds. Signed-off-by: Ross Burton --- meta/recipes-devtools/meson/meson.inc | 1 + .../meson/meson/cross-libdir.patch | 41 ++++++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 meta/recipes-devtools/meson/meson/cross-libdir.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 ef8c5aefa52..d37afc3b0dc 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://0001-python-module-do-not-manipulate-the-environment-when.patch \ file://disable-rpath-handling.patch \ + file://cross-libdir.patch \ " SRC_URI[sha256sum] = "fb0395c4ac208eab381cd1a20571584bdbba176eb562a7efa9cb17cace0e1551" SRC_URI[md5sum] = "3c35b91e8040901034809576d54007c6" diff --git a/meta/recipes-devtools/meson/meson/cross-libdir.patch b/meta/recipes-devtools/meson/meson/cross-libdir.patch new file mode 100644 index 00000000000..2bd4fb3f9e3 --- /dev/null +++ b/meta/recipes-devtools/meson/meson/cross-libdir.patch @@ -0,0 +1,41 @@ +Upstream-Status: Backport +Signed-off-by: Ross Burton + +From ce24f0d6a9be22ba61d80cd254e0409de2eaffd7 Mon Sep 17 00:00:00 2001 +From: Jussi Pakkanen +Date: Thu, 27 Dec 2018 23:43:35 +0200 +Subject: [PATCH] Default libdir is "lib" when cross compiling. Closes #2535. + +--- + docs/markdown/snippets/crosslib.md | 7 +++++++ + mesonbuild/coredata.py | 8 ++++++++ + run_unittests.py | 13 +++++++++++++ + 3 files changed, 28 insertions(+) + create mode 100644 docs/markdown/snippets/crosslib.md + +diff --git a/mesonbuild/coredata.py b/mesonbuild/coredata.py +index d70c23038c..4e2f3e008c 100644 +--- a/mesonbuild/coredata.py ++++ b/mesonbuild/coredata.py +@@ -299,6 +299,7 @@ def __init__(self, options): + # Only to print a warning if it changes between Meson invocations. + self.pkgconf_envvar = os.environ.get('PKG_CONFIG_PATH', '') + self.config_files = self.__load_config_files(options.native_file) ++ self.libdir_cross_fixup() + + @staticmethod + def __load_config_files(filenames): +@@ -348,6 +349,13 @@ def __load_cross_file(filename): + + raise MesonException('Cannot find specified cross file: ' + filename) + ++ def libdir_cross_fixup(self): ++ # By default set libdir to "lib" when cross compiling since ++ # getting the "system default" is always wrong on multiarch ++ # platforms as it gets a value like lib/x86_64-linux-gnu. ++ if self.cross_file is not None: ++ self.builtins['libdir'].value = 'lib' ++ + def sanitize_prefix(self, prefix): + if not os.path.isabs(prefix): + raise MesonException('prefix value {!r} must be an absolute path' From patchwork Mon Jan 7 16:38:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154913 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674602ljp; Mon, 7 Jan 2019 08:39:05 -0800 (PST) X-Google-Smtp-Source: ALg8bN6pzFgqIxOZxjowex95M4NanBzNx+ZSMhbWcbNmmr2eVEYS+90pI5DibseXyCxAb0iI3jlO X-Received: by 2002:a17:902:2887:: with SMTP id f7mr60262320plb.176.1546879145019; Mon, 07 Jan 2019 08:39:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879145; cv=none; d=google.com; s=arc-20160816; b=iR5anbCB1/vNep+DixLdtstDbGCD8uc9KytqBrY8SeEuythIX3b2rKuTF3und3W4qh kj87xsasencjbzSgxy1noZebRBG/7MjHJzFmqzXxjyHyu22tKdMRDKAE5j4bRnJD4VnD 5Jb7OqUt2LLSql0OgM8MK7HwlsxeJHRrz87ITiM+opixYkzOohDkXLS8WmWbe2GXtFeF scnrn98QeWPzHdA2QtvBI1rn9V2v7HFoxUf/K4ljvMfhtSRoVg/7DwVjvEWualdldy8x lp8NAuqWZKxtQtg437L0oZfMHINUHAKxmfTGj0VciLBwM1fS3pdpV9KOq8WiYKztR5ak R2Jg== 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; bh=zx3l5vrA6kByleO9ClY/I0Ie4l36qCe6reUyW8sbOSo=; b=U8ipSPpHBZ0HoW66ZHR4zuv+dSlUOE1YNC7yievSTN/+/TkQAuf+Bbol/y7rN66pw6 lqHpaDAZyYXa49vOV4lmV61aotQba/SsClEcXk412toVCACxFbrWbp7dHIqWMQoBe+54 awHvSsVKVyraGuRmKw+AcXGAezeobuDeGh/fV4sBQlHXs395wpACHeREH60bzfM8Zemr zyfyeZ63k/p285Br86bAOn0o8abI2dA09tLbqGL+IOlbi/5W/kD2zTRKeBpFLW/hf4ct tUFxtZHKAYnmL0hWF4Arh+fA7/9YidjUQhxd7oL/KGeVxkYUg9rVT+GoSJEXfD45HaWc ZO+Q== 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=cPvEMkNz; 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 c12si9792074pgb.402.2019.01.07.08.39.04; Mon, 07 Jan 2019 08:39:05 -0800 (PST) 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=cPvEMkNz; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 3FFF67BF1A; Mon, 7 Jan 2019 16:38:58 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f43.google.com (mail-wm1-f43.google.com [209.85.128.43]) by mail.openembedded.org (Postfix) with ESMTP id D200D7BEAD for ; Mon, 7 Jan 2019 16:38:35 +0000 (UTC) Received: by mail-wm1-f43.google.com with SMTP id m22so1552750wml.3 for ; Mon, 07 Jan 2019 08:38:37 -0800 (PST) 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=UVcfRBZzxkG7rhopEiUsRMOLAg4M3iEtTy/TNaZC1hc=; b=cPvEMkNz6TqI1wQ5XVSrdBdLcDlI9znEmk9GJujXZQik5RB7HW+igm6r/18mdukWE4 NNlPn9OgTK7o8Z08DLRKuIjpBjx1CpQwLzcHoxCrcF/Gji5TIf1PEGh7S7oy8ygFcvbw QwT3BnQLZDKJ3NPa97uSAGVCWX/+77G8dImmUtItp1aKEVySYjM7e03F/1gDM8U4YTpV jm2GTKlrhbTmW7+f4sX4Tac0STiRpKEQ/Wl648gjZSbBBb/vhn1m9J0p/HZb50XYOxq5 sV71Bk362ZfqfbzSycq0TFkb6ODOKta9hvoDl6X8Dxn00AOcL6m4pbfF4kSMyfjGmH1/ nHhA== 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=UVcfRBZzxkG7rhopEiUsRMOLAg4M3iEtTy/TNaZC1hc=; b=JCM0gMU8tkoiTUysg6Tqz35zTBu2OPfTNdpVRy33EdQFD6pa+DAJsk7e0nIXUCCvUe VRlikj0T/6NlBFszmf7VU8si6COEY4ggPyIN8V4XuB4TtSWT6JsOzSLorIFXHd00y7DP G2bFBSUpRgQvn1bwoBe3ontbbMXMF+ZyiaLabZOCy042KoFZ9LbHBo4vRykK2m48Svsv HBP20DPpiltgwbesGVYF74dLK18AERKNIWaWPoIm5jtu5//U0yQytjl7ugO+NH8kay4l Y83I10wCSFb2i30xzq65PA2TNhF7MErFzDwkcSC7iZ7P566HnE8SslMQW8bdAZKAT0dL +rgw== X-Gm-Message-State: AJcUuke9yx4ZBzmYxopaXNdy5nw/6e5izjAOZ9Pu81apya7SPU+v6iq/ DYUQrQuN8jAXQDbFVX1vnFx6n+C6qaA= X-Received: by 2002:a1c:90cb:: with SMTP id s194mr9060636wmd.57.1546879115864; Mon, 07 Jan 2019 08:38:35 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.34 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:35 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:19 +0000 Message-Id: <20190107163823.31816-3-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 3/7] meson: fix nativesdk-meson for multilib SDKs 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 Multilib SDKs differ only in the environment variables set, so nativesdk-meson's setup script needs to write a cross file for each environment. Rename the shipped meson.cross to meson.cross.template, as it cannot be used directly. Now that post-relocate scripts are called once for each environment, the generated meson.cross can be prefixed with TARGET_PREFIX to ensure it is unique. Finally rewrite the setup script to use string.Template to perform the expansion instead of hand-coding the logic. Signed-off-by: Ross Burton --- meta/recipes-devtools/meson/meson/meson-setup.py | 69 ++++++---------------- meta/recipes-devtools/meson/meson/meson-wrapper | 2 +- .../meson/nativesdk-meson_0.49.0.bb | 41 +++++-------- 3 files changed, 36 insertions(+), 76 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/recipes-devtools/meson/meson/meson-setup.py b/meta/recipes-devtools/meson/meson/meson-setup.py index a9749eae9d4..808e2a062f6 100755 --- a/meta/recipes-devtools/meson/meson/meson-setup.py +++ b/meta/recipes-devtools/meson/meson/meson-setup.py @@ -1,62 +1,31 @@ #!/usr/bin/env python3 import os +import string import sys -def bail(msg): - print(msg, file=sys.stderr) - sys.exit(1) - -_MARKER = '@@' -def transform_line(line): - # Substitute any special markers of this form: - # @@ENV@@ - # with the value of ENV, split into meson array syntax. - start = line.find(_MARKER) - if start == -1: - return line - - end = line.rfind(_MARKER) - if end == start: - return line - - # Lookup value of the env var. - var = line[start+len(_MARKER):end] - try: - val = os.environ[var] - except KeyError: - bail('cannot generate meson.cross; env var %s not set' % var) +class Template(string.Template): + delimiter = "@" - # Transform into meson array. - val = ["'%s'" % x for x in val.split()] - val = ', '.join(val) - val = '[%s]' % val +class Environ(): + def __getitem__(self, name): + val = os.environ[name] + val = ["'%s'" % x for x in val.split()] + val = ', '.join(val) + val = '[%s]' % val + return val - before = line[:start] - after = line[end+len(_MARKER):] - - return '%s%s%s' % (before, val, after) - -# Make sure this is really an SDK extraction environment. try: sysroot = os.environ['OECORE_NATIVE_SYSROOT'] except KeyError: - bail('OECORE_NATIVE_SYSROOT env var must be set') - -cross_file = os.path.join(sysroot, 'usr/share/meson/meson.cross') -tmp_cross_file = '%s.tmp' % cross_file + print("Not in environment setup, bailing") + sys.exit(1) -# Read through and transform the current meson.cross. -lines = [] -with open(cross_file, 'r') as f: - for line in f: - lines.append(transform_line(line)) +template_file = os.path.join(sysroot, 'usr/share/meson/meson.cross.template') +cross_file = os.path.join(sysroot, 'usr/share/meson/%smeson.cross' % os.environ["TARGET_PREFIX"]) -# Write the transformed result to a tmp file and atomically rename it. In case -# we crash during the file write, we don't want an invalid meson.cross file. -with open(tmp_cross_file, 'w') as f: - for line in lines: - f.write(line) - f.flush() - os.fdatasync(f.fileno()) -os.rename(tmp_cross_file, cross_file) +with open(template_file) as in_file: + template = in_file.read() + output = Template(template).substitute(Environ()) + with open(cross_file, "w") as out_file: + out_file.write(output) diff --git a/meta/recipes-devtools/meson/meson/meson-wrapper b/meta/recipes-devtools/meson/meson/meson-wrapper index b2e00da513f..d4ffe60f9a1 100755 --- a/meta/recipes-devtools/meson/meson/meson-wrapper +++ b/meta/recipes-devtools/meson/meson/meson-wrapper @@ -10,5 +10,5 @@ fi unset CC CXX CPP LD AR NM STRIP exec "$OECORE_NATIVE_SYSROOT/usr/bin/meson.real" \ - --cross-file "$OECORE_NATIVE_SYSROOT/usr/share/meson/meson.cross" \ + --cross-file "${OECORE_NATIVE_SYSROOT}/usr/share/meson/${TARGET_PREFIX}meson.cross" \ "$@" diff --git a/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb b/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb index 721ee8c8f12..55c57775e06 100644 --- a/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb +++ b/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb @@ -5,9 +5,6 @@ inherit nativesdk SRC_URI += "file://meson-setup.py \ file://meson-wrapper" -def meson_array(var, d): - return "', '".join(d.getVar(var).split()).join(("'", "'")) - # both are required but not used by meson MESON_SDK_ENDIAN = "bogus-endian" MESON_TARGET_ENDIAN = "bogus-endian" @@ -17,32 +14,31 @@ MESON_C_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_CFLAGS}" MESON_CPP_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_CXXFLAGS}" MESON_LINK_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_LDFLAGS}" -# This logic is similar but not identical to that in meson.bbclass, since it's -# generating for an SDK rather than a cross-compile. Important differences are: +# The cross file logic is similar but not identical to that in meson.bbclass, +# since it's generating for an SDK rather than a cross-compile. Important +# differences are: # - We can't set vars like CC, CXX, etc. yet because they will be filled in with # real paths by meson-setup.sh when the SDK is extracted. # - Some overrides aren't needed, since the SDK injects paths that take care of # them. -addtask write_config before do_install -do_write_config[vardeps] += "MESON_C_ARGS MESON_CPP_ARGS MESON_LINK_ARGS CC CXX LD AR NM STRIP READELF" -do_write_config() { - # This needs to be Py to split the args into single-element lists - cat >${WORKDIR}/meson.cross <${D}${datadir}/meson/meson.cross.template < X-Patchwork-Id: 154914 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674701ljp; Mon, 7 Jan 2019 08:39:12 -0800 (PST) X-Google-Smtp-Source: ALg8bN69E2WA5edjRkgYv3NcZH17tLTGlfil245wYrvZcg2xROWyIjsspL/wFmhtgvJs70h4CEou X-Received: by 2002:a65:520a:: with SMTP id o10mr11866926pgp.276.1546879151895; Mon, 07 Jan 2019 08:39:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879151; cv=none; d=google.com; s=arc-20160816; b=gEGYTXPEpXUbw3BpCb91cE98v/iPjjHd44zCNHOKgCzKD+x6QTclFL2Q49kqAaPZaK wgnQ3HUsZqKEe7XgU27wU0p5z15bp+2+qLdSdqOt0fL32r/p2GAufHtQjDTzAaWdvKTJ 9EpwPXG5mhZKP0hbVrBKnZIr/wqbshdlFiPSuKYqD6soM8yrdM8rQEFJau2sXR1eS7bf jby9+fyHFlbLj5HleY1ZN5r8zW9gVgYRDZZ5iCWDsxP2Yjr30t2jP4RgzzkrYUXSsjbi 1Twqtt/ASqewXu6OSQVrCVt61RrjYutY2WXXP0V4JtIMvQJWmhf8pPU8B5Z1wEDIosxc 9mtg== 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; bh=Qe1LLsR4oQZ3I1CIsQAzWwd9SOWGN53zMQ6PA+O4Vkg=; b=W0WjM6FMXttf6kEKHno8vopsvs6ZqKsVhWS3onaYKD6KSJmAx8bB2ZbHgS93TugCsN jvSi/F22PyScCu+m60pvXJfRyGVn6X+aBDEe5CP4qU3GVzXm2x9nyasuJnRyfU7GzXAa aT7Hcu1XtCADdCQd0WdIJmSeUGkDZNeUp7NdKTUCWjbZkn0S9YQmS/JnEGmAtL4BwGQd GPNLDks0sYsdzvXLoaHR5dbqF+RYjVzO3fZf3q9zFm+G4H/+wCKQQEki9+//hbaYRDHE JE+fDrACps1KbSVNBT5jITlnUYACwxzmkip5yYinXDUhQpe4f64cGPvq5pboMmbVjhWS isfw== 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=IpJfqXxr; 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 g21si18352787plo.435.2019.01.07.08.39.11; Mon, 07 Jan 2019 08:39:11 -0800 (PST) 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=IpJfqXxr; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id AA6BA7BF27; Mon, 7 Jan 2019 16:38:59 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f67.google.com (mail-wm1-f67.google.com [209.85.128.67]) by mail.openembedded.org (Postfix) with ESMTP id B35727BEF8 for ; Mon, 7 Jan 2019 16:38:36 +0000 (UTC) Received: by mail-wm1-f67.google.com with SMTP id b11so1487439wmj.1 for ; Mon, 07 Jan 2019 08:38:38 -0800 (PST) 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=uXYx5AdEKzygw1as0yCl2jyD5GN+mv7tMAuIFJ5p5jE=; b=IpJfqXxrvtZDZOBD1SRdG4YEbZ8SlJe4XImifJqLfTpPUIkREilYcRUOBeIoNTFZih Ll0ClkLDc4l0enlkurcWjvXgTNfQOA1QV3kbBFWlLb1QLSK++n58lcsiRnoKxPQNEdrA g+G1fliYXK6odue8JLi5Goj5bF1j3vjDGnbZ0aFgKCW1mSYOQi4YoqzoIvO0MdHWTs+X MFD4EbkQ3xyDbh+Kl+qPPF9fmWitwj1pgJWSQr73cHRdAPnQ1/N/ET4WMous3ft6fz7Y XzBG5lTvnZmvsTklh/aheh75/SgLmLz7YlqUiugGrUpxFDM7a4G9E0vd3URxbiNH7Hcp aoxg== 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=uXYx5AdEKzygw1as0yCl2jyD5GN+mv7tMAuIFJ5p5jE=; b=H+YAdSyM5oPv4eJ4XrtFNxprPzTrfQ3jysUQjbLR6WqzMtVf6kyHMBK5Dq/uxDs2NL 6T8SI4YwieR7S+PDqtamBSkXwI2HHQfA0AEoy7rWvLzSCm4OZDYmwshI0iZG5PUGH1c0 4e8X0zYLgrpm1VT8+4gamAv6aF75Cs6ikJEQ+AEWFwAuxT+cdZym5K6Iw2HblI8rQc+S eDMbxK29xBXjmDub9vebrqMjFCUkWr3rxZORlFzLNn0tXxJinOvsuPS609myyb+oWOgG CeyL3jUeJHUAbiZ5Tt+OYZY0dhUt/7TsZpyoEYKsmXs8TDSZt05yMHtKiXXUkSpS/1b5 7dtw== X-Gm-Message-State: AJcUukedy+9y3Ruuf5LxTrhbgbSTkhh1aWtgo6GLtMNjUWuI+zgnpDVe zxseGoT3Lx+GAcgd8oK57kguV0QUt2E= X-Received: by 2002:a1c:7f0c:: with SMTP id a12mr8933845wmd.89.1546879117170; Mon, 07 Jan 2019 08:38:37 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.35 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:36 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:20 +0000 Message-Id: <20190107163823.31816-4-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 4/7] meson: write correct host endian into SDK 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 Meson doesn't ignore this but will emit a warning, so write the correct value. Signed-off-by: Ross Burton --- meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 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/recipes-devtools/meson/nativesdk-meson_0.49.0.bb b/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb index 55c57775e06..1549357a554 100644 --- a/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb +++ b/meta/recipes-devtools/meson/nativesdk-meson_0.49.0.bb @@ -1,13 +1,20 @@ include meson.inc inherit nativesdk +inherit siteinfo SRC_URI += "file://meson-setup.py \ file://meson-wrapper" -# both are required but not used by meson -MESON_SDK_ENDIAN = "bogus-endian" -MESON_TARGET_ENDIAN = "bogus-endian" +def meson_endian(prefix, d): + arch, os = d.getVar(prefix + "_ARCH"), d.getVar(prefix + "_OS") + sitedata = siteinfo_data_for_machine(arch, os, d) + if "endian-little" in sitedata: + return "little" + elif "endian-big" in sitedata: + return "big" + else: + bb.fatal("Cannot determine endianism for %s-%s" % (arch, os)) MESON_TOOLCHAIN_ARGS = "${BUILDSDK_CC_ARCH}${TOOLCHAIN_OPTIONS}" MESON_C_ARGS = "${MESON_TOOLCHAIN_ARGS} ${BUILDSDK_CFLAGS}" @@ -44,7 +51,7 @@ cpp_link_args = @LDFLAGS system = '${SDK_OS}' cpu_family = '${SDK_ARCH}' cpu = '${SDK_ARCH}' -endian = '${MESON_SDK_ENDIAN}' +endian = '${@meson_endian("SDK", d)}' EOF install -d ${D}${SDKPATHNATIVE}/post-relocate-setup.d From patchwork Mon Jan 7 16:38:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154915 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674822ljp; Mon, 7 Jan 2019 08:39:18 -0800 (PST) X-Google-Smtp-Source: ALg8bN5RGzTxTepbX2TMYJZHvRb3+03MZIm20KBggS1koj/90WVOSrmBfIqUZb8xG194pJ80KmXV X-Received: by 2002:a17:902:7c82:: with SMTP id y2mr61139693pll.33.1546879158725; Mon, 07 Jan 2019 08:39:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879158; cv=none; d=google.com; s=arc-20160816; b=08S/POo8J6Y3CTB0cEuApVHJJOEpv8oAdEXFGzVO+Gw3zSi81Nnlo4FF2BY07FyXWj UeKqYHRUE2y3uw2Q/PgDkJINkdOCR2TF53MMHA+2j70Z1UpZhlvvjUirmT4Or4aoF4pq IxUxzSQ/3S3T8Qz3kWuBOhbZlK0Ip9mxbAdgyGoTlx7vSrPS9AbO5F0ijPtoeB+9EQjw jOjwq3DQAZXfUwC/Oxc3qof0BPIRyyNI4GI5n+X/FhAmTKPRV17ONU2yl89TrAsJvfMk Dl+bpejx8IVQoLguFQUCNgA9LDKTX9Nq0fbU/aaA8n2iZIQs1Z7mszNCvHeLPARXngPe y0YQ== 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; bh=tI4rbpNzGd4rYkftegmXE291kXyjv01n8jwjianw1n0=; b=SaJkvae/bk+4FHR1wsfb7uKaswlt9OBD44wNIjnXLy/qxf60Zj+J+srwRFU6v7O8iD vJugcO+EzxTlIpn5hz2QHsv6Z9bwsY/Cz0xVcXuKYtSueteksN4ku5reQDMk6q4ZW4Ls xC3iAcdBriQSE5rc4+ldQ78JriGuYJXfyoJbsPoQXUnIosiMnuv28/BEyHEbMKP9BmNK GhrotKzM30kgqn1wjn7yhDmqX7cZ1J0GCASbp4Fhmypnxh4X7wlD4MCQ+oJmp299eku4 EgrhhjU8wnjCCSZjDCtqWe26SOPySsbkWDvCcmb31WAqmW9zKWsnNs8+FWo3dia5Gtaz 8qQQ== 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=iDiwrRhy; 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 v17si6584933pga.566.2019.01.07.08.39.18; Mon, 07 Jan 2019 08:39:18 -0800 (PST) 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=iDiwrRhy; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id C58087BF37; Mon, 7 Jan 2019 16:39:00 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f66.google.com (mail-wm1-f66.google.com [209.85.128.66]) by mail.openembedded.org (Postfix) with ESMTP id F02B37BF07 for ; Mon, 7 Jan 2019 16:38:37 +0000 (UTC) Received: by mail-wm1-f66.google.com with SMTP id b11so1487511wmj.1 for ; Mon, 07 Jan 2019 08:38:39 -0800 (PST) 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=ZW6H3v2kjmjmdUdne1gO47HPokIwryiw52VJWhEONn8=; b=iDiwrRhy9mucEh+48Fcu7kCIyIKxI275BWqNOjvljlZRts/1qvdpQWHb1w5Cis5qhE SbP852o7IYmW4Or5M8lO7sILGVE3xVwbNNcP4r1WS8r915RIP+KpEllMwyhjJS9xn5bH 6sHkoTIju9Wl3VS9bckKvCwmHKMKWdJo1FRmCPIoams0E7RV4azmTkxWCA0yCwI0+Mcx 2MCMJYIDi3xN5fMKxaZ9hB9ZUMyGgb7AuhrTy9QKN+z/eIBsN3XEYnAdWYjGJV+KUSc3 kpZtLGVPijxEk9ykisztDesM1Q+GDEpadLGQaeqG0d2RZifXJWPx8ReLXqQu1ddlE8X2 wjgg== 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=ZW6H3v2kjmjmdUdne1gO47HPokIwryiw52VJWhEONn8=; b=ow4xtyWSJivAJlWLWdhcmoOdUmDLlkEBJGPvSKOKm3hCb0zmiEsXTGzmbCd3W5k96j IpaYBtQzF8SKXYHtqcZ7N/fZgWW6S/wbB4NuWyAUp+/1CKuJJGJc86lcfRX+hkqJ0DRg LSFQBRtPUlqUMkNiqsB4VXDu5CVl/1pXG5XZKYDaEJ6FoPeGOr5Z4vboCBQXalr9YQ2r GF4fPCSlaWC06dZ3L7MyPVFOmVWjW2heU7CUpnASwQD7B4qp+qoWa5L+4HJDkg16B7un 9lmo1iotLer2NJVK1V2dF6pwURg1Y4bHQZ7VWQG8a2lIE8/JTyITkaQ4/9E/XisCmqUE o01g== X-Gm-Message-State: AJcUukc6732s49PeOdDFNLQhy9kAH00CkPbfNYDQnGnCgRK3qnTHUXih rZ/YuHTZ9lLa8YFtbSgAfS5ZcTJiGwU= X-Received: by 2002:a1c:4346:: with SMTP id q67mr9882206wma.114.1546879118368; Mon, 07 Jan 2019 08:38:38 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.37 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:37 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:21 +0000 Message-Id: <20190107163823.31816-5-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 5/7] oeqa/sdk/cases: clean up DL_DIR handling 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 Signed-off-by: Ross Burton --- meta/lib/oeqa/sdk/cases/assimp.py | 3 +-- meta/lib/oeqa/sdk/cases/buildcpio.py | 3 +-- meta/lib/oeqa/sdk/cases/buildgalculator.py | 3 +-- meta/lib/oeqa/sdk/cases/buildlzip.py | 3 +-- 4 files changed, 4 insertions(+), 8 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/lib/oeqa/sdk/cases/assimp.py b/meta/lib/oeqa/sdk/cases/assimp.py index 21c91068815..595f3834894 100644 --- a/meta/lib/oeqa/sdk/cases/assimp.py +++ b/meta/lib/oeqa/sdk/cases/assimp.py @@ -20,8 +20,7 @@ class BuildAssimp(OESDKTestCase): def test_assimp(self): import tempfile with tempfile.TemporaryDirectory(prefix="assimp", dir=self.tc.sdk_dir) as testdir: - dl_dir = self.td.get('DL_DIR', None) - tarball = self.fetch(testdir, dl_dir, "https://github.com/assimp/assimp/archive/v4.1.0.tar.gz") + tarball = self.fetch(testdir, self.td["DL_DIR"], "https://github.com/assimp/assimp/archive/v4.1.0.tar.gz") subprocess.check_output(["tar", "xf", tarball, "-C", testdir]) sourcedir = os.path.join(testdir, "assimp-4.1.0") diff --git a/meta/lib/oeqa/sdk/cases/buildcpio.py b/meta/lib/oeqa/sdk/cases/buildcpio.py index ff3e1347d37..9504ee8e053 100644 --- a/meta/lib/oeqa/sdk/cases/buildcpio.py +++ b/meta/lib/oeqa/sdk/cases/buildcpio.py @@ -13,8 +13,7 @@ class BuildCpioTest(OESDKTestCase): """ def test_cpio(self): with tempfile.TemporaryDirectory(prefix="cpio-", dir=self.tc.sdk_dir) as testdir: - dl_dir = self.td.get('DL_DIR', None) - tarball = self.fetch(testdir, dl_dir, "https://ftp.gnu.org/gnu/cpio/cpio-2.12.tar.gz") + tarball = self.fetch(testdir, self.td["DL_DIR"], "https://ftp.gnu.org/gnu/cpio/cpio-2.12.tar.gz") dirs = {} dirs["source"] = os.path.join(testdir, "cpio-2.12") diff --git a/meta/lib/oeqa/sdk/cases/buildgalculator.py b/meta/lib/oeqa/sdk/cases/buildgalculator.py index 164a695637a..47d7580fafd 100644 --- a/meta/lib/oeqa/sdk/cases/buildgalculator.py +++ b/meta/lib/oeqa/sdk/cases/buildgalculator.py @@ -20,8 +20,7 @@ class GalculatorTest(OESDKTestCase): def test_galculator(self): with tempfile.TemporaryDirectory(prefix="galculator", dir=self.tc.sdk_dir) as testdir: - dl_dir = self.td.get('DL_DIR', None) - tarball = self.fetch(testdir, dl_dir, "http://galculator.mnim.org/downloads/galculator-2.1.4.tar.bz2") + tarball = self.fetch(testdir, self.td["DL_DIR"], "http://galculator.mnim.org/downloads/galculator-2.1.4.tar.bz2") dirs = {} dirs["source"] = os.path.join(testdir, "galculator-2.1.4") diff --git a/meta/lib/oeqa/sdk/cases/buildlzip.py b/meta/lib/oeqa/sdk/cases/buildlzip.py index a7ca239fb49..b7483bfea51 100644 --- a/meta/lib/oeqa/sdk/cases/buildlzip.py +++ b/meta/lib/oeqa/sdk/cases/buildlzip.py @@ -9,8 +9,7 @@ class BuildLzipTest(OESDKTestCase): """ def test_lzip(self): with tempfile.TemporaryDirectory(prefix="lzip", dir=self.tc.sdk_dir) as testdir: - dl_dir = self.td.get('DL_DIR', None) - tarball = self.fetch(testdir, dl_dir, "http://downloads.yoctoproject.org/mirror/sources/lzip-1.19.tar.gz") + tarball = self.fetch(testdir, self.td["DL_DIR"], "http://downloads.yoctoproject.org/mirror/sources/lzip-1.19.tar.gz") dirs = {} dirs["source"] = os.path.join(testdir, "lzip-1.19") From patchwork Mon Jan 7 16:38:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154916 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3674923ljp; Mon, 7 Jan 2019 08:39:26 -0800 (PST) X-Google-Smtp-Source: ALg8bN59DYcCL6wWkdIvHH4CwBXi3g/XMpmvQ20BMJp7Go7nAbtx+wanrL9px0PJyX/69aeEMW8w X-Received: by 2002:a63:4246:: with SMTP id p67mr11415596pga.335.1546879166023; Mon, 07 Jan 2019 08:39:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879166; cv=none; d=google.com; s=arc-20160816; b=Sjweiu8VY2jGg96Xva4k5UJC7497PUSf+QOXYtBUS4wWG3D2oeQPOo7J8WcNa3lAVM Z9S1sIxbZZEbuUqBdfjW7h696yGO/iXKm/DFWNb/l6kFyLOoE7Q7RhnNSnLqf6pideMX NHm95vUz3k0obuCtjxh8XFSrqDORUrJF24CgwgesH0gI2Z0vVCmzZslyK2GpuEUCQbT6 QkRx8f0sEFZstyIBG8JddkeCKtjbMKnS1644SNGLtdQh3j+HdhULQFEBNLTAssyJRq32 wYObXpUPpS72v+6YyMpupFsWSv/NChR2Z/r8g19Kl7TDyzB7np87YbI9iNG6RxjFa+tv Ug2A== 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; bh=oNnBILL3CucdWM0XGbf6qqdfzndhIGWAqgcxMo+0//c=; b=o0NlK7dCxHUkBy9vG5/LmqoM4IKncWTaV9TxH4yKiIejkMsfK4UvenuAgX+7T9Ar8u lfj4qW+g0C0zP47GCYEdXUSPgSmPe0nGqveFczJIzJMEarzetBhgQQRPk1vnOOSPZ5Af k4GSTWpmPZil1f9NxS4DcK/cg5NCJqwk6m2cnrN9CrFiIOpwQ89Qs247AGYwLQJrGtUO a6ROygoW2KV9OUHtVmiiU+agI532FuSj6wiI7znJqrVBJ+ZsqKcGzagU8IsN0ZgSs4bl uB6Nlj9wlxhsTCBaKZ0OFKBd+nSvs7tdMpi7kpPH/pxpH+D06bUrJlbJ9cYSb4xFq7qt OXFw== 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=NygoYRtb; 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 d11si62305923pla.335.2019.01.07.08.39.25; Mon, 07 Jan 2019 08:39:26 -0800 (PST) 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=NygoYRtb; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 0CEAF7BF46; Mon, 7 Jan 2019 16:39:02 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) by mail.openembedded.org (Postfix) with ESMTP id D4C537BF0E for ; Mon, 7 Jan 2019 16:38:38 +0000 (UTC) Received: by mail-wm1-f44.google.com with SMTP id f81so1533139wmd.4 for ; Mon, 07 Jan 2019 08:38:40 -0800 (PST) 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=wCMkiKqT7kKw9qeoRZAFsGg7VPWuG6LCe7XUKZnIyqE=; b=NygoYRtbnoo/IIV57qLIH9Cgyc1Zvg/Fzm20ADaoU9KfslaDAGEAawfbhBilfOfVMr kTTGzWpMW11yQKwSTo9nKT8ClWK1GCRsfDH3Eslp+Qi28Q2/ixn6+xhDbcWFlq95LSm+ QYX91sWseitQ8nnxqV1HjLzitgbmyt8C31GaaZ08VjeKdMxUGv1kX5qcr2yKx7dMT38/ j26CbSS8QL+yolL7olBr390KD/h/1g0ipSTgVFKgvNvQTK0Yc/S8bTogPmVdr7XTtOhC w5E8DcZTDQXpkSkHfiR2kzEgvA/tot1j1keD9ORK0qME8bmFs0n74STMp13/Ix4uvkYp deow== 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=wCMkiKqT7kKw9qeoRZAFsGg7VPWuG6LCe7XUKZnIyqE=; b=pwGHS30T3AG6d4/qIs6wLA+XkVXr7h5Vj+zpu0gnzOlIwtf8l4Mys7yypSLvBHRBs/ rXJRHhUcAWAi8ahvNBIFWVIaI8YR6ZzM1LfTz4PQezL5pQ7mBYzdgu1EGMdC+wGgJvE6 mJ7TsOW+Z9bLEmM3sUx8FGn7C3Zf90RU4kXePUcZKoM7eKSdd2XMjFsGqbbn3O/UYxE+ o9zYckM7JiMwjheN5H+tDoXs/5/4lNA/GkuJrNsm8GhbZP+eo1fICDxiPEQmuoQgOr8N iXo0OpEjtK9hjIJ55yS0aVC0VhI30uPRPC3GbhR0gsPG7rWqjWLT5YOg6AOJ+WNrvJRy K95g== X-Gm-Message-State: AJcUukek3QqfkJMcFIE/RazI64f/ANcsErvhbo9SzI1TLyaW80D8qoDh rPuGhzGGHRsr0p95Mgt81NBpMDQG1gY= X-Received: by 2002:a1c:ce0e:: with SMTP id e14mr9868425wmg.53.1546879119355; Mon, 07 Jan 2019 08:38:39 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.38 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:38 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:22 +0000 Message-Id: <20190107163823.31816-6-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 6/7] oeqa/sdk/assimp: cleanup 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 Unify style with the other tests. Signed-off-by: Ross Burton --- meta/lib/oeqa/sdk/cases/assimp.py | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 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/lib/oeqa/sdk/cases/assimp.py b/meta/lib/oeqa/sdk/cases/assimp.py index 595f3834894..a6000103993 100644 --- a/meta/lib/oeqa/sdk/cases/assimp.py +++ b/meta/lib/oeqa/sdk/cases/assimp.py @@ -1,5 +1,7 @@ -import os, subprocess, unittest -import bb +import os +import subprocess +import tempfile +import unittest from oeqa.sdk.case import OESDKTestCase from oeqa.utils.subprocesstweak import errors_have_output @@ -10,25 +12,25 @@ class BuildAssimp(OESDKTestCase): Test case to build a project using cmake. """ - td_vars = ['DATETIME', 'TARGET_OS', 'TARGET_ARCH'] - def setUp(self): if not (self.tc.hasHostPackage("nativesdk-cmake") or self.tc.hasHostPackage("cmake-native")): raise unittest.SkipTest("Needs cmake") def test_assimp(self): - import tempfile with tempfile.TemporaryDirectory(prefix="assimp", dir=self.tc.sdk_dir) as testdir: tarball = self.fetch(testdir, self.td["DL_DIR"], "https://github.com/assimp/assimp/archive/v4.1.0.tar.gz") - subprocess.check_output(["tar", "xf", tarball, "-C", testdir]) - sourcedir = os.path.join(testdir, "assimp-4.1.0") - builddir = os.path.join(testdir, "build") - installdir = os.path.join(testdir, "install") - bb.utils.mkdirhier(builddir) + dirs = {} + dirs["source"] = os.path.join(testdir, "assimp-4.1.0") + dirs["build"] = os.path.join(testdir, "build") + dirs["install"] = os.path.join(testdir, "install") + + subprocess.check_output(["tar", "xf", tarball, "-C", testdir]) + self.assertTrue(os.path.isdir(dirs["source"])) + os.makedirs(dirs["build"]) - self._run("cd %s && cmake -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON %s " % (builddir, sourcedir)) - self._run("cmake --build %s -- -j" % builddir) - self._run("cmake --build %s --target install -- DESTDIR=%s" % (builddir, installdir)) - self.check_elf(os.path.join(installdir, "usr", "local", "lib", "libassimp.so.4.1.0")) + self._run("cd {build} && cmake -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON {source}".format(**dirs)) + self._run("cmake --build {build} -- -j".format(**dirs)) + self._run("cmake --build {build} --target install -- DESTDIR={install}".format(**dirs)) + self.check_elf(os.path.join(dirs["install"], "usr", "local", "lib", "libassimp.so.4.1.0")) From patchwork Mon Jan 7 16:38:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 154917 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3675067ljp; Mon, 7 Jan 2019 08:39:35 -0800 (PST) X-Google-Smtp-Source: ALg8bN7wK2IbKsJwB+XghwB24QQXF+aRr8Y6RSA/tZF69mtiL7Gwjllc0JHeGoO4MiUuu+I0Xeq5 X-Received: by 2002:a17:902:b118:: with SMTP id q24mr62737228plr.209.1546879175076; Mon, 07 Jan 2019 08:39:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546879175; cv=none; d=google.com; s=arc-20160816; b=PPXue98W9R23OVk6dUggkckzdkQbbVlYvFZ3HgTa/pOvzlYYYvXJaHgzKj0ZztH7YW E6eC+dnpOhwfyx1xdKrDlg3kfVZRLIaY6XPHLlNjSCHpc5v4AMx19C3W3RcSHY4ksJAy 33ki5iedx9o0c1daTltLC35LoKk6hRWTkkSF+WsO5nXYZdWyNha1cOXxy2mCWSx24+Tq gXtJPSo0y5Hwz7oi0/rU9Tduvg8XNRK6iO/JdLtjC4B6yZDzOt0lx5U5JxRZ3bHYFwaV L+BNQNycVFkZdV7KWdtYF9QHI0AggLevdCPYgIr7aPVhAg76rFrYDr54VWivTPlLcEf/ wFNg== 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; bh=4BSzFORDkgUfOb43SJ0+rhhyuA+43uePO+HpTeULif8=; b=0Z1NscczDOqBBWO2fEn94/Jh8GQU1xMScBReMyHQiFwLaIKu4zGdYKyeyRjuuWukcb T5nvXFs4FIssZgMjhvoBfqTUBKuNgheB/P0uY5O83XYSw1orLpWn0fxL6P7hzA9jP+PK qnY2A/qcj+cmecnk6uaKUp8L2sUt5K0M27C7Sj2AZ2PPGgc2Ir4m0kwNlYNunciPL01p 9PDqrWrhoeZIeYNjklPKFO9/wpwXkwlxcbTpNO1NLIFUHH49GB/Ww1R4ZeJ/Ucs9PdXW sWMV8omEWdZAtXIEJt9TSYQFROPLlKI6sNoInekpc0NRTHIo9NJcOoFeo5Ar38QIrY3b yiMg== 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=aVKPQr1J; 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 t3si14550754pgl.108.2019.01.07.08.39.34; Mon, 07 Jan 2019 08:39:35 -0800 (PST) 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=aVKPQr1J; 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 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id A6CBC7BF10; Mon, 7 Jan 2019 16:39:04 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wm1-f54.google.com (mail-wm1-f54.google.com [209.85.128.54]) by mail.openembedded.org (Postfix) with ESMTP id 3F8737BEAD for ; Mon, 7 Jan 2019 16:38:40 +0000 (UTC) Received: by mail-wm1-f54.google.com with SMTP id y185so6513948wmd.1 for ; Mon, 07 Jan 2019 08:38:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=4/fFP9x0vmlSYZ+oHB1lVcOV+1/2UGEDzG4PvEBNI9s=; b=aVKPQr1JE7Yl4Kg2eSR6PyWnAlb5LClgODYExDyL9iJi4L+0H82chh2q8yyeQvw07V zy67cJ8CbqJU++Iq2iumO8NfIXXFOKSP+TG6OQghSNDggOzwdPkl/lee1g8JB/FQPUpD fzh533anD5wISomqr9s+nqOZbGyJ3KM7s8V4AlgnXBjsMK3KB1SY28/rNX2hCWuMM2Ab eTxcern3SrUWOTX2jhRPCKXmnj/SyGwauUqmXuYvOAjrQm1L3M5k/sIRN6AMk3GmflVI WeqD4NVWKHEqeyFEp7a7OhgSr2zfJBW2gXhg2VSAHxG/6HG7jpjY5Fx1OwB8jT2cFHqE fcNA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=4/fFP9x0vmlSYZ+oHB1lVcOV+1/2UGEDzG4PvEBNI9s=; b=PgZOTyYq1arBmqnEMPO3zzr6D3Ni+Lrd6Ol3dAKsQRNuwnJEgj18OJbpUPS6v+4w6/ rMW/9hkZj4AOvmMLeMlTUcuchZV90lyv+jkEN2PFcNY7GPXF5YajksUXh/T8fvm9Co2b k8L9N0pahoFpkbPg2B85CC+eXg7AmB9WLJeUayqSps9yc0Paa2aMIKi813BQlM4nL6zE uwTEG7S9VMqQkn0Tid8yOn54r0q3OHxZ8BEwqUFh5CFapQu8yyDMbccLR2ur81r0c/2O NYOGROfaPrKhwtjY1MFKURqpMkswKForN6tkOgLUOT4jMHRbFWxzB06Q3sKROoUjVgca QoCA== X-Gm-Message-State: AJcUukf/AYVwJR8udolS1reZMFvxS52sQWYp5oO4KXItKZWhZG7hxcY+ sqfchniYGb9WyVHasml2SXCecK1FSMY= X-Received: by 2002:a1c:f509:: with SMTP id t9mr9935732wmh.76.1546879120648; Mon, 07 Jan 2019 08:38:40 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id o5sm13918958wmg.25.2019.01.07.08.38.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Jan 2019 08:38:39 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Mon, 7 Jan 2019 16:38:23 +0000 Message-Id: <20190107163823.31816-7-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190107163823.31816-1-ross.burton@intel.com> References: <20190107163823.31816-1-ross.burton@intel.com> Subject: [OE-core] [PATCH 7/7] oeqa/sdk: add test to exercise 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 (From OE-Core rev: 29359493e391d68a5a6b4fa4d09ffdc1fe6db620) Signed-off-by: Ross Burton Signed-off-by: Richard Purdie --- meta/lib/oeqa/sdk/cases/buildepoxy.py | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 meta/lib/oeqa/sdk/cases/buildepoxy.py -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/lib/oeqa/sdk/cases/buildepoxy.py b/meta/lib/oeqa/sdk/cases/buildepoxy.py new file mode 100644 index 00000000000..ef24b4f4ac1 --- /dev/null +++ b/meta/lib/oeqa/sdk/cases/buildepoxy.py @@ -0,0 +1,35 @@ +import os +import subprocess +import tempfile +import unittest + +from oeqa.sdk.case import OESDKTestCase +from oeqa.utils.subprocesstweak import errors_have_output +errors_have_output() + +class EpoxyTest(OESDKTestCase): + """ + Test that Meson builds correctly. + """ + def setUp(self): + if not (self.tc.hasHostPackage("nativesdk-meson")): + raise unittest.SkipTest("GalculatorTest class: SDK doesn't contain Meson") + + def test_epoxy(self): + with tempfile.TemporaryDirectory(prefix="epoxy", dir=self.tc.sdk_dir) as testdir: + tarball = self.fetch(testdir, self.td["DL_DIR"], "https://github.com/anholt/libepoxy/releases/download/1.5.3/libepoxy-1.5.3.tar.xz") + + dirs = {} + dirs["source"] = os.path.join(testdir, "libepoxy-1.5.3") + dirs["build"] = os.path.join(testdir, "build") + dirs["install"] = os.path.join(testdir, "install") + + subprocess.check_output(["tar", "xf", tarball, "-C", testdir]) + self.assertTrue(os.path.isdir(dirs["source"])) + os.makedirs(dirs["build"]) + + self._run("meson -Degl=no -Dglx=no -Dx11=false {build} {source}".format(**dirs)) + self._run("ninja -C {build} -v".format(**dirs)) + self._run("DESTDIR={install} ninja -C {build} -v install".format(**dirs)) + + self.check_elf(os.path.join(dirs["install"], "usr", "local", "lib", "libepoxy.so"))