From ac8905602d1f221a71ddcdc86796344101276321 Mon Sep 17 00:00:00 2001 From: LaG1924 <12997935+LaG1924@users.noreply.github.com> Date: Wed, 14 Jun 2017 19:22:52 +0500 Subject: 2017-06-14 --- CMakeLists.txt | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 73d4124..a52494c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,10 +19,33 @@ set(SRC_UTILITY src/utility/Vector.hpp src/utility/utility.cpp) set(SRC_WORLD src/world/Block.cpp src/world/Section.cpp src/world/World.cpp) set(SOURCE_FILES src/main.cpp ${SRC_CORE} ${SRC_GAMESTATE} ${SRC_GRAPHICS} ${SRC_GUI} ${SRC_GRAPHICS} ${SRC_GUI} - ${SRC_NBT} ${SRC_NETWORK} ${SRC_PACKET} ${SRC_UTILITY} ${SRC_WORLD}) + ${SRC_NBT} ${SRC_NETWORK} ${SRC_PACKET} ${SRC_UTILITY} ${SRC_WORLD} src/graphics/Frustrum.cpp src/graphics/Frustrum.hpp) add_executable(AltCraft ${SOURCE_FILES}) +################ +# CONFIGURATION +################ + +#Configure easlylogging++ +#set(LOGGER_DEFINITIONS "-DELPP_THREAD_SAFE") +if (LINUX) + set(LOGGER_DENITIONS "${LOGGER_DEFINITIPNS} -DELPP_FEATURE_CRASH_LOG -DELPP_STL_LOGGING") +endif() +add_definitions(${LOGGER_DEFINITIONS}) + +#Set compiler's flags and setup platfrom-dependent libraries +if (CMAKE_COMPILER_IS_GNUCXX) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic -Werror") + #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0") + #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3") + #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g") + #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -p") + set(PLATFORM_LIBRARIES "pthread" "stdc++fs") +endif () +target_link_libraries(AltCraft ${PLATFORM_LIBRARIES}) + ############ # LIBRARIES ############ @@ -60,29 +83,6 @@ endif () # message(FATAL_ERROR "Zlib not found!") #endif () -################ -# CONFIGURATION -################ - -#Configure easlylogging++ -#set(LOGGER_DEFINITIONS "-DELPP_THREAD_SAFE") -if (LINUX) - set(LOGGER_DENITIONS "${LOGGER_DEFINITIPNS} -DELPP_FEATURE_CRASH_LOG -DELPP_STL_LOGGING") -endif() -add_definitions(${LOGGER_DEFINITIONS}) - -#Set compiler's flags and setup platfrom-dependent libraries -if (CMAKE_COMPILER_IS_GNUCXX) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic -Werror") - #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0") - #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3") - #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g") - #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pg") - set(PLATFORM_LIBRARIES "pthread" "stdc++fs") -endif () -target_link_libraries(AltCraft ${PLATFORM_LIBRARIES}) - ################# # COPY RESOURCES ################# -- cgit v1.2.3