ANA cmake cleanups.

- Set the option and dependency check in the top level file.

- Directly add the ana/src directoy avoiding two new options being pulled
  in.
This commit is contained in:
Mark de Wever 2010-07-11 16:50:51 +00:00
parent 003e02cbc5
commit 1ea406c40c
2 changed files with 6 additions and 3 deletions

View file

@ -80,6 +80,7 @@ if (UNIX AND NOT APPLE AND NOT CYGWIN)
endif(UNIX AND NOT APPLE AND NOT CYGWIN)
option(ENABLE_STRICT_COMPILATION "Sets the strict compilation mode" ON)
option(ENABLE_DEBUG_WINDOW_LAYOUT "Add the debug option to allow the generation of debug layout files in dot format" OFF)
option ( USE_ANA_NETWORK "Compile network module using ana" OFF )
#misc options
if(NOT MSVC)
@ -221,6 +222,10 @@ if(ENABLE_GAME)
endif(ENABLE_GAME)
if(USE_ANA_NETWORK)
find_package( Boost 1.35 REQUIRED COMPONENTS system )
endif(USE_ANA_NETWORK)
# get languages
file(READ po/LINGUAS LINGUAS)
string(REPLACE "\n" "" LINGUAS ${LINGUAS})

View file

@ -38,14 +38,12 @@ if(ZLIB_INCLUDE_DIR)
include_directories( ${ZLIB_INCLUDE_DIR} )
endif()
option ( USE_ANA_NETWORK "Compile network module using ana" OFF )
set( network_implementation_files network.cpp network_worker.cpp )
if( USE_ANA_NETWORK )
set( network_implementation_files network_ana.cpp network_manager_ana.cpp)
message( STATUS "Compiling network module with ana: ${network_implementation_files}" )
find_package( Boost 1.35 REQUIRED COMPONENTS system )
endif ( USE_ANA_NETWORK )
# needed to get include paths in the subfolders correct
@ -73,7 +71,7 @@ else(MSVC)
endif(MSVC)
if ( USE_ANA_NETWORK )
add_subdirectory ( ana )
add_subdirectory ( ana/src )
set( game-external-libs
${common-external-libs}