summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorLaG1924 <12997935+LaG1924@users.noreply.github.com>2017-04-21 15:31:43 +0200
committerLaG1924 <12997935+LaG1924@users.noreply.github.com>2017-04-21 15:31:43 +0200
commit71760514fc044f273914c17b1510fa3cf10419b3 (patch)
tree72f822efde300d8e1e9de1cc578d431ff72e0e03 /CMakeLists.txt
parent2017-04-15 (diff)
downloadAltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar.gz
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar.bz2
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar.lz
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar.xz
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.tar.zst
AltCraft-71760514fc044f273914c17b1510fa3cf10419b3.zip
Diffstat (limited to '')
-rw-r--r--CMakeLists.txt21
1 files changed, 16 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 31b7a14..65d0205 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,7 +2,10 @@ cmake_minimum_required(VERSION 3.5)
project(AltCraft)
set(CMAKE_CXX_STANDARD 14)
-#set(CMAKE_CXX_FLAGS "-fsanitize=address")
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic-errors -w -Werror -g")
+#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address")
+#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -pg")
+
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules)
#Setup SFML
@@ -12,10 +15,18 @@ if (NOT SFML_FOUND)
message(ERROR "SFML not found!")
endif ()
+#Setup Zlib
+find_package(ZLIB REQUIRED)
+include_directories(${ZLIB_INCLUDE_DIR})
+if (NOT ZLIB_FOUND)
+ message(ERROR "Zlib not found!")
+endif ()
+
+
set(SOURCE_FILES main.cpp Field.hpp utility.cpp Packet.hpp FieldParser.hpp Network.hpp Network.cpp NetworkClient.cpp
- NetworkClient.hpp json.h PacketBuilder.cpp PacketBuilder.hpp Packet.cpp FieldParser.cpp Field.cpp
+ NetworkClient.hpp json.hpp PacketBuilder.cpp PacketBuilder.hpp Packet.cpp FieldParser.cpp Field.cpp
PacketParser.cpp PacketParser.hpp PositionF.cpp PositionF.hpp PositionI.cpp PositionI.hpp Game.cpp
- Game.hpp World.cpp World.hpp Block.cpp Block.hpp Display.cpp Display.hpp)
-#file(GLOB SOURCE_FILES "*.h" "*.hpp" "*.cpp")
+ Game.hpp World.cpp World.hpp Block.cpp Block.hpp Display.cpp Display.hpp Section.cpp Section.hpp Nbt.hpp)
+
add_executable(AltCraft ${SOURCE_FILES})
-target_link_libraries(AltCraft ${SFML_LIBRARIES}) \ No newline at end of file
+target_link_libraries(AltCraft ${SFML_LIBRARIES} ${ZLIB_LIBRARIES} pthread) \ No newline at end of file