1
0
mirror of https://git.yoctoproject.org/meta-arm synced 2026-01-11 15:00:39 +00:00

arm/edk2-firmware: add version to be printed out

Currently, the version number is not being specified, which is causing
the version to be printed as an empty string.  Such as:
    UEFI firmware (version  built at 00:50:36 on Feb 21 2025)
and
    Tianocore/EDK2 firmware version

Add the package version as the version to be printed out, which results
in:
    UEFI firmware (version 202502 built at 00:50:36 on Feb 21 2025)
and
    Tianocore/EDK2 firmware version 202502

An intermediate variable was used instead of PV to allow for the
variable to be overridden if necessary.

Also, minor white space clean-up to match the style in the rest of the
file.

Signed-off-by: Jon Mason <jon.mason@arm.com>
This commit is contained in:
Jon Mason
2025-04-04 10:43:38 -04:00
parent ca97d0fcec
commit ce4c7f6661

View File

@@ -22,7 +22,7 @@ SRC_URI = "\
${SRC_URI_EDK2_PLATFORMS};branch=${SRCBRANCH_edk2_platforms};name=edk2-platforms;destsuffix=edk2/edk2-platforms \
"
SRCREV_FORMAT = "edk2_edk2-platforms"
SRCREV_FORMAT = "edk2_edk2-platforms"
UPSTREAM_CHECK_GITTAGREGEX = "^edk2-stable(?P<pver>\d+)$"
COMPATIBLE_MACHINE ?= "invalid"
@@ -42,6 +42,9 @@ EDK2_ARCH:x86 = "IA32"
EDK2_ARCH:x86-64 = "X64"
EDK2_ARCH:riscv64 = "RISCV64"
# Use the package version as the version to be printed out but allow for it to be overridden
EDK2_VERSION ?= "${PV}"
# Extra arguments passed to build
EDK2_EXTRA_BUILD = ""
@@ -115,6 +118,7 @@ do_compile() {
--tagname ${EDK_COMPILER} \
--platform ${EDK2_PLATFORM_DSC} \
${@oe.utils.parallel_make_argument(d, "-n %d")} \
-D FIRMWARE_VER="${EDK2_VERSION}" \
${EDK2_EXTRA_BUILD}
}