Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/buildsystem2/CMakeLists.txt @ 2620

Last change on this file since 2620 was 2612, checked in by rgrieder, 16 years ago

Rearranged CMake configuration code. I split serveral files in two and moved some code around.
There are no actual code changes!

Details:

  • Everything that involves library finding is in LibraryConfig.cmake. It includes other LibraryConfigXXX.cmake files that set specific options for certain platforms or package configurations (like MSVC or MinGW dependency package).
  • All build related code is in BuildConfig.cmake. The actual compiler configuration is done in BuildConfigXXX.cmake where XXX can be GCC or MSVC.
  • The changes above implied splitting FindOGRE.cmake in two (was going to do it anyway, but rather in a later commit) so that CheckOGREPlugins.cmake is now a separate module.
  • Property svn:eol-style set to native
File size: 848 bytes
Line 
1PROJECT(Orxonox C CXX)
2
3CMAKE_MINIMUM_REQUIRED(VERSION 2.6 FATAL_ERROR)
4
5SET(ORXONOX_VERSION_MAJOR 0)
6SET(ORXONOX_VERSION_MINOR 1)
7SET(ORXONOX_VERSION_PATCH 0)
8SET(ORXONOX_VERSION 0.1.0)
9
10# Keep devs from using the root directory as binary directory (messes up the source tree)
11IF(${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_BINARY_DIR})
12  MESSAGE(FATAL_ERROR "Do not use the root directory as CMake output directory! mkdir build; cd build; cmake ..")
13ENDIF(${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_CURRENT_BINARY_DIR})
14
15# This sets where to look for modules (e.g. "Find*.cmake" files)
16SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
17
18# Library Config
19INCLUDE(LibraryConfig)
20
21# Build Config
22INCLUDE(BuildConfig)
23
24# Creates the actual project
25ADD_SUBDIRECTORY(src)
26
27# Configure the binary output directory
28ADD_SUBDIRECTORY(bin-config)
Note: See TracBrowser for help on using the repository browser.