TEST_BIG_ENDIAN() performs compile tests that will fail with
-nodefaultlibs when building under LLVM_USE_SANITIZER.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
The error with -DLLVM_USE_SANITIZER=Address is
-- Check if the system is big endian -- Searching 16 bit integer -- Looking for stddef.h -- Looking for stddef.h - not found -- Check size of unsigned short -- Check size of unsigned short - failed -- Check size of unsigned int -- Check size of unsigned int - failed -- Check size of unsigned long -- Check size of unsigned long - failed CMake Error at <...>/cmake/share/cmake-3.5/Modules/TestBigEndian.cmake:51 (message): no suitable type found Call Stack (most recent call first): projects/compiler-rt/cmake/base-config-ix.cmake:151 (TEST_BIG_ENDIAN) projects/compiler-rt/cmake/config-ix.cmake:138 (test_targets) projects/compiler-rt/CMakeLists.txt:99 (include)
The reason is that the compile tests are performed with -fsanitize=address -nodefaultlibs. This gives a lot of undefined references because the runtime dependencies aren't linked in.
Comment Actions
http://lab.llvm.org:8011/builders/sanitizer-ppc64be-linux/builds/4004 is broken by this change
compiler-rt/trunk/cmake/base-config-ix.cmake | ||
---|---|---|
154 ↗ | (On Diff #117132) | Oh, right, it should be: string(REPLACE "-nodefaultlibs" "" CMAKE_REQUIRED_FLAGS ${CMAKE_REQUIRED_FLAGS}) |
compiler-rt/trunk/cmake/base-config-ix.cmake | ||
---|---|---|
154 ↗ | (On Diff #117132) | Sorry! Thanks for fixing it so fast, my git-svn just told me that I'm out of sync! |
cmake_push_check_state()