From: "Sean" <spbrogan@outlook.com>
To: devel@edk2.groups.io, michael.d.kinney@intel.com
Cc: Michael Kubacki <mikuback@linux.microsoft.com>,
Sean Brogan <sean.brogan@microsoft.com>
Subject: Re: [edk2-devel] [Patch 1/1] UnitTestFrameworkPkg: Support FILE_GUID override in host based unit tests
Date: Mon, 31 Oct 2022 16:50:10 -0700 [thread overview]
Message-ID: <SA1PR19MB491160F65A2D3AEB7DCDC1D1C8379@SA1PR19MB4911.namprd19.prod.outlook.com> (raw)
In-Reply-To: <20221028155947.1172-1-michael.d.kinney@intel.com>
Look good. Good find.
reviewed-by: Sean Brogan <sean.brogan@microsoft.com>
On 10/28/2022 8:59 AM, Michael D Kinney wrote:
> 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>
> ---
> 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))"
next prev parent reply other threads:[~2022-10-31 23:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-28 15:59 [Patch 1/1] UnitTestFrameworkPkg: Support FILE_GUID override in host based unit tests Michael D Kinney
2022-10-31 23:50 ` Sean [this message]
2022-11-01 0:37 ` [edk2-devel] " Michael Kubacki
2022-11-01 0:37 ` Michael Kubacki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=SA1PR19MB491160F65A2D3AEB7DCDC1D1C8379@SA1PR19MB4911.namprd19.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox