From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.groups.io with SMTP id smtpd.web11.6712.1665750873684543287 for ; Fri, 14 Oct 2022 05:34:34 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=FEodI2Mo; spf=pass (domain: redhat.com, ip: 170.10.133.124, mailfrom: osteffen@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1665750872; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=/XjeHaM9JMNU1NsuqnIKCfjhB33xjb2NlOvLTVx1yE8=; b=FEodI2MozRQmfkbdImF3guBNIVxz9ZKG6p2dp2al+IM8DZkYT74sHTd5sg1ZF5Lx7MxUwH rAQ7ZTW9jde8zdBPLwWW+Kvv6klPUpAzci26GkGpOkjCSWW/xvPGhOiNj/9ksqGQj62mwx Y3iunkRPt68FBpq/oc46h+WzL7Da5SE= Received: from mail-lf1-f71.google.com (mail-lf1-f71.google.com [209.85.167.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-556-jggRWZQ9OeCiz3wCgFLJIg-1; Fri, 14 Oct 2022 08:34:32 -0400 X-MC-Unique: jggRWZQ9OeCiz3wCgFLJIg-1 Received: by mail-lf1-f71.google.com with SMTP id s5-20020a056512214500b004a24e8c79ebso1555395lfr.0 for ; Fri, 14 Oct 2022 05:34:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:mime-version:references:in-reply-to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=/XjeHaM9JMNU1NsuqnIKCfjhB33xjb2NlOvLTVx1yE8=; b=JvunWiKUNyFf8RiwDdVAYDWu20mnNctspTbxO/GvXAcfbh4t2VfK2s7VrbM0j8S9Kr DkdsEuUXWvAFfSzIjsY/HVFKzbBXDiok+hZC8T9INdnbdhgwDRfqB1vJhzZbO100FU8d C2b6r1xF3Rel6bs9HNpSeNcIn4VKCgTDNOQCsufN6kC+1iLzMPxmrxI+0op6162BksHa e0hVX1ohJEvKw6PRzlA03LN/ewBrBaJz+Y0EZ6NEOnWrTy06xkU6oTawoBjdKiMG26JH lqLKtiKcxTwqQuFG27TfmTGsvme5wyXuUBCqlj3TkiN8JuDiH+Ww0MoKV4UPyyjSNQXf TXaA== X-Gm-Message-State: ACrzQf3q2MYqCvWjZvXZN7ZjR575lF3TcKqjJXWkeuFKX8c6daULH3qs OSWJkNuUH4XsqREZ6HR6W8KtsfDyeVbcmzLnB3gwf0cFKK84uQHGWEA7ellziOtPy+82y/1oTQV bbmzC2Bt+2EpjDSXzRg+Vt2lBFFsTfA== X-Received: by 2002:a05:6512:689:b0:4a2:5955:54fb with SMTP id t9-20020a056512068900b004a2595554fbmr1556510lfe.656.1665750869209; Fri, 14 Oct 2022 05:34:29 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6tsdAjLqHKq/L3a6jmGaumtDKnH1gcnfWSqnCP80JTHHbLuglc/hwgsxAYLghsHkXiwDj5GxEvZmYZxltHGw4= X-Received: by 2002:a05:6512:689:b0:4a2:5955:54fb with SMTP id t9-20020a056512068900b004a2595554fbmr1556483lfe.656.1665750869010; Fri, 14 Oct 2022 05:34:29 -0700 (PDT) Received: from 567203818698 named unknown by gmailapi.google.com with HTTPREST; Fri, 14 Oct 2022 05:34:28 -0700 From: "Oliver Steffen" X-Mailer: git-send-email 2.37.3 In-Reply-To: <20221014123408.302491-1-osteffen@redhat.com> References: <20221014123408.302491-1-osteffen@redhat.com> MIME-Version: 1.0 Date: Fri, 14 Oct 2022 05:34:28 -0700 Message-ID: Subject: [PATCH v2 2/2] ArmVirtPkg: allow setting Firmware Version from build command line To: devel@edk2.groups.io Cc: Anthony Perard , Ard Biesheuvel , Gerd Hoffmann , Jian J Wang , Jiewen Yao , Jordan Justen , Julien Grall , Leif Lindholm , Liming Gao , Ray Ni , Sami Mujawar , Zhichao Gao , Pawel Polawski , nd@arm.com, Oliver Steffen X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" 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 --- ArmVirtPkg/ArmVirt.dsc.inc | 4 ++++ ArmVirtPkg/ArmVirtXen.dsc | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ArmVirtPkg/ArmVirt.dsc.inc b/ArmVirtPkg/ArmVirt.dsc.inc index c39e2506a3ea..49e96c9fb91c 100644 --- a/ArmVirtPkg/ArmVirt.dsc.inc +++ b/ArmVirtPkg/ArmVirt.dsc.inc @@ -289,6 +289,10 @@ [PcdsFeatureFlag.AARCH64] gEfiMdeModulePkgTokenSpaceGuid.PcdInstallAcpiSdtProtocol|TRUE [PcdsFixedAtBuild.common] +!ifdef $(FIRMWARE_VER) + gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString|L"$(FIRMWARE_VER)" +!endif + gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000 gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000 gEfiMdePkgTokenSpaceGuid.PcdMaximumLinkedListLength|0 diff --git a/ArmVirtPkg/ArmVirtXen.dsc b/ArmVirtPkg/ArmVirtXen.dsc index 58088af6ea3a..a280ae203bae 100644 --- a/ArmVirtPkg/ArmVirtXen.dsc +++ b/ArmVirtPkg/ArmVirtXen.dsc @@ -69,7 +69,6 @@ [BuildOptions] ################################################################################ [PcdsFixedAtBuild.common] - gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString|L"$(FIRMWARE_VER)" !if $(ARCH) == AARCH64 gArmTokenSpaceGuid.PcdVFPEnabled|1 !endif -- 2.37.3