More portability checks for CMake's config.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72975 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0de1e08..8133398 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -150,11 +150,13 @@
option(LLVM_ENABLE_PIC "Build Position-Independent Code" OFF)
+set(ENABLE_PIC 0)
if( LLVM_ENABLE_PIC )
if( SUPPORTS_FPIC_FLAG )
message(STATUS "Building with -fPIC")
add_llvm_definitions(-fPIC)
- else( SUPPORTS_FPIC_FLAG )
+ set(ENABLE_PIC 1)
+ else( SUPPORTS_FPIC_FLAG )
message(STATUS "Warning: -fPIC not supported.")
endif()
endif()