diff options
author | Michael D Kinney <michael.d.kinney@intel.com> | 2022-10-28 08:41:34 -0700 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2022-11-01 14:44:04 +0000 |
commit | 85dba961c761021755cd2aa6bc98b8e789f751ef (patch) | |
tree | 97dcd42b1210b56aeba6944b0cdbfee90995bb08 | |
parent | 720c25ab41400f9a3dfd0742da5a6d237991df5b (diff) | |
download | edk2-85dba961c761021755cd2aa6bc98b8e789f751ef.zip edk2-85dba961c761021755cd2aa6bc98b8e789f751ef.tar.gz edk2-85dba961c761021755cd2aa6bc98b8e789f751ef.tar.bz2 |
UnitTestFrameworkPkg: Support FILE_GUID override in host based unit tests
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4129
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 <mikuback@linux.microsoft.com>
Cc: Sean Brogan <sean.brogan@microsoft.com>
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Michael Kubacki <mikuback@linux.microsoft.com>
Reviewed-by: Sean Brogan <sean.brogan@microsoft.com>
-rw-r--r-- | UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc b/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc index 4dd8d4a..f249813 100644 --- a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc +++ b/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc @@ -30,7 +30,7 @@ #
# 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 @@ #
# 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 @@ #
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))"
|