summaryrefslogtreecommitdiff
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
authorAdam <Adam@drink-coca-cola.info>2010-05-05 18:14:06 -0400
committerAdam <Adam@anope.org>2010-06-18 20:58:54 -0400
commit031bc4a8b0dc456aca4d70dc260f626b64cd82b3 (patch)
tree74f9c217963e45f54c787ed83fc6d494232f5cd4 /src/CMakeLists.txt
parent503958aa77382a85a041e195d04b7a2ec51589e3 (diff)
Merged branch threadingengine with master - Added a threading engine
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 4bad367b4..8cf232a77 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -2,14 +2,24 @@
file(GLOB SRC_SRCS_C RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*.c")
file(GLOB SRC_SRCS_CPP RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*.cpp")
set(SRC_SRCS ${SRC_SRCS_C} ${SRC_SRCS_CPP})
+
# Don't include win32_memory.cpp, it's only required by Visual Studio to override it's override of the new/delete operators
remove_item_from_list(SRC_SRCS win32_memory.cpp)
+
# If not using Windows, don't include windows.cpp, as it's Windows-specific
if(NOT WIN32)
remove_item_from_list(SRC_SRCS windows.cpp)
endif(NOT WIN32)
sort_list(SRC_SRCS)
+# If using Windows, remove the pthread threading engine from the list
+if(WIN32)
+ remove_item_from_list(SRC_SRCS threadengine_pthread.cpp)
+# If not using Windows, remove the Windows threading engine from the list
+else(WIN32)
+ remove_item_from_list(SRC_SRCS threadengine_win32.cpp)
+endif(WIN32)
+
# Set all the files to use C++ as well as set their compile flags (use the module-specific compile flags, though)
set_source_files_properties(${SRC_SRCS} PROPERTIES LANGUAGE CXX COMPILE_FLAGS "${CXXFLAGS}")