From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=hzbY3T58; spf=pass (domain: linaro.org, ip: 209.85.221.67, mailfrom: leif.lindholm@linaro.org) Received: from mail-wr1-f67.google.com (mail-wr1-f67.google.com [209.85.221.67]) by groups.io with SMTP; Tue, 27 Aug 2019 05:43:54 -0700 Received: by mail-wr1-f67.google.com with SMTP id u16so18671058wrr.0 for ; Tue, 27 Aug 2019 05:43:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=L+H5mjgaoLSWPy4AZXeOjsMXYDR4zQsnmeIu4b9BgAY=; b=hzbY3T588ih22dqkj30jYZHhYp1F4wotL/FATXR5VSE6Fs2QuELUhwMqH51X65P7Qj 7Zs1knvTTHYzAHt9/yIu8zAi/e1ICXAmQlx7EaKjiMl+P+Q2H3q9XLAmsjq8mNppoHXh GheXW3v/IhAZN//jBg1hWdzXB7L2C+4HrS2eI7Hpgio3AFKs/JuVOmzfjrruCDc2xZ+R bLWUekmuSSrKuYijBG8VPOUX96DcXFGXLLPZKsJ1+/+rmXypD4R+k5XLiUZGmBBsdfRS EZMvygm+5H5u6dqCGBRr642U37Cn5p53bmmUIz7zazBAN1JkGFEjTmLPTigNxu4/hJ3L Tdzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=L+H5mjgaoLSWPy4AZXeOjsMXYDR4zQsnmeIu4b9BgAY=; b=pzG+tXnxo2D8dkMN4AoJfOj4tBYs/ZmU1n2CgEySxhOhvuEGdlH1xhqofaj3jHCGxw I8xJul1/WteZKt1mJ1Oqm1QpXSN1fwAhPLaYqVF7NM8qjwo98YhP8kj1vebaiSD36dyB HNqnVywTxhiPh/RtqDXaQR884OVDA93Tyh/Y9eV9jhDRG0thdu/yrxfNx2hebmyW6yJr 2Mwl6Ud2dSu2VWoRFNlln1Xc9tEWMXp5O084ipSsOAYqx7xcFXyuRecSQzFXzTkf1ZWF 4AuQ0MhdrpPiFhWqB+FHYGpZc0s0Ed79kzKLthZDnYSIIaan31xusqQ9kLd9SeNzjO6h THUw== X-Gm-Message-State: APjAAAWMZKT3EaJa/wlzZJGPME+Y8CGb+K8cSdr6+BjT0TVa21eJZOjb 3epr0fbSMLi3yz9oa/TaUR81LvOM0ldcIA== X-Google-Smtp-Source: APXvYqyNfSfiqJZHrtefeaHLIs5M3lrY7v3PIID8EsFPkOKrv5+d7lH1a6CvwRKc2DMnyj2DXoE6Ag== X-Received: by 2002:adf:ce8d:: with SMTP id r13mr28846035wrn.37.1566909832084; Tue, 27 Aug 2019 05:43:52 -0700 (PDT) Return-Path: Received: from urvogel.hemma.eciton.net (cpc92302-cmbg19-2-0-cust304.5-4.cable.virginm.net. [82.1.209.49]) by smtp.gmail.com with ESMTPSA id a18sm18865540wrt.18.2019.08.27.05.43.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Aug 2019 05:43:51 -0700 (PDT) From: "Leif Lindholm" To: devel@edk2.groups.io Cc: Andrew Fish , Laszlo Ersek , Michael D Kinney , Baptiste Gerondeau , Jian J Wang , Hao A Wu Subject: [PATCH 1/1] MdeModulePkg: fix !x86 builds (more) Date: Tue, 27 Aug 2019 13:43:28 +0100 Message-Id: <20190827124328.9034-1-leif.lindholm@linaro.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Commit 4a1f6b85c184 ("MdeModulePkg: add LockBoxNullLib for !IA32/X64 in .dsc") added an ARM/AARCH64 resolution for LockBoxLib. However, this failed to address the overrides provided for PEIM, DXE_DRIVER, DXE_RUNTIME_DRIVER, DXE_SMM_DRIVER and UEFI_DRIVER, so any modules of those classes still failed to build. Break these out properly into their own LibraryClasses sections. Resolves BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2134 Signed-off-by: Leif Lindholm Reported-by: Baptiste Gerondeau Cc: Jian J Wang Cc: Hao A Wu --- I don't understand how the above would appear to work back when I submitted the previous patch but not work now, but I haven't dug into it deeper. Including the x86-specific LockBoxLib in the .common section is however clearly not correct. I think a fix for this issue needs to go into 2019.08, but if someone has a prettier suggestion, I am not wedded to this one. MdeModulePkg/MdeModulePkg.dsc | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/MdeModulePkg/MdeModulePkg.dsc b/MdeModulePkg/MdeModulePkg.dsc index 4320839abfb5..15ba96cecbed 100644 --- a/MdeModulePkg/MdeModulePkg.dsc +++ b/MdeModulePkg/MdeModulePkg.dsc @@ -109,6 +109,8 @@ [LibraryClasses.common.PEIM] HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf ExtractGuidedSectionLib|MdePkg/Library/PeiExtractGuidedSectionLib/PeiExtractGuidedSectionLib.inf + +[LibraryClasses.IA32.PEIM,LibraryClasses.X64.PEIM] LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf [LibraryClasses.common.DXE_CORE] @@ -118,18 +120,22 @@ [LibraryClasses.common.DXE_CORE] [LibraryClasses.common.DXE_DRIVER] HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf - LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf ExtractGuidedSectionLib|MdePkg/Library/DxeExtractGuidedSectionLib/DxeExtractGuidedSectionLib.inf CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf +[LibraryClasses.IA32.DXE_DRIVER,LibraryClasses.X64.DXE_DRIVER] + LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf + [LibraryClasses.common.DXE_RUNTIME_DRIVER] HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf - LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibFmp/DxeRuntimeCapsuleLib.inf +[LibraryClasses.IA32.DXE_RUNTIME_DRIVER,LibraryClasses.X64.DXE_RUNTIME_DRIVER] + LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf + [LibraryClasses.common.SMM_CORE] HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf MemoryAllocationLib|MdeModulePkg/Library/PiSmmCoreMemoryAllocationLib/PiSmmCoreMemoryAllocationLib.inf @@ -143,13 +149,17 @@ [LibraryClasses.common.DXE_SMM_DRIVER] MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllocationLib.inf MmServicesTableLib|MdePkg/Library/MmServicesTableLib/MmServicesTableLib.inf SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServicesTableLib.inf + SmmMemLib|MdePkg/Library/SmmMemLib/SmmMemLib.inf + +[LibraryClasses.IA32.DXE_SMM_DRIVER,LibraryClasses.X64.DXE_SMM_DRIVER] LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf - SmmMemLib|MdePkg/Library/SmmMemLib/SmmMemLib.inf [LibraryClasses.common.UEFI_DRIVER] HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf + +[LibraryClasses.IA32.UEFI_DRIVER,LibraryClasses.X64.UEFI_DRIVER] LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf [LibraryClasses.common.UEFI_APPLICATION] -- 2.20.1