]> xenbits.xensource.com Git - ovmf.git/commitdiff
ArmVirtPkg: allow setting Firmware Version from build command line
authorOliver Steffen <osteffen@redhat.com>
Fri, 14 Apr 2023 08:33:23 +0000 (10:33 +0200)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Thu, 4 May 2023 14:26:58 +0000 (14:26 +0000)
ArmVirtXen.dsc initializes
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString with with the
value of the variable "FIRMWARE_VER".

Move that functionality to ArmVirt.dsc.inc to make it available to all
ArmVirt packages, and make it conditional: only set the PCD string if
FIRMWARE_VER is actually defined.

This allows specifying the firmware version string on the build command
line with -D FIRMARE_VER=...

Signed-off-by: Oliver Steffen <osteffen@redhat.com>
Reviewed-by: Sami Mujawar <sami.mujawar@arm.com>
ArmVirtPkg/ArmVirt.dsc.inc
ArmVirtPkg/ArmVirtXen.dsc

index 5b18184be2631ce6d158b471c055af9e6e07f4a0..2443e8351c99eadb5b3cb33c012517f3606a766d 100644 (file)
   gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE\r
 \r
 [PcdsFixedAtBuild.common]\r
+!ifdef $(FIRMWARE_VER)\r
+  gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString|L"$(FIRMWARE_VER)"\r
+!endif\r
+\r
   gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000\r
   gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000\r
   gEfiMdePkgTokenSpaceGuid.PcdMaximumLinkedListLength|0\r
index 58088af6ea3ae8cee7780283139ae216fd20c49e..a280ae203bae6875aa3f32c9dfd4a41af03ed6da 100644 (file)
@@ -69,7 +69,6 @@
 ################################################################################\r
 \r
 [PcdsFixedAtBuild.common]\r
-  gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString|L"$(FIRMWARE_VER)"\r
 !if $(ARCH) == AARCH64\r
   gArmTokenSpaceGuid.PcdVFPEnabled|1\r
 !endif\r