Changeset 8264
- Timestamp:
- Apr 19, 2011, 6:00:12 AM (14 years ago)
- Location:
- code/trunk/cmake
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/cmake/LibraryConfig.cmake
r7955 r8264 202 202 ################# OGRE Plugins ################## 203 203 204 # More plugins: Plugin_BSPSceneManager, Plugin_OctreeSceneManager205 SET(OGRE_PLUGINS_INT Plugin_ParticleFX)206 IF(WIN32)207 # CG program manager is probably DirectX related (not available under unix)208 LIST(APPEND OGRE_PLUGINS_INT Plugin_CgProgramManager)209 ENDIF(WIN32)210 SET(OGRE_PLUGINS ${OGRE_PLUGINS_INT} CACHE STRING211 "Specify which OGRE plugins to load. Existance check is performed.")212 213 204 # Check the plugins and determine the plugin folder 214 205 # You can give a hint by setting the environment variable ENV{OGRE_PLUGIN_DIR} 215 206 INCLUDE(CheckOGREPlugins) 216 CHECK_OGRE_PLUGINS(${OGRE_PLUGINS}) 217 207 # Note 1: First argument (as string!) are for mandatory plugins, second one is 208 # for optional ones. 209 # Note 2: Render systems are found automatically (at least one required) 210 CHECK_OGRE_PLUGINS("Plugin_ParticleFX" "Plugin_CgProgramManager") 211 -
code/trunk/cmake/tools/CheckOGREPlugins.cmake
r7163 r8264 21 21 # Reto Grieder 22 22 # Description: 23 # Function that checks each OGRE plugin for existance. Also looks for debug 24 # versions and sets them accordingly. 25 # All the plugins specified as function arguments have to be found or the 26 # script will issue a fatal error. Additionally, all release plugins have 27 # to be found in the same folder. Analogously for debug plugins. 23 # Finds OGRE plugins and their folder, which has to be unique each set 24 # of plugins (Debug, Release). 25 # Specify arguments as strings: mandatory and optional plugins. 26 # Input: 27 # _mandatory_plugins Have to be found, error issued otherwise 28 # _optional_plugins Added as well if found 28 29 # Output: 29 # OGRE_PLUGINS_FOLDER_DEBUG Folder with the debug plugins30 # OGRE_PLUGINS_FOLDER_RELEASE Folder with the release plugins31 # OGRE_PLUGINS_DEBUG Names of the debug plugins without extension32 # OGRE_PLUGINS_RELEASE Names of the release plugins without ext.30 # OGRE_PLUGINS_FOLDER_DEBUG Folder with the debug plugins 31 # OGRE_PLUGINS_FOLDER_RELEASE Folder with the release plugins 32 # OGRE_PLUGINS_DEBUG Names of the debug plugins without extension 33 # OGRE_PLUGINS_RELEASE Names of the release plugins without ext. 33 34 # Note: 34 35 # You must not specify render systems as input. That will be taken care of … … 36 37 # 37 38 38 FUNCTION(CHECK_OGRE_PLUGINS) 39 40 SET(OGRE_PLUGINS ${ARGN}) 39 FUNCTION(CHECK_OGRE_PLUGINS _mandatory_plugins _optional_plugins) 41 40 42 41 IF(WIN32) … … 49 48 SET(OGRE_RENDER_SYSTEMS RenderSystem_GL RenderSystem_Direct3D9) 50 49 SET(OGRE_RENDER_SYSTEM_FOUND FALSE) 51 FOREACH(_plugin ${ OGRE_PLUGINS} ${OGRE_RENDER_SYSTEMS})50 FOREACH(_plugin ${_mandatory_plugins} ${_optional_plugins} ${OGRE_RENDER_SYSTEMS}) 52 51 FIND_LIBRARY(OGRE_PLUGIN_${_plugin}_OPTIMIZED 53 52 NAMES ${_plugin} … … 62 61 # We only need at least one render system. Check at the end. 63 62 IF(NOT ${_plugin} MATCHES "RenderSystem") 64 IF( NOT OGRE_PLUGIN_${_plugin}_OPTIMIZED)63 IF(${_plugin} MATCHES "${_mandatory_plugins}" AND NOT OGRE_PLUGIN_${_plugin}_OPTIMIZED) 65 64 MESSAGE(FATAL_ERROR "Could not find OGRE plugin named ${_plugin}") 66 65 ENDIF()
Note: See TracChangeset
for help on using the changeset viewer.