summaryrefslogtreecommitdiffstats
path: root/EmulatorPkg/EmulatorPkg.dsc
diff options
context:
space:
mode:
authorLiming Gao <liming.gao@intel.com>2019-10-17 14:55:54 +0800
committerLiming Gao <liming.gao@intel.com>2019-10-24 09:41:34 +0800
commit2737037a417a97de8153ebc5e4556bdf38f765c6 (patch)
tree723c01e10795c9a7e2bda35c00c00293af27cd77 /EmulatorPkg/EmulatorPkg.dsc
parent933681b2084435ec2744e7042e3864cabd4fa879 (diff)
downloadedk2-2737037a417a97de8153ebc5e4556bdf38f765c6.tar.gz
edk2-2737037a417a97de8153ebc5e4556bdf38f765c6.tar.bz2
edk2-2737037a417a97de8153ebc5e4556bdf38f765c6.zip
EmulatorPkg: Enable CLANG9 tool chain
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1603 1. Add WIN_HOST_BUILD macro check for CLANG9 tool chain build -p EmulatorPkg\EmulatorPkg.dsc -a IA32 -DWIN_HOST_BUILD=TRUE -t CLANG9 build -p EmulatorPkg\EmulatorPkg.dsc -a X64 -DWIN_HOST_BUILD=TRUE -t CLANG9 2. Append CLANG CC and LINK flags to generate windows HOST. 3. Fix WinHost issue to call GetProcessAffinityMask() API. The input parameter should be UINTN pointer instead of UINT32 pointer. Cc: Jordan Justen <jordan.l.justen@intel.com> Cc: Andrew Fish <afish@apple.com> Cc: Ray Ni <ray.ni@intel.com> Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com>
Diffstat (limited to 'EmulatorPkg/EmulatorPkg.dsc')
-rw-r--r--EmulatorPkg/EmulatorPkg.dsc14
1 files changed, 13 insertions, 1 deletions
diff --git a/EmulatorPkg/EmulatorPkg.dsc b/EmulatorPkg/EmulatorPkg.dsc
index 20f1187713..109685b062 100644
--- a/EmulatorPkg/EmulatorPkg.dsc
+++ b/EmulatorPkg/EmulatorPkg.dsc
@@ -237,9 +237,11 @@
[Components]
!if "IA32" in $(ARCH) || "X64" in $(ARCH)
- !if "MSFT" in $(FAMILY)
+ !if "MSFT" in $(FAMILY) || $(WIN_HOST_BUILD) == TRUE
##
# Emulator, OS WIN application
+ # CLANG9 is cross OS tool chain. It depends on WIN_HOST_BUILD flag
+ # to build WinHost application.
##
EmulatorPkg/Win/Host/WinHost.inf
!else
@@ -419,7 +421,17 @@
MSFT:DEBUG_*_*_CC_FLAGS = /Od /Oy-
MSFT:NOOPT_*_*_CC_FLAGS = /Od /Oy-
+ GCC:DEBUG_CLANG9_*_CC_FLAGS =-O0 -Wno-unused-command-line-argument -Wno-incompatible-pointer-types -Wno-enum-conversion -Wno-incompatible-pointer-types -Wno-sometimes-uninitialized -Wno-constant-conversion -Wno-main-return-type
MSFT:*_*_*_DLINK_FLAGS = /ALIGN:4096 /FILEALIGN:4096 /SUBSYSTEM:CONSOLE
MSFT:DEBUG_*_*_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /BASE:0x10000
MSFT:NOOPT_*_*_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /BASE:0x10000
+
+!if $(WIN_HOST_BUILD) == TRUE
+ #
+ # CLANG9 tool chain depends on WIN_HOST_BUILD flag to generate the windows application.
+ #
+ GCC:*_CLANG9_*_DLINK_FLAGS = /ALIGN:4096 /FILEALIGN:4096 /SUBSYSTEM:CONSOLE
+ GCC:DEBUG_CLANG9_*_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /BASE:0x10000
+ GCC:NOOPT_CLANG9_*_DLINK_FLAGS = /EXPORT:InitializeDriver=$(IMAGE_ENTRY_POINT) /BASE:0x10000
+!endif