summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitmodules3
-rw-r--r--CMakeLists.txt1
-rw-r--r--depends/CMakeLists.txt4
m---------depends/clsocket0
-rw-r--r--library/CMakeLists.txt2
5 files changed, 9 insertions, 1 deletions
diff --git a/.gitmodules b/.gitmodules
index 76fb139d..700af743 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -7,3 +7,6 @@
[submodule "library/xml"]
path = library/xml
url = git://github.com/peterix/df-structures.git
+[submodule "depends/clsocket"]
+ path = depends/clsocket
+ url = git://github.com/peterix/clsocket.git
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 620bf6d9..367e68f6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -110,6 +110,7 @@ include_directories(depends/md5)
include_directories(depends/tinyxml)
include_directories(depends/tthread)
include_directories(${ZLIB_INCLUDE_DIRS})
+include_directories(depends/clsocket/src)
add_subdirectory(depends)
diff --git a/depends/CMakeLists.txt b/depends/CMakeLists.txt
index d16e83ea..d879657e 100644
--- a/depends/CMakeLists.txt
+++ b/depends/CMakeLists.txt
@@ -4,3 +4,7 @@ add_subdirectory(md5)
add_subdirectory(protobuf)
add_subdirectory(tinyxml)
add_subdirectory(tthread)
+# build clsocket static and only as a dependency. Setting those options here overrides its own default settings.
+OPTION(CLSOCKET_SHARED "Build clsocket lib as shared." OFF)
+OPTION(CLSOCKET_DEP_ONLY "Build for use inside other CMake projects as dependency." ON)
+add_subdirectory(clsocket)
diff --git a/depends/clsocket b/depends/clsocket
new file mode 160000
+Subproject 49fa800615a4e5c872164bcb4122030d2ebda9c
diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt
index ac54340e..0521184c 100644
--- a/library/CMakeLists.txt
+++ b/library/CMakeLists.txt
@@ -228,7 +228,7 @@ ENDIF()
#effectively disables debug builds...
SET_TARGET_PROPERTIES(dfhack PROPERTIES DEBUG_POSTFIX "-debug" )
-TARGET_LINK_LIBRARIES(dfhack protobuf-lite ${PROJECT_LIBS})
+TARGET_LINK_LIBRARIES(dfhack protobuf-lite clsocket ${PROJECT_LIBS})
SET_TARGET_PROPERTIES(dfhack PROPERTIES LINK_INTERFACE_LIBRARIES "")
IF(UNIX)