diff options
author | Kenny Root <kroot@google.com> | 2011-02-07 11:35:20 -0800 |
---|---|---|
committer | Kenny Root <kroot@google.com> | 2011-02-07 20:51:39 -0800 |
commit | 1077c330eed643485d5bc2852abea1fb41bac5fb (patch) | |
tree | 471c8d9ecc459d3ff9100023bf6e84889af2cf8f /device/include/llvm/Config/config.h | |
parent | cfb9e3db360f9161eede09766fadb2cb178771cb (diff) | |
download | external_llvm-1077c330eed643485d5bc2852abea1fb41bac5fb.zip external_llvm-1077c330eed643485d5bc2852abea1fb41bac5fb.tar.gz external_llvm-1077c330eed643485d5bc2852abea1fb41bac5fb.tar.bz2 |
Fix X86 target build
Change some definitions in the .def files to allow the targeting of ARM
or X86.
Fix a typo in the previously submitted Makefile.
Add the include for <ctype.h> to use toupper()
Change-Id: Ibb9bea6566d47f1d1854fea18d09287fdd36048b
Diffstat (limited to 'device/include/llvm/Config/config.h')
-rw-r--r-- | device/include/llvm/Config/config.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/device/include/llvm/Config/config.h b/device/include/llvm/Config/config.h index d5cdab5..06f29f4 100644 --- a/device/include/llvm/Config/config.h +++ b/device/include/llvm/Config/config.h @@ -496,10 +496,22 @@ /* #undef LLVM_MULTITHREADED */ /* LLVM architecture name for the native architecture, if available */ -#define LLVM_NATIVE_ARCH ARMTarget +#if defined(__arm__) +# define LLVM_NATIVE_ARCH ARMTarget +#elif defined(__i386__) +# define LLVM_NATIVE_ARCH X86Target +#else +# error Unsupported target architecture for LLVM_NATIVE_ARCH +#endif /* Short LLVM architecture name for the native architecture, if available */ -#define LLVM_NATIVE_ARCHNAME ARM +#if defined(__arm__) +# define LLVM_NATIVE_ARCHNAME ARM +#elif defined(__i386__) +# define LLVM_NATIVE_ARCHNAME X86 +#else +# error Unsupported target architecture for LLVM_NATIVE_ARCHNAME +#endif /* Define if this is Unixish platform */ #define LLVM_ON_UNIX 1 |