[llvm] r262038 - [CMAKE] Update build on recent Haiku
Renato Golin via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 26 09:01:45 PST 2016
Author: rengolin
Date: Fri Feb 26 11:01:45 2016
New Revision: 262038
URL: http://llvm.org/viewvc/llvm-project?rev=262038&view=rev
Log:
[CMAKE] Update build on recent Haiku
This patch updates cmake build scripts to build on Haiku. It adds Haiku x86_64 to config.guess.
Please consider reviewing.
Pathc by Jérôme Duval.
Modified:
llvm/trunk/cmake/config-ix.cmake
llvm/trunk/cmake/config.guess
llvm/trunk/include/llvm/Support/Host.h
llvm/trunk/lib/Support/CMakeLists.txt
Modified: llvm/trunk/cmake/config-ix.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/config-ix.cmake?rev=262038&r1=262037&r2=262038&view=diff
==============================================================================
--- llvm/trunk/cmake/config-ix.cmake (original)
+++ llvm/trunk/cmake/config-ix.cmake Fri Feb 26 11:01:45 2016
@@ -13,7 +13,7 @@ include(TestBigEndian)
include(HandleLLVMStdlib)
-if( UNIX AND NOT BEOS )
+if( UNIX AND NOT (BEOS OR HAIKU) )
# Used by check_symbol_exists:
set(CMAKE_REQUIRED_LIBRARIES m)
endif()
Modified: llvm/trunk/cmake/config.guess
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/config.guess?rev=262038&r1=262037&r2=262038&view=diff
==============================================================================
--- llvm/trunk/cmake/config.guess (original)
+++ llvm/trunk/cmake/config.guess Fri Feb 26 11:01:45 2016
@@ -1203,6 +1203,9 @@ EOF
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
echo i586-pc-haiku
exit ;;
+ x86_64:Haiku:*:*) # Haiku running on x86_64.
+ echo x86_64-unknown-haiku
+ exit ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
exit ;;
Modified: llvm/trunk/include/llvm/Support/Host.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/Host.h?rev=262038&r1=262037&r2=262038&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/Host.h (original)
+++ llvm/trunk/include/llvm/Support/Host.h Fri Feb 26 11:01:45 2016
@@ -16,7 +16,7 @@
#include "llvm/ADT/StringMap.h"
-#if defined(__linux__) || defined(__GNU__)
+#if defined(__linux__) || defined(__GNU__) || defined(__HAIKU__)
#include <endian.h>
#else
#if !defined(BYTE_ORDER) && !defined(LLVM_ON_WIN32)
Modified: llvm/trunk/lib/Support/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/CMakeLists.txt?rev=262038&r1=262037&r2=262038&view=diff
==============================================================================
--- llvm/trunk/lib/Support/CMakeLists.txt (original)
+++ llvm/trunk/lib/Support/CMakeLists.txt Fri Feb 26 11:01:45 2016
@@ -23,7 +23,9 @@ elseif( CMAKE_HOST_UNIX )
if ( LLVM_ENABLE_ZLIB AND HAVE_LIBZ )
set(system_libs ${system_libs} z)
endif()
- set(system_libs ${system_libs} m)
+ if( UNIX AND NOT (BEOS OR HAIKU) )
+ set(system_libs ${system_libs} m)
+ endif()
endif( MSVC OR MINGW )
add_llvm_library(LLVMSupport
More information about the llvm-commits
mailing list