summaryrefslogtreecommitdiffstats
path: root/Tools
diff options
context:
space:
mode:
authorTycho <work.tycho+git@gmail.com>2014-02-16 00:27:10 +0100
committerTycho <work.tycho+git@gmail.com>2014-02-16 00:27:10 +0100
commit42e9b21fb25426cd6f4e42c7cede4294e00e9e6b (patch)
tree867f1da38c2a2bea35963c515d79a78d4e96ea26 /Tools
parentrewrote MCADefrag CMakelist to use Setflags (diff)
downloadcuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar.gz
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar.bz2
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar.lz
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar.xz
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.tar.zst
cuberite-42e9b21fb25426cd6f4e42c7cede4294e00e9e6b.zip
Diffstat (limited to '')
-rw-r--r--Tools/MCADefrag/CMakeLists.txt13
1 files changed, 4 insertions, 9 deletions
diff --git a/Tools/MCADefrag/CMakeLists.txt b/Tools/MCADefrag/CMakeLists.txt
index f3256f275..174da4fab 100644
--- a/Tools/MCADefrag/CMakeLists.txt
+++ b/Tools/MCADefrag/CMakeLists.txt
@@ -19,7 +19,6 @@ include_directories("../../lib")
include_directories("../../src")
-
function(flatten_files arg1)
set(res "")
foreach(f ${${arg1}})
@@ -32,12 +31,8 @@ endfunction()
# Include the libraries:
if(NOT DEFINED ${ZLIB})
-file(GLOB ZLIB_SRC "../../lib/zlib/*.c")
-file(GLOB ZLIB_HDR "../../lib/zlib/*.h")
-flatten_files(ZLIB_SRC)
-flatten_files(ZLIB_HDR)
-source_group("ZLib" FILES ${ZLIB_SRC} ${ZLIB_HDR})
-set(ZLIB 1)
+ add_subdirectory(../../lib/zlib lib/zlib)
+ set(ZLIB 1)
endif()
set_exe_flags()
@@ -98,7 +93,7 @@ add_executable(MCADefrag
${SHARED_HDR}
${SHARED_OSS_SRC}
${SHARED_OSS_HDR}
- ${ZLIB_SRC}
- ${ZLIB_HDR}
)
+target_link_libraries(MCADefrag zlib)
+