From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id F360B740032 for ; Sat, 10 Feb 2024 02:27:25 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=ZWiOcGwMXrBVEimEfcp3ncIFXtFsMMEyVq2EIkZ9Tq0=; c=relaxed/simple; d=groups.io; h=DKIM-Filter:Message-ID:Date:MIME-Version:User-Agent:Subject:To:Cc:References:From:In-Reply-To:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20140610; t=1707532044; v=1; b=Nbvav4N8jgOmVSURQTyM1PGsuHCY0ufFQydS2LVHnGKX0HLqOWfQLALW97olShqnSRuWmYKw OmUbM4phVLk/0p+GlsNmxiE4BrL30yXI27qaje20cSnkeAuRxcCJFfaCIuOhe1uwSeihji5ENlH a1n5TVpRHnls6UZchq+ouFYM= X-Received: by 127.0.0.2 with SMTP id V0xrYY7687511xGYOJYWLxzK; Fri, 09 Feb 2024 18:27:24 -0800 X-Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mx.groups.io with SMTP id smtpd.web11.6043.1707532043927199875 for ; Fri, 09 Feb 2024 18:27:24 -0800 X-Received: from [10.0.0.154] (unknown [20.39.63.13]) by linux.microsoft.com (Postfix) with ESMTPSA id 2FC36207EB07; Fri, 9 Feb 2024 18:27:23 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 2FC36207EB07 Message-ID: <9eea86e6-f105-4383-9f00-3826f7400162@linux.microsoft.com> Date: Fri, 9 Feb 2024 21:26:27 -0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [edk2-devel] [edk2-stable202402][Patch V3 2/7] UnitTestFrameworkPkg: MSFT CC_FLAGS add /MT to for host builds To: devel@edk2.groups.io, michael.d.kinney@intel.com Cc: Sean Brogan References: <20240209203253.488-1-michael.d.kinney@intel.com> <20240209203253.488-3-michael.d.kinney@intel.com> From: "Michael Kubacki" In-Reply-To: <20240209203253.488-3-michael.d.kinney@intel.com> Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,mikuback@linux.microsoft.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: aeYiTwSUCjEE0SfwH5L4B2Knx7686176AA= Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=Nbvav4N8; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=linux.microsoft.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io Did this patch intend to swap /EHsc with /EHs? It looks like that was=20 planned for patch 3/7. On 2/9/2024 3:32 PM, Michael D Kinney wrote: > Add /MT to MSFT CC_FLAGS to always use release libraries > when building host-based unit tests so any exceptions > generated during host-based test execution generate an > error message in stderr instead of a popup window. >=20 > Use /MTd when -D UNIT_TESTING_DEBUG is to use debug > libraries when building host-based unit tests so any > exceptions generated during host-based test execution > generate a popup window with option to attach a debugger. >=20 > Cc: Michael Kubacki > Cc: Sean Brogan > Signed-off-by: Michael D Kinney > --- > UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf | 2 +- > UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc | 3 ++- > 2 files changed, 3 insertions(+), 2 deletions(-) >=20 > diff --git a/UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf= b/UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf > index 0104384953c3..bdab98a54f0e 100644 > --- a/UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf > +++ b/UnitTestFrameworkPkg/Library/GoogleTestLib/GoogleTestLib.inf > @@ -28,6 +28,6 @@ [Packages] > UnitTestFrameworkPkg/UnitTestFrameworkPkg.dec > =20 > [BuildOptions] > - MSFT:*_*_*_CC_FLAGS =3D=3D /c /EHsc /Zi /Od > + MSFT:*_*_*_CC_FLAGS =3D=3D /c /EHs /Zi /Od /MT > GCC:*_*_IA32_CC_FLAGS =3D=3D -g -c -fshort-wchar -O0 -m32 > GCC:*_*_X64_CC_FLAGS =3D=3D -g -c -fshort-wchar -O0 -m64 > diff --git a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc b/Unit= TestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc > index b8068fd91c98..00f8d9a895be 100644 > --- a/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc > +++ b/UnitTestFrameworkPkg/UnitTestFrameworkPkgHost.dsc.inc > @@ -24,9 +24,10 @@ [LibraryClasses.common.HOST_APPLICATION] > PeiServicesTablePointerLib|UnitTestFrameworkPkg/Library/UnitTestPeiSe= rvicesTablePointerLib/UnitTestPeiServicesTablePointerLib.inf > =20 > [BuildOptions] > + MSFT:*_*_*_CC_FLAGS =3D /MT > GCC:*_*_*_CC_FLAGS =3D -fno-pie > !ifdef $(UNIT_TESTING_DEBUG) > - MSFT:*_*_*_CC_FLAGS =3D -D UNIT_TESTING_DEBUG=3D1 > + MSFT:*_*_*_CC_FLAGS =3D /MTd -D UNIT_TESTING_DEBUG=3D1 > GCC:*_*_*_CC_FLAGS =3D -D UNIT_TESTING_DEBUG=3D1 > XCODE:*_*_*_CC_FLAGS =3D -D UNIT_TESTING_DEBUG=3D1 > !endif -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#115342): https://edk2.groups.io/g/devel/message/115342 Mute This Topic: https://groups.io/mt/104267257/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-