summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorAlexander Harkness <bearbin@gmail.com>2014-01-01 19:15:21 +0100
committerAlexander Harkness <bearbin@gmail.com>2014-01-01 19:15:21 +0100
commitbb0d43f70e41f7182e740e36bb719a28dddf7855 (patch)
treef1fd5c77ebf7ccb130700a97fe7c9c8c02d411b5 /CMakeLists.txt
parentMerge branch 'FishingHook' (diff)
parentmerged changes from upstream (diff)
downloadcuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar.gz
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar.bz2
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar.lz
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar.xz
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.tar.zst
cuberite-bb0d43f70e41f7182e740e36bb719a28dddf7855.zip
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 5 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d2afceaab..67f70142b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -46,6 +46,11 @@ endif()
if(MSVC)
# Make build use multiple threads under MSVC:
add_flags("/MP")
+elseif(APPLE)
+ #on os x clang adds pthread for us but we need to add it for gcc
+ if (NOT "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+ add_flags("-pthread")
+ endif()
else()
# Let gcc / clang know that we're compiling a multi-threaded app:
add_flags("-pthread")
@@ -111,17 +116,8 @@ add_subdirectory(lib/md5/)
# We do not do that for MSVC since MSVC produces an awful lot of warnings for its own STL headers;
# the important warnings will be turned on using #pragma in Globals.h
if (NOT MSVC)
- #TODO: set -Wall -Werror -Wextra
add_flags("-Wall -Wextra")
endif()
-if (NOT WIN32)
- set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -rdynamic")
- set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} -rdynamic")
- set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} -rdynamic")
- set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_PROFILE} -rdynamic")
-endif()
-
-
add_subdirectory (src)