Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Feb 17, 2011, 5:47:22 AM (14 years ago)
Author:
rgrieder
Message:

Stripped down trunk to form a new light sandbox.

Location:
code/forks/sandbox_light/cmake
Files:
10 deleted
7 edited

Legend:

Unmodified
Added
Removed
  • code/forks/sandbox_light/cmake/InstallConfig.cmake

    r7163 r7908  
    4343SET(LIBRARY_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_LIBRARY_PATH})
    4444SET(ARCHIVE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_ARCHIVE_PATH})
    45 SET(MODULE_INSTALL_DIRECTORY  ${CMAKE_INSTALL_PREFIX}/${DEFAULT_MODULE_PATH})
    4645SET(DOC_INSTALL_DIRECTORY     ${CMAKE_INSTALL_PREFIX}/${DEFAULT_DOC_PATH})
    4746SET(DATA_INSTALL_DIRECTORY    ${CMAKE_INSTALL_PREFIX}/${DEFAULT_DATA_PATH})
     
    5554    SET(LIBRARY_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/lib/games/orxonox)
    5655    SET(ARCHIVE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/lib/games/orxonox/static)
    57     SET(MODULE_INSTALL_DIRECTORY  ${CMAKE_INSTALL_PREFIX}/lib/games/orxonox/modules)
    5856    SET(DOC_INSTALL_DIRECTORY     ${CMAKE_INSTALL_PREFIX}/share/doc/orxonox)
    5957    SET(DATA_INSTALL_DIRECTORY    ${CMAKE_INSTALL_PREFIX}/share/games/orxonox)
  • code/forks/sandbox_light/cmake/LibraryConfig.cmake

    r7459 r7908  
    9393# Performs the search and sets the variables    #
    9494
    95 FIND_PACKAGE(OGRE  1.4       REQUIRED)
    96 #FIND_PACKAGE(ENet  1.1       REQUIRED)
    97 FIND_PACKAGE(Ogg             REQUIRED)
    98 FIND_PACKAGE(Vorbis          REQUIRED)
    99 FIND_PACKAGE(ALUT            REQUIRED)
    100 FIND_PACKAGE(ZLIB            REQUIRED)
    101 IF(POCO_REQUIRED)
    102   FIND_PACKAGE(POCO          REQUIRED)
    103 ENDIF()
     95#FIND_PACKAGE(POCO          REQUIRED)
    10496IF(WIN32)
    10597  FIND_PACKAGE(DbgHelp)
    106   FIND_PACKAGE(DirectX       REQUIRED)
    10798ENDIF()
    108 
    109 ##### CEGUI #####
    110 # We make use of the CEGUI script module called CEGUILua.
    111 # However there is a small issue with that: We use Tolua, a C++ binding
    112 # generator ourselves. And we also have to use our bindings in the same
    113 # lua state is CEGUILua's. Unfortunately this implies that both lua runtime
    114 # version are equal or else you get segmentation faults.
    115 # In order to match the Lua versions we decided to ship CEGUILua in our
    116 # repository, mainly because there is no way to determine which version of
    117 # Lua CEGUILua was linked against (you'd have to specify yourself) and secondly
    118 # because we can then choose the Lua version. Future plans might involve only
    119 # accepting Lua 5.1.
    120 
    121 # Insert all internally supported CEGUILua versions here
    122 SET(CEGUILUA_INTERNAL_SUPPORT 0.5.0 0.6.0 0.6.1 0.6.2)
    123 OPTION(CEGUILUA_USE_EXTERNAL_LIBRARY "Force the use of external CEGUILua library" OFF)
    124 FIND_PACKAGE(CEGUI 0.5 REQUIRED)
    125 
    126 ##### Lua #####
    127 IF(CEGUILUA_USE_EXTERNAL_LIBRARY)
    128   COMPARE_VERSION_STRINGS(${CEGUI_VERSION} "0.6" _version_comparison)
    129   IF(version_comparison LESS 0)
    130     SET(LUA_VERSION_REQUEST 5.0)
    131   ELSE()
    132     SET(LUA_VERSION_REQUEST 5.1)
    133   ENDIF()
    134 ELSE()
    135   SET(LUA_VERSION_REQUEST 5)
    136 ENDIF()
    137 FIND_PACKAGE(Lua ${LUA_VERSION_REQUEST} EXACT REQUIRED)
    138 
    139 ##### OpenAL #####
    140 FIND_PACKAGE(OpenAL REQUIRED)
    141 # Also use parent include dir (without AL/) for ALUT
    142 IF(OPENAL_INCLUDE_DIR MATCHES "/AL$")
    143   GET_FILENAME_COMPONENT(ALT_OPENAL_INCLUDE_DIR ${OPENAL_INCLUDE_DIR} PATH)
    144 ENDIF()
    145 SET(OPENAL_INCLUDE_DIRS ${OPENAL_INCLUDE_DIR} ${ALT_OPENAL_INCLUDE_DIR})
    146 # Notfiy user
    147 FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenAL DEFAULT_MSG OPENAL_LIBRARY OPENAL_INCLUDE_DIR)
    148 # Hide variables created by the script
    149 MARK_AS_ADVANCED(OPENAL_INCLUDE_DIR OPENAL_LIBRARY)
    150 
    151 ##### Tcl #####
    152 # We only require Tcl, so avoid confusing user about other Tcl stuff by
    153 # applying a little workaround
    154 SET(Tclsh_FIND_QUIETLY TRUE)
    155 FIND_PACKAGE(TCL QUIET)
    156 # Display messages separately
    157 SET(TCL_FIND_QUIETLY FALSE)
    158 FIND_PACKAGE_HANDLE_STANDARD_ARGS(TCL DEFAULT_MSG TCL_LIBRARY TCL_INCLUDE_PATH)
    15999
    160100##### Boost #####
     
    176116IF(WIN32)
    177117  OPTION(LINK_BOOST_DYNAMIC "Link Boost dynamically on Windows" TRUE)
    178   OPTION(LINK_CEGUI_DYNAMIC "Link CEGUI dynamicylly on Windows" TRUE)
    179   #OPTION(LINK_ENET_DYNAMIC  "Link ENet dynamically on Windows" TRUE)
    180   OPTION(LINK_OGRE_DYNAMIC  "Link OGRE dynamically on Windows" TRUE)
    181   OPTION(LINK_TCL_DYNAMIC   "Link TCL dynamically on Windows" TRUE)
    182   OPTION(LINK_ZLIB_DYNAMIC  "Link ZLib dynamically on Windows" TRUE)
    183   COMPARE_VERSION_STRINGS("${LUA_VERSION}" "5.1" _version_comparison)
    184   IF(_version_comparison LESS 0)
    185     OPTION(LINK_LUA_DYNAMIC "Link Lua dynamically on Windows" FALSE)
    186   ELSE(_version_comparison LESS 0)
    187     OPTION(LINK_LUA_DYNAMIC "Link Lua dynamically on Windows" TRUE)
    188   ENDIF(_version_comparison LESS 0)
    189118
    190119  IF(DEPENDENCY_PACKAGE_ENABLE)
    191     MARK_AS_ADVANCED(
    192       LINK_BOOST_DYNAMIC LINK_CEGUI_DYNAMIC #LINK_ENET_DYNAMIC
    193       LINK_OGRE_DYNAMIC  LINK_TCL_DYNAMIC   LINK_ZLIB_DYNAMIC
    194       LINK_LUA_DYNAMIC
    195     )
     120    MARK_AS_ADVANCED(LINK_BOOST_DYNAMIC)
    196121  ENDIF()
    197122ENDIF(WIN32)
    198 
    199 
    200 ################# OGRE Plugins ##################
    201 
    202 # More plugins: Plugin_BSPSceneManager, Plugin_OctreeSceneManager
    203 SET(OGRE_PLUGINS_INT Plugin_ParticleFX)
    204 IF(WIN32)
    205   # CG program manager is probably DirectX related (not available under unix)
    206   LIST(APPEND OGRE_PLUGINS_INT Plugin_CgProgramManager)
    207 ENDIF(WIN32)
    208 SET(OGRE_PLUGINS ${OGRE_PLUGINS_INT} CACHE STRING
    209    "Specify which OGRE plugins to load. Existance check is performed.")
    210 
    211 # Check the plugins and determine the plugin folder
    212 # You can give a hint by setting the environment variable ENV{OGRE_PLUGIN_DIR}
    213 INCLUDE(CheckOGREPlugins)
    214 CHECK_OGRE_PLUGINS(${OGRE_PLUGINS})
    215 
  • code/forks/sandbox_light/cmake/LibraryConfigTardis.cmake

    r6746 r7908  
    7272  LIST(APPEND CMAKE_LIBRARY_PATH "/usr/pack/ogre-1.6.1-sd/i686-debian-linux5.0")
    7373
    74   #SET(ENV{CEGUIDIR}    "/usr/pack/cegui-0.6.2-sd;/usr/pack/cegui-0.6.2-sd/i686-debian-linux5.0")
    75   #SET(ENV{ENETDIR}     "/usr/pack/enet-1.2-sd;/usr/pack/enet-1.2-sd/i686-debian-linux4.0")
    76   #SET(ENV{ALUTDIR}     "/usr/pack/openal-0.0.8-cl;/usr/pack/openal-0.0.8-cl/i686-debian-linux3.1")
    77   #SET(ENV{OGGDIR}      "/usr/pack/oggvorbis-1.0-ds;/usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0")
    78   #SET(ENV{VORBISDIR}   "/usr/pack/oggvorbis-1.0-ds;/usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0")
    79   #SET(ENV{LUA_DIR}     "/usr/pack/lua-5.1.4-sd;/usr/pack/lua-5.1.4-sd/i686-debian-linux4.0")
    80   #SET(ENV{OGRE_HOME}   "/usr/pack/ogre-1.4.9-sd;/usr/pack/ogre-1.4.9-sd/i686-debian-linux4.0")
    81   #SET(ENV{OPENALDIR}   "/usr/pack/openal-0.0.8-cl;/usr/pack/openal-0.0.8-cl/i686-debian-linux3.1")
    82   #SET(TCL_INCLUDE_PATH "/usr/pack/tcltk-8.4.9.linux-mo/include")
    8374ENDIF(TARDIS)
  • code/forks/sandbox_light/cmake/PackageConfig.cmake

    r7459 r7908  
    7878
    7979# Include paths and other special treatments
    80 SET(ENV{ALUTDIR}               ${DEP_INCLUDE_DIR}/freealut)
    8180SET(ENV{BOOST_ROOT}            ${DEP_INCLUDE_DIR}/boost)
    82 SET(ENV{CEGUIDIR}              ${DEP_INCLUDE_DIR}/cegui)
    8381SET(ENV{DBGHELP_DIR}           ${DEP_INCLUDE_DIR}/dbghelp)
    84 SET(ENV{DXSDK_DIR}             ${DEP_INCLUDE_DIR}/directx)
    85 #SET(ENV{ENETDIR}               ${DEP_INCLUDE_DIR}/enet)
    86 SET(ENV{LUA_DIR}               ${DEP_INCLUDE_DIR}/lua)
    87 SET(ENV{OGGDIR}                ${DEP_INCLUDE_DIR}/libogg)
    88 SET(ENV{VORBISDIR}             ${DEP_INCLUDE_DIR}/libvorbis)
    89 SET(ENV{OGRE_HOME}             ${DEP_INCLUDE_DIR}/ogre)
    90 SET(ENV{OGRE_PLUGIN_DIR}       ${DEP_BINARY_DIR})
    91 SET(ENV{OPENALDIR}             ${DEP_INCLUDE_DIR}/openal)
    9282SET(ENV{POCODIR}               ${DEP_INCLUDE_DIR}/poco)
    93 LIST(APPEND CMAKE_INCLUDE_PATH ${DEP_INCLUDE_DIR}/tcl/include)
    94 LIST(APPEND CMAKE_INCLUDE_PATH ${DEP_INCLUDE_DIR}/zlib/include)
    9583
    9684### INSTALL ###
    97 
    98 # Tcl script library
    99 INSTALL(
    100   DIRECTORY ${DEP_LIBRARY_DIR}/tcl/
    101   DESTINATION lib/tcl
    102 )
    10385
    10486# On Windows, DLLs have to be in the executable folder, install them
  • code/forks/sandbox_light/cmake/PackageConfigMSVC.cmake

    r7818 r7908  
    5454  # Certain find scripts don't behave as ecpected to we have
    5555  # to specify the libraries ourselves.
    56   SET(TCL_LIBRARY  ${DEP_LIBRARY_DIR}/tcl85.lib CACHE FILEPATH "")
    57   SET(ZLIB_LIBRARY ${DEP_LIBRARY_DIR}/zdll.lib  CACHE FILEPATH "")
     56  #SET(ZLIB_LIBRARY ${DEP_LIBRARY_DIR}/zdll.lib  CACHE FILEPATH "")
    5857
    5958ENDIF(MSVC)
  • code/forks/sandbox_light/cmake/PackageConfigMinGW.cmake

    r5781 r7908  
    4747  # Certain find scripts don't behave as ecpected to we have
    4848  # to specify the libraries ourselves.
    49   SET(TCL_LIBRARY  ${DEP_BINARY_DIR}/tcl85.dll CACHE FILEPATH "")
    50   SET(ZLIB_LIBRARY ${DEP_BINARY_DIR}/zlib1.dll CACHE FILEPATH "")
     49  #SET(ZLIB_LIBRARY ${DEP_BINARY_DIR}/zlib1.dll CACHE FILEPATH "")
    5150
    5251ENDIF(MINGW)
  • code/forks/sandbox_light/cmake/tools/TargetUtilities.cmake

    r7818 r7908  
    3434 #      NO_DLL_INTERFACE:  Link statically with MSVC
    3535 #      NO_SOURCE_GROUPS:  Don't create msvc source groups
    36  #      MODULE:            For dynamic module libraries (libraries only)
    3736 #      WIN32:             Inherited from ADD_EXECUTABLE (executables only)
    3837 #      PCH_NO_DEFAULT:    Do not make precompiled header files default if
     
    4645 #      SOURCE_FILES:      Source files for the target
    4746 #      DEFINE_SYMBOL:     Sets the DEFINE_SYMBOL target property
    48  #      TOLUA_FILES:       Files with tolua interface
    4947 #      PCH_FILE:          Precompiled header file
    5048 #      PCH_EXCLUDE:       Source files to be excluded from PCH support
     
    6058INCLUDE(CMakeDependentOption)
    6159INCLUDE(CapitaliseName)
    62 INCLUDE(GenerateToluaBindings)
    6360INCLUDE(ParseMacroArguments)
    6461INCLUDE(SourceFileUtilities)
     
    8582                  NO_INSTALL         NO_VERSION        ${_additional_switches})
    8683  SET(_list_names LINK_LIBRARIES     VERSION           SOURCE_FILES
    87                   DEFINE_SYMBOL      TOLUA_FILES       PCH_FILE
     84                  DEFINE_SYMBOL      PCH_FILE
    8885                  PCH_EXCLUDE        OUTPUT_NAME)
    8986
     
    165162  LIST(REMOVE_DUPLICATES _${_target_name}_files)
    166163
    167   # TOLUA_FILES
    168   IF(_arg_TOLUA_FILES)
    169     GENERATE_TOLUA_BINDINGS(${_target_name_capitalised} _${_target_name}_files
    170                             INPUTFILES ${_arg_TOLUA_FILES})
    171   ENDIF()
    172 
    173164  # First part (pre target) of precompiled header files
    174165  IF(PCH_COMPILER_SUPPORT AND _arg_PCH_FILE)
     
    258249  ENDIF()
    259250
    260   # Configure modules
    261   IF (_arg_MODULE)
    262     SET_TARGET_PROPERTIES(${_target_name} PROPERTIES
    263       RUNTIME_OUTPUT_DIRECTORY ${CMAKE_MODULE_OUTPUT_DIRECTORY} # Windows
    264       LIBRARY_OUTPUT_DIRECTORY ${CMAKE_MODULE_OUTPUT_DIRECTORY} # Unix
    265     )
    266     ADD_MODULE(${_target_name})
    267     # Ensure that the main program depends on the module
    268     SET(ORXONOX_MODULES ${ORXONOX_MODULES} ${_target_name} CACHE STRING "" FORCE)
    269   ENDIF()
    270 
    271251  # Static library flags are not globally available
    272252  IF(ORXONOX_STATIC_LINKER_FLAGS)
     
    306286  # Install all targets except for static ones (executables also have SHARED in _link_mode)
    307287  IF(${_link_mode} STREQUAL "SHARED" AND NOT _arg_NO_INSTALL)
    308     IF(_arg_MODULE)
    309       INSTALL(TARGETS ${_target_name}
    310         RUNTIME DESTINATION ${MODULE_INSTALL_DIRECTORY}
    311         LIBRARY DESTINATION ${MODULE_INSTALL_DIRECTORY}
    312       )
    313     ELSE()
    314       INSTALL(TARGETS ${_target_name}
    315         RUNTIME DESTINATION ${RUNTIME_INSTALL_DIRECTORY}
    316         LIBRARY DESTINATION ${LIBRARY_INSTALL_DIRECTORY}
    317       )
    318     ENDIF()
     288    INSTALL(TARGETS ${_target_name}
     289      RUNTIME DESTINATION ${RUNTIME_INSTALL_DIRECTORY}
     290      LIBRARY DESTINATION ${LIBRARY_INSTALL_DIRECTORY}
     291    )
    319292  ENDIF()
    320293
    321294ENDMACRO(TU_ADD_TARGET)
    322 
    323 
    324 # Creates a helper file with name <name_of_the_library>${ORXONOX_MODULE_EXTENSION}
    325 # This helps finding dynamically loadable modules at runtime
    326 
    327 FUNCTION(ADD_MODULE _target)
    328   # We use the properties to get the name because the librarys name may differ from
    329   # the target name (for example orxonox <-> liborxonox)
    330 
    331   GET_TARGET_PROPERTY(_target_loc ${_target} LOCATION)
    332   GET_FILENAME_COMPONENT(_target_name ${_target_loc} NAME_WE)
    333 
    334   IF(CMAKE_CONFIGURATION_TYPES)
    335     FOREACH(_config ${CMAKE_CONFIGURATION_TYPES})
    336       SET(_module_filename ${CMAKE_MODULE_OUTPUT_DIRECTORY}/${_config}/${_target_name}${ORXONOX_MODULE_EXTENSION})
    337 
    338       FILE(WRITE ${_module_filename})
    339 
    340       INSTALL(
    341         FILES ${_module_filename}
    342         DESTINATION ${MODULE_INSTALL_DIRECTORY}
    343         CONFIGURATIONS ${_config}
    344       )
    345     ENDFOREACH()
    346   ELSE()
    347     SET(_module_filename ${CMAKE_MODULE_OUTPUT_DIRECTORY}/${_target_name}${ORXONOX_MODULE_EXTENSION})
    348 
    349     FILE(WRITE ${_module_filename})
    350 
    351     INSTALL(
    352       FILES ${_module_filename}
    353       DESTINATION ${MODULE_INSTALL_DIRECTORY}
    354     )
    355   ENDIF()
    356 ENDFUNCTION(ADD_MODULE)
Note: See TracChangeset for help on using the changeset viewer.