From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web12.1231.1666972805331649628 for ; Fri, 28 Oct 2022 09:00:05 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=TW3CXNdq; spf=pass (domain: intel.com, ip: 134.134.136.31, mailfrom: michael.d.kinney@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1666972805; x=1698508805; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=39FOPCp/Q7C0y6EhF16v+3hc2pBHbyiEjOITv8rXDBw=; b=TW3CXNdq/IfIAiKIylPSTQ15NNoolMvof1uwWj+1wqN22pESakfEGfYa v7q0BkDNCd1RJw4owN4qxmcM1BJ4gNKBf3SiGgNvlxECCpY6lXeR2HKlj p4f1NMeji190AYG2fmn63qInAqtzRLMiacT3Rc1TZC0/aP8vO4zk2dk80 nSUabrOBAjUFHjDpP1dBOR3La87VJudxuHKm9BTYULrzgDvBBkY5K5gfe 3Phsf2cAYK1KvHRBOQOwRetQl+IiSR2nBDzRxUyNy6jsKK0n6HagteWAT VTlcEzQwi04mvN75t6wG80DnvQpxTt9CkeVAYi7dKE4zLaRhbXsL0dEwy Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10514"; a="370588726" X-IronPort-AV: E=Sophos;i="5.95,221,1661842800"; d="scan'208";a="370588726" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Oct 2022 08:59:53 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10514"; a="758122606" X-IronPort-AV: E=Sophos;i="5.95,221,1661842800"; d="scan'208";a="758122606" Received: from mdkinney-mobl2.amr.corp.intel.com ([10.209.104.243]) by orsmga004-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Oct 2022 08:59:52 -0700 From: "Michael D Kinney" To: devel@edk2.groups.io Cc: Michael Kubacki , Sean Brogan Subject: [Patch 1/1] UnitTestFrameworkPkg: Support FILE_GUID override in host based unit tests Date: Fri, 28 Oct 2022 08:59:47 -0700 Message-Id: <20221028155947.1172-1-michael.d.kinney@intel.com> X-Mailer: git-send-email 2.37.1.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Always use the module name with FILE_GUID to generate the host-based unit test executable image and symbol files. This allows the same host-based unit test INF file to be used more than once in a single DSC file with FILE_GUID override. This is valuable when there is a requirement to run the same host-based unit test with different PCD settings, library mappings, or build options. Cc: Michael Kubacki Cc: Sean Brogan Signed-off-by: Michael D Kinney --- UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc b/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc index 4dd8d4ac678a..f249813713a8 100644 --- a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc +++ b/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc @@ -30,7 +30,7 @@ [BuildOptions.common.EDKII.HOST_APPLICATION] # # MSFT # - MSFT:*_*_*_DLINK_FLAGS == /out:"$(BIN_DIR)\$(BASE_NAME).exe" /pdb:"$(BIN_DIR)\$(BASE_NAME).pdb" /IGNORE:4001 /NOLOGO /SUBSYSTEM:CONSOLE /DEBUG /STACK:0x40000,0x40000 /NODEFAULTLIB:libcmt.lib libcmtd.lib + MSFT:*_*_*_DLINK_FLAGS == /out:"$(BIN_DIR)\$(MODULE_NAME_GUID).exe" /pdb:"$(BIN_DIR)\$(MODULE_NAME_GUID).pdb" /IGNORE:4001 /NOLOGO /SUBSYSTEM:CONSOLE /DEBUG /STACK:0x40000,0x40000 /NODEFAULTLIB:libcmt.lib libcmtd.lib MSFT:*_*_IA32_DLINK_FLAGS = /MACHINE:I386 MSFT:*_*_X64_DLINK_FLAGS = /MACHINE:AMD64 @@ -47,8 +47,8 @@ [BuildOptions.common.EDKII.HOST_APPLICATION] # # GCC # - GCC:*_*_IA32_DLINK_FLAGS == -o $(BIN_DIR)/$(BASE_NAME) -m32 -no-pie - GCC:*_*_X64_DLINK_FLAGS == -o $(BIN_DIR)/$(BASE_NAME) -m64 -no-pie + GCC:*_*_IA32_DLINK_FLAGS == -o $(BIN_DIR)/$(MODULE_NAME_GUID) -m32 -no-pie + GCC:*_*_X64_DLINK_FLAGS == -o $(BIN_DIR)/$(MODULE_NAME_GUID) -m64 -no-pie GCC:*_*_*_DLINK2_FLAGS == -lgcov # @@ -56,10 +56,10 @@ [BuildOptions.common.EDKII.HOST_APPLICATION] # XCODE:*_*_IA32_DLINK_PATH == gcc XCODE:*_*_IA32_CC_FLAGS = -I$(WORKSPACE)/EmulatorPkg/Unix/Host/X11IncludeHack - XCODE:*_*_IA32_DLINK_FLAGS == -arch i386 -o $(BIN_DIR)/Host -L/usr/X11R6/lib -lXext -lX11 -framework Carbon + XCODE:*_*_IA32_DLINK_FLAGS == -arch i386 -o $(BIN_DIR)/$(MODULE_NAME_GUID) -L/usr/X11R6/lib -lXext -lX11 -framework Carbon XCODE:*_*_IA32_ASM_FLAGS == -arch i386 -g XCODE:*_*_X64_DLINK_PATH == gcc - XCODE:*_*_X64_DLINK_FLAGS == -o $(BIN_DIR)/Host -L/usr/X11R6/lib -lXext -lX11 -framework Carbon -Wl,-no_pie + XCODE:*_*_X64_DLINK_FLAGS == -o $(BIN_DIR)/$(MODULE_NAME_GUID) -L/usr/X11R6/lib -lXext -lX11 -framework Carbon -Wl,-no_pie XCODE:*_*_X64_ASM_FLAGS == -g XCODE:*_*_X64_CC_FLAGS = -O0 -target x86_64-apple-darwin -I$(WORKSPACE)/EmulatorPkg/Unix/Host/X11IncludeHack "-DEFIAPI=__attribute__((ms_abi))" -- 2.37.1.windows.1