aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Support/CommandLineTest.cpp
diff options
context:
space:
mode:
authorLouis Dionne <ldionne@apple.com>2020-07-20 13:13:38 -0400
committerLouis Dionne <ldionne@apple.com>2020-07-21 09:14:33 -0400
commit14c4de13e920c497c5275f81f74c453da2b3c957 (patch)
treeec8f698fd70c0163f025e23f045d9b840b545d74 /llvm/unittests/Support/CommandLineTest.cpp
parent5a8779169ebc6a5bb839b46c6201e9217b7e3561 (diff)
downloadllvm-14c4de13e920c497c5275f81f74c453da2b3c957.zip
llvm-14c4de13e920c497c5275f81f74c453da2b3c957.tar.gz
llvm-14c4de13e920c497c5275f81f74c453da2b3c957.tar.bz2
[compiler-rt] Use -nostdinc++ in clang_rt.profile to avoid including C++ headers
Most of the code in compiler_rt is C code. However, clang_rt.profile contains the InstrProfilingRuntime.cpp file, which builds as C++. This means that including e.g. <stdint.h> will actually include libc++'s <stdint.h> and then #include_next the system's <stdint.h>. However, if the target we're building compiler-rt for isn't supported by libc++, this will lead to a failure since libc++'s <stdint.h> includes <__config>, which performs various checks. Since the goal seems to *not* be including any header from the C++ Standard Library in clang_rt.profile, using -nostdinc++ to ensure that doesn't happen unknowingly seems to make sense. rdar://65852694 Differential Revision: https://reviews.llvm.org/D84205
Diffstat (limited to 'llvm/unittests/Support/CommandLineTest.cpp')
0 files changed, 0 insertions, 0 deletions