diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 4070dcbd6..ef3bc782f 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -173,7 +173,10 @@ set (SERVER_SRC ${SERVER_SRC} ) endif(CURSES_FOUND) -add_library(game ${ERESSEA_SRC}) +add_library(version OBJECT ${VERSION_SRC}) +add_library(game ${ERESSEA_SRC} + $ +) add_executable(eressea ${SERVER_SRC}) target_link_libraries(eressea game diff --git a/src/kernel/CMakeLists.txt b/src/kernel/CMakeLists.txt index 016c8fb18..2c9da7dc0 100644 --- a/src/kernel/CMakeLists.txt +++ b/src/kernel/CMakeLists.txt @@ -33,7 +33,6 @@ jsonconf.test.c ) SET(_FILES -version.c alliance.c ally.c build.c @@ -65,6 +64,8 @@ xmlreader.c jsonconf.c ) +SET(VERSION_SRC ${PROJECT_NAME}/version.c PARENT_SCOPE) + FOREACH(_FILE ${_FILES}) LIST(APPEND _SOURCES ${PROJECT_NAME}/${_FILE}) ENDFOREACH(_FILE)