[2626] | 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 | ################ Various Options ################ |
---|
| 21 | |
---|
[2621] | 22 | # various macro includes |
---|
| 23 | INCLUDE(FlagUtilities) |
---|
| 24 | INCLUDE(SourceFileUtilities) |
---|
| 25 | INCLUDE(GenerateToluaBindings) |
---|
| 26 | |
---|
| 27 | # Use TinyXML++ |
---|
| 28 | ADD_COMPILER_FLAGS("-DTIXML_USE_TICPP") |
---|
| 29 | # OIS dynamic linking requires macro definition, at least for Windows |
---|
| 30 | ADD_COMPILER_FLAGS("-DOIS_DYNAMIC_LIB") |
---|
[2625] | 31 | # Tolua binding speedup if required |
---|
[2621] | 32 | ADD_COMPILER_FLAGS("-DTOLUA_RELEASE" Release MinSizeRel TOLUA_PARSER_RELEASE) |
---|
| 33 | |
---|
[2619] | 34 | ################ OrxonoxConfig.h ################ |
---|
| 35 | |
---|
| 36 | # Copy and configure OrxonoxConfig which gets included in every file |
---|
| 37 | CONFIGURE_FILE(OrxonoxConfig.h.in ${CMAKE_CURRENT_BINARY_DIR}/OrxonoxConfig.h) |
---|
| 38 | |
---|
[2621] | 39 | |
---|
| 40 | ############## Include Directories ############## |
---|
| 41 | |
---|
[2509] | 42 | # Set the search paths for include files |
---|
| 43 | INCLUDE_DIRECTORIES( |
---|
[2621] | 44 | # External |
---|
[2509] | 45 | ${OGRE_INCLUDE_DIR} |
---|
| 46 | ${CEGUI_INCLUDE_DIR} |
---|
[2583] | 47 | ${ENET_INCLUDE_DIR} |
---|
[2509] | 48 | ${Boost_INCLUDE_DIRS} |
---|
[2630] | 49 | ${OPENAL_INCLUDE_DIRS} |
---|
[2509] | 50 | ${ALUT_INCLUDE_DIR} |
---|
| 51 | ${VORBIS_INCLUDE_DIR} |
---|
| 52 | ${OGG_INCLUDE_DIR} |
---|
| 53 | ${LUA_INCLUDE_DIR} |
---|
| 54 | ${TCL_INCLUDE_PATH} |
---|
[2621] | 55 | ${DIRECTX_INCLUDE_DIR} |
---|
[2509] | 56 | ${ZLIB_INCLUDE_DIR} |
---|
[1505] | 57 | |
---|
[2621] | 58 | # Internal |
---|
[2509] | 59 | . |
---|
| 60 | orxonox |
---|
[2621] | 61 | # Required for tolua bind and config files that are in the binary folder |
---|
[2509] | 62 | ${CMAKE_CURRENT_BINARY_DIR} |
---|
[2567] | 63 | ${CMAKE_CURRENT_BINARY_DIR}/orxonox |
---|
[2509] | 64 | ) |
---|
| 65 | |
---|
| 66 | |
---|
[2621] | 67 | ################ Sub Directories ################ |
---|
[2583] | 68 | |
---|
[2621] | 69 | # Third party libraries |
---|
[2610] | 70 | ADD_SUBDIRECTORY(tolua) |
---|
[2621] | 71 | |
---|
| 72 | # Include CEGUILua if not requested otherwise |
---|
| 73 | IF(CEGUILUA_USE_INTERNAL_LIBRARY) |
---|
| 74 | IF(NOT IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ceguilua/ceguilua-${CEGUI_VERSION}) |
---|
| 75 | MESSAGE(FATAL_ERROR "CEGUILua version not found in src folder. Update list of supported versions in LibraryConfig.cmake!") |
---|
[2624] | 76 | ENDIF() |
---|
[2621] | 77 | |
---|
| 78 | INCLUDE_DIRECTORIES(ceguilua/ceguilua-${CEGUI_VERSION}) |
---|
| 79 | ADD_SUBDIRECTORY(ceguilua) |
---|
[2624] | 80 | ENDIF() |
---|
[2621] | 81 | |
---|
[1505] | 82 | ADD_SUBDIRECTORY(cpptcl) |
---|
[2569] | 83 | ADD_SUBDIRECTORY(ogreceguirenderer) |
---|
[1505] | 84 | ADD_SUBDIRECTORY(ois) |
---|
| 85 | ADD_SUBDIRECTORY(tinyxml) |
---|
| 86 | |
---|
[2621] | 87 | # Orxonox code |
---|
[1505] | 88 | ADD_SUBDIRECTORY(util) |
---|
| 89 | ADD_SUBDIRECTORY(core) |
---|
[2621] | 90 | ADD_SUBDIRECTORY(audio) |
---|
[1505] | 91 | ADD_SUBDIRECTORY(network) |
---|
| 92 | ADD_SUBDIRECTORY(orxonox) |
---|