aboutsummaryrefslogtreecommitdiffstats
path: root/lib/MC
diff options
context:
space:
mode:
authorAndrew Kaylor <andrew.kaylor@intel.com>2012-10-02 18:38:34 +0000
committerAndrew Kaylor <andrew.kaylor@intel.com>2012-10-02 18:38:34 +0000
commit7bbd6e366b39157445cc921024a987e61ea68c00 (patch)
tree102f2dfc142c368fdcd9c077da5bdaeed0e200a9 /lib/MC
parenta346f462716b4eb32d27ffe20fc8696473f225f6 (diff)
downloadexternal_llvm-7bbd6e366b39157445cc921024a987e61ea68c00.zip
external_llvm-7bbd6e366b39157445cc921024a987e61ea68c00.tar.gz
external_llvm-7bbd6e366b39157445cc921024a987e61ea68c00.tar.bz2
Support for generating ELF objects on Windows.
This adds 'elf' as a recognized target triple environment value and overrides the default generated object format on Windows platforms if that value is present. This patch also enables MCJIT tests on Windows using the new environment value. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165030 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC')
-rw-r--r--lib/MC/MCObjectFileInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/MC/MCObjectFileInfo.cpp b/lib/MC/MCObjectFileInfo.cpp
index 8053624..c59477f 100644
--- a/lib/MC/MCObjectFileInfo.cpp
+++ b/lib/MC/MCObjectFileInfo.cpp
@@ -565,6 +565,7 @@ void MCObjectFileInfo::InitMCObjectFileInfo(StringRef TT, Reloc::Model relocm,
Env = IsMachO;
InitMachOMCObjectFileInfo(T);
} else if ((Arch == Triple::x86 || Arch == Triple::x86_64) &&
+ (T.getEnvironment() != Triple::ELF) &&
(T.getOS() == Triple::MinGW32 || T.getOS() == Triple::Cygwin ||
T.getOS() == Triple::Win32)) {
Env = IsCOFF;