Support/FileSystem: Fix MinGW build. It doesn't have _chsize_s.
[oota-llvm.git] / cmake / config-ix.cmake
index 1d64c13c3f5e14cdc0ad478fc5d04d2aa40cf2a7..27f2964038ba4084264a2017b4cc08a71e4a9913 100755 (executable)
@@ -108,6 +108,9 @@ check_symbol_exists(strerror string.h HAVE_STRERROR)
 check_symbol_exists(strerror_r string.h HAVE_STRERROR_R)
 check_symbol_exists(strerror_s string.h HAVE_STRERROR_S)
 check_symbol_exists(setenv stdlib.h HAVE_SETENV)
+if ( LLVM_ON_WIN32 )
+  check_symbol_exists(_chsize_s io.h HAVE__CHSIZE_S)
+endif()
 
 check_symbol_exists(__GLIBC__ stdio.h LLVM_USING_GLIBC)
 if( LLVM_USING_GLIBC )
@@ -258,8 +261,6 @@ if( LLVM_ENABLE_THREADS )
   endif()
 endif()
 
-test_big_endian(LLVM_IS_HOST_BIG_ENDIAN)
-
 if( ENABLE_THREADS )
   message(STATUS "Threads enabled.")
 else( ENABLE_THREADS )
@@ -279,7 +280,7 @@ configure_file(
   )
 
 configure_file(
-  ${LLVM_MAIN_INCLUDE_DIR}/llvm/System/DataTypes.h.cmake
-  ${LLVM_BINARY_DIR}/include/llvm/System/DataTypes.h
+  ${LLVM_MAIN_INCLUDE_DIR}/llvm/Support/DataTypes.h.cmake
+  ${LLVM_BINARY_DIR}/include/llvm/Support/DataTypes.h
   )