Fix LLVM CMake build system so that it may now work on Solaris and AuroraUX.
authorEdward O'Callaghan <eocallaghan@auroraux.org>
Mon, 12 Oct 2009 04:00:11 +0000 (04:00 +0000)
committerEdward O'Callaghan <eocallaghan@auroraux.org>
Mon, 12 Oct 2009 04:00:11 +0000 (04:00 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83819 91177308-0d34-0410-b5e6-96231b3b80d8

CMakeLists.txt
cmake/config-ix.cmake
include/llvm/Config/config.h.cmake

index b22a8c239d1031c21ca886da174bef26ce46b737..f7126584ba78acd9cead5b538ae3d994618c9365 100644 (file)
@@ -221,6 +221,10 @@ endif( MSVC )
 
 include_directories( ${LLVM_BINARY_DIR}/include ${LLVM_MAIN_INCLUDE_DIR})
 
+if( ${CMAKE_SYSTEM_NAME} MATCHES SunOS )
+   SET(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} "-include llvm/System/Solaris.h")
+endif( ${CMAKE_SYSTEM_NAME} MATCHES SunOS )
+
 include(AddLLVM)
 include(TableGen)
 
index 320aaf899402dc47f3a957f70403594b9a34e0f6..320335cf0fe037fcd95ee55140b6b94c11596bc2 100755 (executable)
@@ -75,6 +75,7 @@ check_symbol_exists(setrlimit sys/resource.h HAVE_SETRLIMIT)
 check_function_exists(isatty HAVE_ISATTY)
 check_symbol_exists(isinf cmath HAVE_ISINF_IN_CMATH)
 check_symbol_exists(isinf math.h HAVE_ISINF_IN_MATH_H)
+check_symbol_exists(finite ieeefp.h HAVE_FINITE_IN_IEEEFP_H)
 check_symbol_exists(isnan cmath HAVE_ISNAN_IN_CMATH)
 check_symbol_exists(isnan math.h HAVE_ISNAN_IN_MATH_H)
 check_symbol_exists(ceilf math.h HAVE_CEILF)
index d8de146c8c20a13d6270dc55b0529d51e450082e..fa5d316ef076d1de4d103f39f6d67e2600894f82 100644 (file)
@@ -98,7 +98,7 @@
 #cmakedefine HAVE_FCNTL_H ${HAVE_FCNTL_H}
 
 /* Set to 1 if the finite function is found in <ieeefp.h> */
-#undef HAVE_FINITE_IN_IEEEFP_H
+#cmakedefine HAVE_FINITE_IN_IEEEFP_H ${HAVE_FINITE_IN_IEEEFP_H}
 
 /* Define to 1 if you have the `floorf' function. */
 #cmakedefine HAVE_FLOORF ${HAVE_FLOORF}
 #undef HAVE_ROUNDF
 
 /* Define to 1 if you have the `sbrk' function. */
-#undef HAVE_SBRK
+#cmakedefine HAVE_SBRK ${HAVE_SBRK}
 
 /* Define to 1 if you have the `setenv' function. */
 #cmakedefine HAVE_SETENV ${HAVE_SETENV}