1
This commit is contained in:
parent
832c134765
commit
273b13b018
@ -4,30 +4,11 @@ cmake_minimum_required(VERSION 2.8)
|
|||||||
if (${GAME_ID})
|
if (${GAME_ID})
|
||||||
message(GAME_ID: ${GAME_ID})
|
message(GAME_ID: ${GAME_ID})
|
||||||
else()
|
else()
|
||||||
set(GAME_ID 1008)
|
message(FATAL_ERROR "GAME_ID error")
|
||||||
message(GAME_ID: ${GAME_ID})
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (${LIB_DIR})
|
set(LIB_DIR "ubuntu20.04_g++-9")
|
||||||
message(LIB_DIR: ${LIB_DIR})
|
message(LIB_DIR: ${LIB_DIR})
|
||||||
else()
|
|
||||||
set(LIB_DIR )
|
|
||||||
message(LIB_DIR: ${LIB_DIR} )
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${MASTER_MODE})
|
|
||||||
message(MASTER_MODE: 1)
|
|
||||||
else()
|
|
||||||
set(MASTER_MODE 0)
|
|
||||||
message(MASTER_MODE: 0)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${ASYNC_TCPCLIENT})
|
|
||||||
message(ASYNC_TCPCLIENT: 1)
|
|
||||||
else()
|
|
||||||
set(ASYNC_TCPCLIENT 0)
|
|
||||||
message(ASYNC_TCPCLIENT: 0)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if (${RELEASE})
|
if (${RELEASE})
|
||||||
set(CMAKE_BUILD_TYPE "Release")
|
set(CMAKE_BUILD_TYPE "Release")
|
||||||
@ -36,12 +17,17 @@ else()
|
|||||||
set(CMAKE_BUILD_TYPE "Debug")
|
set(CMAKE_BUILD_TYPE "Debug")
|
||||||
message("debug mode")
|
message("debug mode")
|
||||||
endif()
|
endif()
|
||||||
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -Wall -g -std=gnu++11 -DGAME_ID=${GAME_ID} -DMASTER_MODE=${MASTER_MODE} -DASYNC_TCPCLIENT=${ASYNC_TCPCLIENT} -DNDEBUG")
|
|
||||||
set(CMAKE_CXX_FLAGS_DEBUG "-Wall -g -std=gnu++11 -DGAME_ID=${GAME_ID} -DMASTER_MODE=${MASTER_MODE} -DASYNC_TCPCLIENT=${ASYNC_TCPCLIENT} -DDEBUG")
|
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -Wall -g -std=gnu++1z -DGAME_ID=${GAME_ID} -DNDEBUG")
|
||||||
|
if (${ASAN})
|
||||||
|
set(CMAKE_CXX_FLAGS_DEBUG "-Wall -g -std=gnu++1z -DGAME_ID=${GAME_ID} -DDEBUG -fsanitize=address -fno-omit-frame-pointer")
|
||||||
|
else()
|
||||||
|
set(CMAKE_CXX_FLAGS_DEBUG "-Wall -g -std=gnu++1z -DGAME_ID=${GAME_ID} -DDEBUG")
|
||||||
|
endif()
|
||||||
|
|
||||||
include_directories(
|
include_directories(
|
||||||
AFTER
|
AFTER
|
||||||
../../third_party/a8engine
|
../../third_party/a8
|
||||||
/usr/include/mysql
|
/usr/include/mysql
|
||||||
/usr/include/jsoncpp
|
/usr/include/jsoncpp
|
||||||
/usr/include/hiredis
|
/usr/include/hiredis
|
||||||
@ -60,11 +46,11 @@ link_directories(
|
|||||||
../../third_party/behaviac/lib/${LIB_DIR}
|
../../third_party/behaviac/lib/${LIB_DIR}
|
||||||
)
|
)
|
||||||
|
|
||||||
aux_source_directory(../../third_party/a8engine/a8
|
aux_source_directory(../../third_party/a8/a8
|
||||||
SRC_LIST
|
SRC_LIST
|
||||||
)
|
)
|
||||||
|
|
||||||
aux_source_directory(../../third_party/framework/cpp
|
aux_source_directory(../../third_party/f8/f8
|
||||||
SRC_LIST
|
SRC_LIST
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -138,3 +124,16 @@ else()
|
|||||||
behaviac_gcc_release
|
behaviac_gcc_release
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
|
target_link_libraries(
|
||||||
|
wsproxy${GAME_ID}
|
||||||
|
behaviac_gcc_debug
|
||||||
|
)
|
||||||
|
else()
|
||||||
|
target_link_libraries(
|
||||||
|
wsproxy${GAME_ID}
|
||||||
|
tcmalloc
|
||||||
|
behaviac_gcc_release
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
2
third_party/behaviac
vendored
2
third_party/behaviac
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 5beca57f6555aa0d9e4de71c93653cade928a654
|
Subproject commit 8cd7e2432785bf4027e89c5dc74cb4980e4cd3c1
|
2
third_party/recastnavigation
vendored
2
third_party/recastnavigation
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 35ca2eadc32161cd6ab479d1a2626759a73bb5a3
|
Subproject commit 0165dc279d62af5536f122ea30c3cd3f642f34ee
|
2
third_party/tools
vendored
2
third_party/tools
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 04a0bc939eeae0090fd0e8964dddf3863a551154
|
Subproject commit d38ce0b86c7b9262391f48108d808ddb62854760
|
Loading…
x
Reference in New Issue
Block a user