From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.93, mailfrom: liming.gao@intel.com) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by groups.io with SMTP; Fri, 26 Apr 2019 07:42:59 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Apr 2019 07:42:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,397,1549958400"; d="scan'208";a="145975671" Received: from lgao4-mobl1.ccr.corp.intel.com ([10.255.29.102]) by orsmga003.jf.intel.com with ESMTP; 26 Apr 2019 07:42:58 -0700 From: "Liming Gao" To: devel@edk2.groups.io Subject: [Patch 0/7] Add new CLANG8ELF tool chain for new LLVM/CLANG8 Date: Fri, 26 Apr 2019 22:42:35 +0800 Message-Id: <20190426144242.19024-1-liming.gao@intel.com> X-Mailer: git-send-email 2.16.2.windows.1 BZ:https://bugzilla.tianocore.org/show_bug.cgi?id=1603 LLVM/CLANG8 formal release http://releases.llvm.org/download.html#8.0.0 It can be downloaded and installed in Windows/Linux/Mac OS. CLANG8ELF tool chain is added to generate ELF image, and convert to PE/COFF. On Windows OS, set CLANG_HOST_BIN=n, set CLANG8_BIN=LLVM installed directory CLANG_HOST_BIN is used CLANG_HOST_PREFIX. Prefix n is for nmake. For example: set CLANG_HOST_BIN=n set CLANG8_BIN=C:\Program Files\LLVM\bin\ On Linux/Mac, export CLANG8_BIN=LLVM installed directory, CLANG_HOST_BIN is not required, because there is no prefix for make. For example: export CLANG8_BIN=/home/clang8/bin/ This tool chain can be used to compile the firmware code. On windows OS, Visual Studio is still required to compile BaseTools C tools and provide nmake.exe for makefile. On Linux/Mac OS, gcc is used to compile BaseTools C tools. make is used for makefile. This tool chain is verified on OVMF Ia32, X64 and Ia32X64 to boot Shell. This tool chain is verified in Windows/Linux and Mac OS. Liming Gao (7): BaseTools: Add ClangBase.lds for CLANG8 tool chain with max-page-size BaseTools GenFw: Support CLANG8ELF with conversion ELF to PE/COFF image BaseTools: Update build_rule.template for ASLC rule with full C flags BaseTools: Update build_rule to skip CLANG resource section generation BaseTools: Update tools_def.template to directly refer to AutoGen.h BaseTools: Add new CLANG8ELF tool chain for new LLVM/CLANG8 OvmfPkg: Update DSC/FDF to support CLANG8ELF tool chain BaseTools/Source/C/GenFw/Elf32Convert.c | 12 +--- BaseTools/Source/C/GenFw/Elf64Convert.c | 11 +-- BaseTools/Conf/build_rule.template | 8 +-- BaseTools/Conf/tools_def.template | 121 +++++++++++++++++++++++++++++--- BaseTools/Scripts/ClangBase.lds | 79 +++++++++++++++++++++ OvmfPkg/OvmfPkgIa32.dsc | 4 +- OvmfPkg/OvmfPkgIa32.fdf | 2 +- OvmfPkg/OvmfPkgIa32X64.dsc | 4 +- OvmfPkg/OvmfPkgIa32X64.fdf | 2 +- OvmfPkg/OvmfPkgX64.dsc | 4 +- OvmfPkg/OvmfPkgX64.fdf | 2 +- 11 files changed, 213 insertions(+), 36 deletions(-) create mode 100644 BaseTools/Scripts/ClangBase.lds -- 2.13.0.windows.1