From nobody Tue Feb 10 04:15:20 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1657664537; cv=none; d=zohomail.com; s=zohoarc; b=mb7/fKDIEUFQCk4UuazgI+4nAbGxNxIno8pqOclQ5OLNrfLzRK6tCJKqMyCkM18ViwR5ZIBmrRfWpSStQxQZeWQbFyyAub9+FRtQQSnn0Y5ivy2hz+q48r+/mlD7XCzxxBXmuCLhfk9HZV/b/eUsAsjzY66rRtj+WHKJ444F2Q0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1657664537; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=kNSwwLUlb4TjazJWbInH85IZYRihokDtaxUvDxQfVGw=; b=VIljXV/pMrU+v8RiPoJP357KFC78KDtblHPCR9LHxUc05taOSuQdbaIaXzpVTZLGCGb95Z7SnBlH1e7PJdCYJLRVPaxtn42/5SN5IclVWRQn5zzE81qgmsGe7mWIczO6vtgYZWynu2zkrAp37gnl2fumumcDneOVaOXvG3W+FW0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1657664537314876.8469121667025; Tue, 12 Jul 2022 15:22:17 -0700 (PDT) Received: from localhost ([::1]:41316 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oBOGm-0007wU-74 for importer@patchew.org; Tue, 12 Jul 2022 18:22:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47140) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oBOBe-0007wu-Hq for qemu-devel@nongnu.org; Tue, 12 Jul 2022 18:16:58 -0400 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:56114) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oBOBd-0002W1-1Q for qemu-devel@nongnu.org; Tue, 12 Jul 2022 18:16:58 -0400 Received: by mail-wm1-x32c.google.com with SMTP id l42so5428406wms.5 for ; Tue, 12 Jul 2022 15:16:56 -0700 (PDT) Received: from localhost.localdomain ([185.126.107.38]) by smtp.gmail.com with ESMTPSA id x4-20020adfdd84000000b0021d7f032022sm9258680wrl.17.2022.07.12.15.16.54 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 12 Jul 2022 15:16:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=kNSwwLUlb4TjazJWbInH85IZYRihokDtaxUvDxQfVGw=; b=aXaRkxGuky9dWr7wLOcLG3Qv5yAzQFzMDrDz3na2GFUg6S/xavmkjXFJqfArXrLcWH PueATxn3udioZjtwGM2k6fW/eld76R+oIw4h+6Ml328uwRJ4zxbLOAcaeK+JqQ6+Vl1Y Rqd6eLGQS8qEmpMedyT08J8857ZAkkZiK/1PvniElRgTf2on9zZqkqg72QeyHX9ju8+k aw33VV8DIA3VVRZMmWLnlSBK/uGDsNhvolxkrdBHOjfoO99EWr+Hw/+sMugypBzSO/z5 GuDWJ8TAZ+d750H/tWfY2jBehltm45ZpRBbNmKH/Qm9h5e3II1OaIX99sAOuLC3mJN17 fTig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=kNSwwLUlb4TjazJWbInH85IZYRihokDtaxUvDxQfVGw=; b=bNzxydxr0Ecr+JZHSSEJwwONMEsjeZCoDy14p3WEimj/QzRrKU8+K53QeANa/ll7FQ eyEtNwgTwJFdqX3uNvYbVD2LCjAVtuw2xMyMvc78qfPtCt6Xtbex7EIAmwqOc5ICM2IO xeWErtv2WILiKXnEoh0/Eq1RcYyhCmyVZOsGydeMv1rF8isGY1Rctvg7Uzf1Rp4k1cf8 qJlGWPAKi/sZwceC/GP2WSKfRQ4DsnvAYv+mzdecdNMAdZQSBRkO6G32KfTqdr41rcKy xPMlaNgZpVX0peVvuTyRyAlYVCNeZaZHfzkOypto8cUTE9FR/qlhThbml1+JFS3z9dgR xGjA== X-Gm-Message-State: AJIora+SeYu28ZnxlGravlzqJvu22pcPb8wEZpTZsZj2KbEXQf5fFg4h +WhvBndvbetbGhsetPkJV6gdbyEWyAhcpV9i X-Google-Smtp-Source: AGRyM1vPxNW2EsSrR6U2SwExhHijQjSt0W5gLuUTO511wlEJ0aKgFU+820TIvTgWz+ob+PA60zbQww== X-Received: by 2002:a05:600c:4fc9:b0:3a0:4d54:b315 with SMTP id o9-20020a05600c4fc900b003a04d54b315mr217598wmq.62.1657664215496; Tue, 12 Jul 2022 15:16:55 -0700 (PDT) To: qemu-devel@nongnu.org Cc: Roman Bolshakov , Akihiko Odaki , Thomas Huth , Cameron Esfahani , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Peter Delevoryas Subject: [PULL 5/5] avocado: Fix BUILD_DIR if it's equal to SOURCE_DIR Date: Wed, 13 Jul 2022 00:16:07 +0200 Message-Id: <20220712221607.9933-6-f4bug@amsat.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220712221607.9933-1-f4bug@amsat.org> References: <20220712221607.9933-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.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; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wm1-x32c.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Reply-to: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= via X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1657664537962100001 From: Peter Delevoryas I like to build QEMU from the root source directory [*], rather than cd'ing into the build directory. This code may as well include a search path for that, so that you can run avocado tests individually without specifying "-p qemu_bin=3Dbuild/qemu-system-arm" manually. [*] See commit dedad02720 ("configure: add support for pseudo-"in source tr= ee" builds") Signed-off-by: Peter Delevoryas Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20220702185604.46643-1-peter@pjd.dev> [PMD: Mention commit dedad02720] Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- tests/avocado/avocado_qemu/__init__.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/tests/avocado/avocado_qemu/__init__.py b/tests/avocado/avocado= _qemu/__init__.py index b656a70c55..ed4853c805 100644 --- a/tests/avocado/avocado_qemu/__init__.py +++ b/tests/avocado/avocado_qemu/__init__.py @@ -120,14 +120,15 @@ def pick_default_qemu_bin(bin_prefix=3D'qemu-system-'= , arch=3DNone): # qemu binary path does not match arch for powerpc, handle it if 'ppc64le' in arch: arch =3D 'ppc64' - qemu_bin_relative_path =3D os.path.join(".", bin_prefix + arch) - if is_readable_executable_file(qemu_bin_relative_path): - return qemu_bin_relative_path - - qemu_bin_from_bld_dir_path =3D os.path.join(BUILD_DIR, - qemu_bin_relative_path) - if is_readable_executable_file(qemu_bin_from_bld_dir_path): - return qemu_bin_from_bld_dir_path + qemu_bin_name =3D bin_prefix + arch + qemu_bin_paths =3D [ + os.path.join(".", qemu_bin_name), + os.path.join(BUILD_DIR, qemu_bin_name), + os.path.join(BUILD_DIR, "build", qemu_bin_name), + ] + for path in qemu_bin_paths: + if is_readable_executable_file(path): + return path return None =20 =20 --=20 2.36.1