From nobody Mon Nov 25 09:54:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; 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 ARC-Seal: i=1; a=rsa-sha256; t=1716531377; cv=none; d=zohomail.com; s=zohoarc; b=K1dYwuMIA0roe8a6ZNioW2KTjaaB0o4jQ9KEkSBYMfL4OfiS0B+9Zd4gfukeLa2zKO/0uRL4iiBpbbssTSjSXrmm/ks85wY1Q7sGWSULPDnAYCpZsmYJEIa8DNGR8yesxen1HU5ko5VEZTsxe3qmxlKqVDG/7fBK0mc+9AJycOw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1716531377; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=pvZbx7Qhc09keL1vmWRUuQcCdr8TgH4NHpQR9QL+77M=; b=YVqG5uwVavc5rUzHyJzwVHrGbkM9HwiTF+Zlj6ng5NvG49CuNVLQEM9vgGTBvEYi71SyaP4rpdRpt4d3vJ7ZBXZRZgf8rFSTVBM+FLzkry9TF2AGbET6PDzKuHPC0KVqQ+/xaspW6gTaIyi9eJf0qOfx0waobmp42wVEOuSW8ao= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; 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 Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1716531377536442.0367772869382; Thu, 23 May 2024 23:16:17 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sAOCS-0001zq-II; Fri, 24 May 2024 02:14:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sAOCQ-0001yI-Uh for qemu-devel@nongnu.org; Fri, 24 May 2024 02:14:42 -0400 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sAOCL-0001A5-VX for qemu-devel@nongnu.org; Fri, 24 May 2024 02:14:42 -0400 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6f8ec7e054dso374816b3a.2 for ; Thu, 23 May 2024 23:14:37 -0700 (PDT) Received: from sunil-pc.Dlink ([106.51.188.31]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-6f8fcbea487sm516106b3a.107.2024.05.23.23.14.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 May 2024 23:14:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ventanamicro.com; s=google; t=1716531276; x=1717136076; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=pvZbx7Qhc09keL1vmWRUuQcCdr8TgH4NHpQR9QL+77M=; b=an/m6vxEgS/i7AaLVIH3xDtOgKuzKgWnhYNvIoantypgBXGomjZSUXKMPq31YBEG0J Dg/W5Z7Am9bb5pQcp1KDYA8R9xrK9k5XMoPhdK07NKk50VKYK/9R2+98mdMK35pbJYWj +GKY6gIIsCkrz4+NnTWfx5t8EsQgPfqAwkTV97Dq2u2knoKrkerb+bSYiWFUoxRbvJJv vPO6JrNvM/EzpY+5jk2Fp8v2sCovqgZd02Fcf+XGoH/jaxgvM0Ei0KnGMwspj3M6S1El 9k9uf9mM1DqQvYrmfFVVxXo18PV6mzYxsQTA175tiEwy65TKXy1hkaoMKsHKfHGzAwqC 2yLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716531276; x=1717136076; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pvZbx7Qhc09keL1vmWRUuQcCdr8TgH4NHpQR9QL+77M=; b=CiFJqdQb1xeoF/HhVu7gNduNvzdmHY8EC8bs9XUWFOqMZ9LyksynVM85B1tcXilmQL D9e6kmug6jctShYmva6Ll9UeDmoM0xgM/B3mJ/5s0/vIPbzpApDobG2NesNifnu5V/2m 2x0z0Uv4z7BWviONPZxdSz5Sbua5hJLKr9blikdr/hSj6x7s2VOnH5e8/S9RwERD5w4H RkpA7a0GaV0VDPFM+zCo4Aum6zK/PYrgvmkiOhMn2mWOyknSayOG6woXAjawG9d50XRD gbQrwCp7RXYWIQxl9kOe8LpSfb4R7dv7gNasxwoENgM5T1izaVJpv6NmHmwctD21FLaR 0DIQ== X-Gm-Message-State: AOJu0Yx8BacyFyMXkHiCiZUhv9RxRZH9NdVnV9y3zH+ka9LULTGPlAAJ K3xnCyjGHBXqFsI6sVeCwzStLb7sdWSzztN3rJ8793RGAeX1UDnbb47QEMuMG75RLtZ9Usxfkfq eY9I= X-Google-Smtp-Source: AGHT+IE0VtEQHAXXltI1LnNBbMSVq9ysw24hlBqNXrWEtwVuuVlX69Z3K62gkYO1lVdLIRCRe8gE8g== X-Received: by 2002:a05:6a00:301c:b0:6ec:f712:8a69 with SMTP id d2e1a72fcca58-6f8f3d6e6b3mr1647997b3a.29.1716531275758; Thu, 23 May 2024 23:14:35 -0700 (PDT) From: Sunil V L To: qemu-devel@nongnu.org, qemu-arm@nongnu.org, qemu-riscv@nongnu.org Cc: Paolo Bonzini , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Daniel=20P=20=2E=20Berrang=C3=A9?= , Thomas Huth , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , "Michael S . Tsirkin" , Igor Mammedov , Ani Sinha , Laurent Vivier , Gerd Hoffmann , Alistair Francis , Sia Jee Heng , Haibo1 Xu , Anup Patel , Andrew Jones , Daniel Henrique Barboza , Peter Maydell , Palmer Dabbelt , Bin Meng , Weiwei Li , Liu Zhiwei , Sunil V L Subject: [PATCH v2 02/12] uefi-test-tools: Add support for python based build script Date: Fri, 24 May 2024 11:44:01 +0530 Message-Id: <20240524061411.341599-3-sunilvl@ventanamicro.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240524061411.341599-1-sunilvl@ventanamicro.com> References: <20240524061411.341599-1-sunilvl@ventanamicro.com> MIME-Version: 1.0 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=2607:f8b0:4864:20::432; envelope-from=sunilvl@ventanamicro.com; helo=mail-pf1-x432.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham 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-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @ventanamicro.com) X-ZM-MESSAGEID: 1716531378356100005 Content-Type: text/plain; charset="utf-8" edk2-funcs.sh which is used in this Makefile, was removed in the commit c28a2891f3 ("edk2: update build script"). It is replaced with a python based script. So, update the Makefile and add the configuration file as required to support the python based build script. Signed-off-by: Sunil V L --- tests/uefi-test-tools/Makefile | 19 +++---- tests/uefi-test-tools/uefi-test-build.config | 52 ++++++++++++++++++++ 2 files changed, 59 insertions(+), 12 deletions(-) create mode 100644 tests/uefi-test-tools/uefi-test-build.config diff --git a/tests/uefi-test-tools/Makefile b/tests/uefi-test-tools/Makefile index 0c003f2877..f4eaebd8ff 100644 --- a/tests/uefi-test-tools/Makefile +++ b/tests/uefi-test-tools/Makefile @@ -12,7 +12,7 @@ =20 edk2_dir :=3D ../../roms/edk2 images_dir :=3D ../data/uefi-boot-images -emulation_targets :=3D arm aarch64 i386 x86_64 +emulation_targets :=3D arm aarch64 i386 x86_64 riscv64 uefi_binaries :=3D bios-tables-test intermediate_suffixes :=3D .efi .fat .iso.raw =20 @@ -56,7 +56,8 @@ Build/%.iso.raw: Build/%.fat # stripped from, the argument. map_arm_to_uefi =3D $(subst arm,ARM,$(1)) map_aarch64_to_uefi =3D $(subst aarch64,AA64,$(call map_arm_to_uefi,$(1))) -map_i386_to_uefi =3D $(subst i386,IA32,$(call map_aarch64_to_uefi,$(1))) +map_riscv64_to_uefi =3D $(subst riscv64,RISCV64,$(call map_aarch64_to_uefi= ,$(1))) +map_i386_to_uefi =3D $(subst i386,IA32,$(call map_riscv64_to_uefi,$(1))) map_x86_64_to_uefi =3D $(subst x86_64,X64,$(call map_i386_to_uefi,$(1))) map_to_uefi =3D $(subst .,,$(call map_x86_64_to_uefi,$(1))) =20 @@ -70,7 +71,7 @@ Build/%.fat: Build/%.efi uefi_bin_b=3D$$(stat --format=3D%s -- $<) && \ uefi_fat_kb=3D$$(( (uefi_bin_b * 11 / 10 + 1023) / 1024 )) && \ uefi_fat_kb=3D$$(( uefi_fat_kb >=3D 64 ? uefi_fat_kb : 64 )) && \ - mkdosfs -C $@ -n $(basename $(@F)) -- $$uefi_fat_kb + mkdosfs -C $@ -n "bios-test" -- $$uefi_fat_kb MTOOLS_SKIP_CHECK=3D1 mmd -i $@ ::EFI MTOOLS_SKIP_CHECK=3D1 mmd -i $@ ::EFI/BOOT MTOOLS_SKIP_CHECK=3D1 mcopy -i $@ -- $< \ @@ -95,15 +96,9 @@ Build/%.fat: Build/%.efi # we must mark the recipe manually as recursive, by using the "+" indicato= r. # This way, when the inner "make" starts a parallel build of the target ed= k2 # module, it can communicate with the outer "make"'s job server. -Build/bios-tables-test.%.efi: build-edk2-tools - +./build.sh $(edk2_dir) BiosTablesTest $* $@ - -build-edk2-tools: - cd $(edk2_dir)/BaseTools && git submodule update --init --force - $(MAKE) -C $(edk2_dir)/BaseTools \ - PYTHON_COMMAND=3D$${EDK2_PYTHON_COMMAND:-python3} \ - EXTRA_OPTFLAGS=3D'$(EDK2_BASETOOLS_OPTFLAGS)' \ - EXTRA_LDFLAGS=3D'$(EDK2_BASETOOLS_LDFLAGS)' +Build/bios-tables-test.%.efi: + $(PYTHON) ../../roms/edk2-build.py --config uefi-test-build.config \ + --match $* =20 clean: rm -rf Build Conf log diff --git a/tests/uefi-test-tools/uefi-test-build.config b/tests/uefi-test= -tools/uefi-test-build.config new file mode 100644 index 0000000000..1f389ae541 --- /dev/null +++ b/tests/uefi-test-tools/uefi-test-build.config @@ -0,0 +1,52 @@ +[global] +core =3D ../../roms/edk2 + +##########################################################################= ########## +# arm + +[build.arm] +conf =3D UefiTestToolsPkg/UefiTestToolsPkg.dsc +plat =3D UefiTestTools +dest =3D ./Build +arch =3D ARM +cpy1 =3D ARM/BiosTablesTest.efi bios-tables-test.arm.efi + +##########################################################################= ########## +# aarch64 + +[build.aarch64] +conf =3D UefiTestToolsPkg/UefiTestToolsPkg.dsc +plat =3D UefiTestTools +dest =3D ./Build +arch =3D AARCH64 +cpy1 =3D AARCH64/BiosTablesTest.efi bios-tables-test.aarch64.efi + +##########################################################################= ########## +# riscv64 + +[build.riscv] +conf =3D UefiTestToolsPkg/UefiTestToolsPkg.dsc +plat =3D UefiTestTools +dest =3D ./Build +arch =3D RISCV64 +cpy1 =3D RISCV64/BiosTablesTest.efi bios-tables-test.riscv64.efi + +##########################################################################= ########## +# ia32 + +[build.ia32] +conf =3D UefiTestToolsPkg/UefiTestToolsPkg.dsc +plat =3D UefiTestTools +dest =3D ./Build +arch =3D IA32 +cpy1 =3D IA32/BiosTablesTest.efi bios-tables-test.i386.efi + +##########################################################################= ########## +# x64 + +[build.x64] +conf =3D UefiTestToolsPkg/UefiTestToolsPkg.dsc +plat =3D UefiTestTools +dest =3D ./Build +arch =3D X64 +cpy1 =3D X64/BiosTablesTest.efi bios-tables-test.x86_64.efi --=20 2.40.1