From nobody Sat May 18 23:44:15 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1553120380752186.77714905404957; Wed, 20 Mar 2019 15:19:40 -0700 (PDT) Received: from localhost ([127.0.0.1]:54085 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6jYa-0001vs-7J for importer@patchew.org; Wed, 20 Mar 2019 18:19:32 -0400 Received: from eggs.gnu.org ([209.51.188.92]:32850) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6jWp-00014y-Ri for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:17:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h6jWp-0006O0-5i for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:17:43 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47440) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1h6jWo-0006NB-R3 for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:17:43 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BF3B43DE04; Wed, 20 Mar 2019 22:12:21 +0000 (UTC) Received: from virtlab501.virt.lab.eng.bos.redhat.com (virtlab501.virt.lab.eng.bos.redhat.com [10.19.152.162]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3FC7919C66; Wed, 20 Mar 2019 22:12:21 +0000 (UTC) From: Wainer dos Santos Moschetta To: qemu-devel@nongnu.org Date: Wed, 20 Mar 2019 18:12:06 -0400 Message-Id: <20190320221207.11366-2-wainersm@redhat.com> In-Reply-To: <20190320221207.11366-1-wainersm@redhat.com> References: <20190320221207.11366-1-wainersm@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Wed, 20 Mar 2019 22:12:21 +0000 (UTC) Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH 1/2] docker: Fix travis.py parser and misc change X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, philmd@redhat.com, alex.bennee@linaro.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Fixed the travis.py script that has failed to parse the current QEMU_SRC/.travis.yml file. It no longer makes combinations from env/matrix, instead it uses explicit includes. Also the compiler can be omitted from matrix/include, so that Travis chooses the first entry of the global compiler list. Replaced yaml.load() with yaml.safe_load() so that quieting the following deprecation warning: https://github.com/yaml/pyyaml/wiki/PyYAML-yaml.load(input)-Deprecation Signed-off-by: Wainer dos Santos Moschetta Reviewed-by: Alex Benn=C3=A9e --- tests/docker/travis.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/tests/docker/travis.py b/tests/docker/travis.py index ea1ef169e6..e1433012bd 100755 --- a/tests/docker/travis.py +++ b/tests/docker/travis.py @@ -17,18 +17,17 @@ import yaml import itertools =20 def load_yaml(fname): - return yaml.load(open(fname, "r").read()) + return yaml.safe_load(open(fname, "r").read()) =20 def conf_iter(conf): + # If "compiler" is omitted from the included env then Travis picks the + # first entry of the global compiler list. + default_compiler =3D conf["compiler"][0] def env_to_list(env): return env if isinstance(env, list) else [env] for entry in conf["matrix"]["include"]: yield {"env": env_to_list(entry["env"]), - "compiler": entry["compiler"]} - for entry in itertools.product(conf["compiler"], - conf["env"]["matrix"]): - yield {"env": env_to_list(entry[1]), - "compiler": entry[0]} + "compiler": entry.get("compiler", default_compiler)} =20 def main(): if len(sys.argv) < 2: --=20 2.20.1 From nobody Sat May 18 23:44:15 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1553120394734775.0999495550152; Wed, 20 Mar 2019 15:19:54 -0700 (PDT) Received: from localhost ([127.0.0.1]:54089 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6jYs-0002FS-KL for importer@patchew.org; Wed, 20 Mar 2019 18:19:50 -0400 Received: from eggs.gnu.org ([209.51.188.92]:32850) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6jWz-00014y-KH for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:17:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h6jRf-0000PK-Ux for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:12:24 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56076) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1h6jRf-0000K4-KH for qemu-devel@nongnu.org; Wed, 20 Mar 2019 18:12:23 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7851430832D3; Wed, 20 Mar 2019 22:12:22 +0000 (UTC) Received: from virtlab501.virt.lab.eng.bos.redhat.com (virtlab501.virt.lab.eng.bos.redhat.com [10.19.152.162]) by smtp.corp.redhat.com (Postfix) with ESMTP id E66E619C66; Wed, 20 Mar 2019 22:12:21 +0000 (UTC) From: Wainer dos Santos Moschetta To: qemu-devel@nongnu.org Date: Wed, 20 Mar 2019 18:12:07 -0400 Message-Id: <20190320221207.11366-3-wainersm@redhat.com> In-Reply-To: <20190320221207.11366-1-wainersm@redhat.com> References: <20190320221207.11366-1-wainersm@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.44]); Wed, 20 Mar 2019 22:12:22 +0000 (UTC) Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH 2/2] docker: Fix travis script unable to find source dir X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, philmd@redhat.com, alex.bennee@linaro.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" The script generated from QEMU_SRC/.travis.yml uses BUILD_DIR and SRC_DIR path relative to the current dir, unless these variables are exported in environment. Since commit 05790dafef1 BUILD_DIR is exported in the runner script, although SRC_DIR is not, so that make docker-travis fails becase the reference to source dir is wrong. So let's unset both BUILD_DIR and SRC_DIR before calling the script, given it is executed from the source dir already (as in Travis). Signed-off-by: Wainer dos Santos Moschetta Reviewed-by: Alex Benn=C3=A9e --- tests/docker/travis | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/docker/travis b/tests/docker/travis index d345393ced..47c03677d6 100755 --- a/tests/docker/travis +++ b/tests/docker/travis @@ -18,4 +18,5 @@ cmdfile=3D/tmp/travis_cmd_list.sh $QEMU_SRC/tests/docker/travis.py $QEMU_SRC/.travis.yml > $cmdfile chmod +x $cmdfile cd "$QEMU_SRC" +unset BUILD_DIR SRC_DIR $cmdfile --=20 2.20.1