[PATCH] D17595: [CMAKE] Update build on recent Haiku
Jérôme Duval via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 24 23:15:09 PST 2016
korli created this revision.
korli added reviewers: rengolin, beanz.
korli added a subscriber: llvm-commits.
korli set the repository for this revision to rL LLVM.
cmake build support on Haiku is lagging a bit.
This patch updates cmake build scripts to build on Haiku. It adds Haiku x86_64 to config.guess.
Please consider reviewing.
[ I have no idea what Chris Lattner phab account is :/ ]
Repository:
rL LLVM
http://reviews.llvm.org/D17595
Files:
cmake/config-ix.cmake
cmake/config.guess
include/llvm/Support/Host.h
lib/Support/CMakeLists.txt
Index: lib/Support/CMakeLists.txt
===================================================================
--- lib/Support/CMakeLists.txt
+++ lib/Support/CMakeLists.txt
@@ -24,7 +24,9 @@
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( MINGW )
endif( NOT MSVC )
Index: cmake/config.guess
===================================================================
--- cmake/config.guess
+++ cmake/config.guess
@@ -1203,6 +1203,9 @@
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 ;;
Index: cmake/config-ix.cmake
===================================================================
--- cmake/config-ix.cmake
+++ cmake/config-ix.cmake
@@ -13,7 +13,7 @@
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()
Index: include/llvm/Support/Host.h
===================================================================
--- include/llvm/Support/Host.h
+++ include/llvm/Support/Host.h
@@ -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)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D17595.49009.patch
Type: text/x-patch
Size: 1616 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160225/9aebd2df/attachment.bin>
More information about the llvm-commits
mailing list