-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
37 lines (30 loc) · 1.08 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
cmake_minimum_required(VERSION 3.0)
project(PodrumR4)
find_package(OpenSSL REQUIRED)
set(CMAKE_C_STANDARD 11)
set(USE_LEAK_DETECTOR 0)
file(GLOB CBINARYSTREAM cbinarystream/*.c)
file(GLOB CNBT cnbt/*.c)
file(GLOB CZLIBHELPER czlibhelper/*.c)
file(GLOB MINIZ miniz/*.c)
file(GLOB PODRUM podrum/*.c podrum/misc/*.c podrum/world/*.c podrum/world/format/anvil/*.c podrum/world/chunk/*.c podrum/command/*.c podrum/network/minecraft/*.c podrum/network/raknet/*.c)
include_directories(.)
IF("${CMAKE_SYSTEM}" MATCHES "Windows")
if("${USE_LEAK_DETECTOR}" MATCHES "1")
include_directories("c:\\Program Files (x86)\\Visual Leak Detector\\include")
link_directories("c:\\Program Files (x86)\\Visual Leak Detector\\lib\\Win64")
endif()
endif()
add_executable(PodrumR4
${CBINARYSTREAM}
${CNBT}
${CZLIBHELPER}
${MINIZ}
${PODRUM}
)
target_link_libraries(PodrumR4 OpenSSL::SSL)
target_link_libraries(PodrumR4 OpenSSL::Crypto)
IF(NOT ("${CMAKE_SYSTEM}" MATCHES "Windows"))
TARGET_LINK_LIBRARIES(PodrumR4 pthread)
TARGET_LINK_LIBRARIES(PodrumR4 m)
endif()