Changeset 5695 for code/trunk/cmake
- Timestamp:
- Aug 30, 2009, 2:22:00 AM (15 years ago)
- Location:
- code/trunk
- Files:
-
- 4 deleted
- 9 edited
- 4 copied
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/resource2 (added) merged: 3373-3374,5594,5597,5610-5611,5614,5624,5641,5644-5646,5650-5664,5667-5672,5682-5684,5688-5691,5694
- Property svn:mergeinfo changed
-
code/trunk/cmake/CheckOGREPlugins.cmake
r2710 r5695 32 32 # OGRE_PLUGINS_RELEASE Names of the release plugins without ext. 33 33 # Note: 34 # You must not specify render systems as input , but the ones found will be35 # present in the output variables.34 # You must not specify render systems as input. That will be taken care of 35 # automatically. 36 36 # 37 37 -
code/trunk/cmake/GenerateToluaBindings.cmake
r3368 r5695 30 30 # TOLUA_PARSER_SOURCE - Lua file with the parser source code 31 31 # TOLUA_PARSER_DEPENDENCIES - All the dependent lua files 32 # ORXONOX_RUNTIME_LIBRARY_DIRECTORY - Working directory32 # RUNTIME_LIBRARY_DIRECTORY - Working directory 33 33 # 34 34 … … 74 74 DEPENDS ${TOLUA_PARSER_DEPENDENCIES} 75 75 IMPLICIT_DEPENDS ${_implicit_dependencies} 76 WORKING_DIRECTORY ${ ORXONOX_RUNTIME_LIBRARY_DIRECTORY}76 WORKING_DIRECTORY ${RUNTIME_LIBRARY_DIRECTORY} 77 77 COMMENT "Generating tolua bind files for package ${_tolua_package}" 78 78 ) -
code/trunk/cmake/InstallConfig.cmake
r5694 r5695 43 43 SET(LIBRARY_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_LIBRARY_PATH}) 44 44 SET(ARCHIVE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_ARCHIVE_PATH}) 45 SET(MODULE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_MODULE_PATH}) 45 46 SET(DOC_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_DOC_PATH}) 46 47 SET(DATA_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${DEFAULT_DATA_PATH}) … … 54 55 SET(LIBRARY_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/lib/orxonox) 55 56 SET(ARCHIVE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/lib/orxonox/static) 57 SET(MODULE_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/lib/orxonox/modules) 56 58 SET(DOC_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/share/doc/orxonox) 57 59 SET(DATA_INSTALL_DIRECTORY ${CMAKE_INSTALL_PREFIX}/share/orxonox) … … 67 69 # When building, don't use the install RPATH already 68 70 # (but later on when installing) 69 SET(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE) 71 SET(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE) 70 72 71 73 # The RPATH to be used when installing -
code/trunk/cmake/LibraryConfig.cmake
r3304 r5695 31 31 # Prevent CMake from finding libraries in the installation folder on Windows. 32 32 # There might already be an installation from another compiler 33 IF( DEPENDENCY_PACKAGE_ENABLE)33 IF(WIN32) 34 34 LIST(REMOVE_ITEM CMAKE_SYSTEM_PREFIX_PATH "${CMAKE_INSTALL_PREFIX}") 35 35 LIST(REMOVE_ITEM CMAKE_SYSTEM_LIBRARY_PATH "${CMAKE_INSTALL_PREFIX}/bin") … … 72 72 73 73 # User script 74 SET( USER_SCRIPT_LIBRARY_CONFIG"" CACHE FILEPATH74 SET(LIBRARY_CONFIG_USER_SCRIPT "" CACHE FILEPATH 75 75 "Specify a CMake script if you wish to write your own library path config. 76 See LibraryConfigTardis.cmake or LibraryConfigMinGW.cmake for examples.") 77 IF(USER_SCRIPT_LIBRARY_CONFIG) 78 IF(EXISTS ${CMAKE_MODULE_PATH}/${USER_SCRIPT_LIBRARY_CONFIG}.cmake) 79 INCLUDE(${USER_SCRIPT_LIBRARY_CONFIG}) 80 ELSEIF(EXISTS ${USER_SCRIPT_LIBRARY_CONFIG}) 81 INCLUDE(${USER_SCRIPT_LIBRARY_CONFIG}) 82 ELSEIF(EXISTS ${CMAKE_MODULE_PATH}/${USER_SCRIPT_LIBRARY_CONFIG}) 83 INCLUDE(${CMAKE_MODULE_PATH}/${USER_SCRIPT_LIBRARY_CONFIG}) 84 ENDIF() 85 ENDIF(USER_SCRIPT_LIBRARY_CONFIG) 76 See LibraryConfigTardis.cmake for an example.") 77 IF(LIBRARY_CONFIG_USER_SCRIPT) 78 IF(EXISTS ${CMAKE_MODULE_PATH}/${LIBRARY_CONFIG_USER_SCRIPT}) 79 INCLUDE(${CMAKE_MODULE_PATH}/${LIBRARY_CONFIG_USER_SCRIPT}) 80 ENDIF() 81 ENDIF(LIBRARY_CONFIG_USER_SCRIPT) 86 82 87 83 … … 89 85 # Performs the search and sets the variables # 90 86 91 FIND_PACKAGE(OGRE 1.4 EXACTREQUIRED)87 FIND_PACKAGE(OGRE 1.4 REQUIRED) 92 88 FIND_PACKAGE(ENet 1.1 REQUIRED) 93 89 FIND_PACKAGE(Ogg REQUIRED) … … 185 181 ENDIF() 186 182 ENDIF(WIN32) 183 184 185 ################# OGRE Plugins ################## 186 187 # More plugins: Plugin_BSPSceneManager, Plugin_OctreeSceneManager 188 SET(OGRE_PLUGINS_INT Plugin_ParticleFX) 189 IF(WIN32) 190 # CG program manager is probably DirectX related (not available under unix) 191 LIST(APPEND OGRE_PLUGINS_INT Plugin_CgProgramManager) 192 ENDIF(WIN32) 193 SET(OGRE_PLUGINS ${OGRE_PLUGINS_INT} CACHE STRING 194 "Specify which OGRE plugins to load. Existance check is performed.") 195 196 # Check the plugins and determine the plugin folder 197 # You can give a hint by setting the environment variable ENV{OGRE_PLUGIN_DIR} 198 INCLUDE(CheckOGREPlugins) 199 CHECK_OGRE_PLUGINS(${OGRE_PLUGINS}) 200 -
code/trunk/cmake/PackageConfig.cmake
r3370 r5695 1 # General package configuration. Merely sets the include paths. 2 # Library files are treated separately. 1 # 2 # ORXONOX - the hottest 3D action shooter ever to exist 3 # > www.orxonox.net < 4 # 5 # This program is free software; you can redistribute it and/or 6 # modify it under the terms of the GNU General Public License 7 # as published by the Free Software Foundation; either version 2 8 # of the License, or (at your option) any later version. 9 # 10 # This program is distributed in the hope that it will be useful, 11 # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 # GNU General Public License for more details. 14 # 15 # You should have received a copy of the GNU General Public License along 16 # with this program; if not, write to the Free Software Foundation, 17 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 18 # 19 # 20 # Author: 21 # Reto Grieder 22 # Description: 23 # General package configuration. Merely sets the include paths. 24 # Library files are treated separately. 25 # 3 26 4 27 # Check package version info … … 28 51 ENDIF() 29 52 30 MESSAGE(STATUS "Using library package for the dependencies.") 53 IF(NOT _INTERNAL_PACKAGE_MESSAGE) 54 MESSAGE(STATUS "Using library package for the dependencies.") 55 SET(_INTERNAL_PACKAGE_MESSAGE 1 CACHE INTERNAL "Do not edit!" FORCE) 56 ENDIF() 31 57 32 58 # Include paths and other special treatments -
code/trunk/cmake/PackageConfigMSVC.cmake
r3370 r5695 47 47 48 48 # Also the directory with the runtime libraries 49 SET( ORXONOX_RUNTIME_LIBRARY_DIRECTORY ${DEP_BINARY_DIR})49 SET(RUNTIME_LIBRARY_DIRECTORY ${DEP_BINARY_DIR}) 50 50 51 51 # Sets the library path for the FIND_LIBRARY -
code/trunk/cmake/PackageConfigMinGW.cmake
r3196 r5695 40 40 41 41 # Also the directory with the runtime libraries 42 SET( ORXONOX_RUNTIME_LIBRARY_DIRECTORY ${DEP_BINARY_DIR})42 SET(RUNTIME_LIBRARY_DIRECTORY ${DEP_BINARY_DIR}) 43 43 44 44 # Sets the library path for the FIND_LIBRARY -
code/trunk/cmake/ParseMacroArguments.cmake
r3196 r5695 36 36 37 37 MACRO(PARSE_MACRO_ARGUMENTS _switches _list_names) 38 39 # Using LIST(FIND ...) speeds up the process 40 SET(_keywords ${_switches} ${_list_names}) 41 38 42 # Parse all the arguments and set the corresponding variable 39 43 # If the option is just a switch, set the variable to its name for later use 40 44 FOREACH(_arg ${ARGN}) 41 SET(_arg_found FALSE)42 45 43 # Switches 44 FOREACH(_switch ${_switches}) 45 IF(${_switch} STREQUAL ${_arg}) 46 SET(_arg_${_switch} ${_switch}) 47 SET(_arg_found TRUE) 48 # Avoid interpreting arguments after this one as options args for the previous one 49 SET(_storage_var) 50 BREAK() 51 ENDIF() 52 ENDFOREACH(_switch) 46 # Is the argument a keyword? 47 LIST(FIND _keywords ${_arg} _keyword_index) 48 IF(NOT _keyword_index EQUAL -1) 53 49 54 # Input options 55 IF(NOT _arg_found) 56 FOREACH(_list_name ${_list_names}) 57 IF(${_list_name} STREQUAL ${_arg}) 58 SET(_storage_var _arg_${_list_name}) 59 SET(_arg_found TRUE) 50 # Another optimisation 51 SET(_arg_found FALSE) 52 # Switches 53 FOREACH(_switch ${_switches}) 54 IF(${_switch} STREQUAL ${_arg}) 55 SET(_arg_${_switch} ${_switch}) 56 SET(_arg_found TRUE) 57 # Avoid interpreting arguments after this one as options args for the previous one 58 SET(_storage_var) 60 59 BREAK() 61 60 ENDIF() 62 ENDFOREACH(_list_name) 63 ENDIF(NOT _arg_found) 61 ENDFOREACH(_switch) 64 62 65 # Arguments of an input option (like source files for SOURCE_FILES) 66 IF(NOT _arg_found) 63 # Input options 64 IF(NOT _arg_found) 65 FOREACH(_list_name ${_list_names}) 66 IF(${_list_name} STREQUAL ${_arg}) 67 SET(_storage_var _arg_${_list_name}) 68 BREAK() 69 ENDIF() 70 ENDFOREACH(_list_name) 71 ENDIF(NOT _arg_found) 72 73 ELSE() 74 75 # Arguments of an input option (like source files for SOURCE_FILES) 67 76 IF(_storage_var) 68 77 # Store in variable define above in the foreach loop … … 71 80 MESSAGE(FATAL_ERROR "ORXONOX_ADD_${_target_type} was given a non compliant argument: ${_arg}") 72 81 ENDIF(_storage_var) 73 ENDIF(NOT _arg_found) 82 83 ENDIF() 74 84 75 85 ENDFOREACH(_arg) -
code/trunk/cmake/TargetUtilities.cmake
r5693 r5695 58 58 # 59 59 60 INCLUDE(CMakeDependentOption) 60 61 INCLUDE(CapitaliseName) 61 62 INCLUDE(GenerateToluaBindings) … … 118 119 119 120 # First part (pre target) of precompiled header files 120 IF(PCH_COMPILER_SUPPORT AND PCH_ENABLE AND_arg_PCH_FILE)121 IF(PCH_COMPILER_SUPPORT AND _arg_PCH_FILE) 121 122 # Provide convenient option to control PCH 122 123 STRING(TOUPPER "${_target_name}" _target_name_upper) … … 126 127 SET(PCH_DEFAULT TRUE) 127 128 ENDIF() 128 OPTION(PCH_ENABLE_${_target_name_upper} "Enable using precompiled header files for library ${_target_name}." ${PCH_DEFAULT}) 129 CMAKE_DEPENDENT_OPTION(PCH_ENABLE_${_target_name_upper} 130 "Enable using precompiled header files for library ${_target_name}." ${PCH_DEFAULT} PCH_ENABLE OFF) 129 131 130 132 IF(PCH_ENABLE_${_target_name_upper}) … … 203 205 IF(_arg_MODULE) 204 206 INSTALL(TARGETS ${_target_name} 205 RUNTIME DESTINATION ${ ORXONOX_MODULE_INSTALL_PATH}206 LIBRARY DESTINATION ${ ORXONOX_MODULE_INSTALL_PATH}207 RUNTIME DESTINATION ${MODULE_INSTALL_DIRECTORY} 208 LIBRARY DESTINATION ${MODULE_INSTALL_DIRECTORY} 207 209 ) 208 210 ELSE() 209 211 INSTALL(TARGETS ${_target_name} 210 RUNTIME DESTINATION ${ ORXONOX_RUNTIME_INSTALL_PATH}211 LIBRARY DESTINATION ${ ORXONOX_LIBRARY_INSTALL_PATH}212 RUNTIME DESTINATION ${RUNTIME_INSTALL_DIRECTORY} 213 LIBRARY DESTINATION ${LIBRARY_INSTALL_DIRECTORY} 212 214 ) 213 215 ENDIF() … … 217 219 218 220 219 # Creates a helper file with name <name_of_the_library> .module221 # Creates a helper file with name <name_of_the_library>${ORXONOX_MODULE_EXTENSION} 220 222 # This helps finding dynamically loadable modules at runtime 221 223 … … 235 237 INSTALL( 236 238 FILES ${_module_filename} 237 DESTINATION ${ ORXONOX_MODULE_INSTALL_PATH}239 DESTINATION ${MODULE_INSTALL_DIRECTORY} 238 240 CONFIGURATIONS ${_config} 239 241 ) … … 246 248 INSTALL( 247 249 FILES ${_module_filename} 248 DESTINATION ${ ORXONOX_MODULE_INSTALL_PATH}250 DESTINATION ${MODULE_INSTALL_DIRECTORY} 249 251 ) 250 252 ENDIF()
Note: See TracChangeset
for help on using the changeset viewer.