summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorPiotr Dziwinski <piotrdz@gmail.com>2013-03-22 22:24:35 +0100
committerPiotr Dziwinski <piotrdz@gmail.com>2013-03-22 22:24:35 +0100
commit87bc927d8757d6b9d7633260ff12580dcd48b3a4 (patch)
tree91694d494128c3fc2bf943f31fa693486ae605d2 /CMakeLists.txt
parent4a30800cf16d403a7c25d78388e2822aa396ac86 (diff)
downloadcolobot-87bc927d8757d6b9d7633260ff12580dcd48b3a4.tar.gz
colobot-87bc927d8757d6b9d7633260ff12580dcd48b3a4.tar.bz2
colobot-87bc927d8757d6b9d7633260ff12580dcd48b3a4.zip
Updated README files, optional libsndfile
* updated readme files * moved sndfile to optional * changed install paths on Windows
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt21
1 files changed, 14 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 60839be..607df20 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -125,10 +125,9 @@ option(GLEW_STATIC "Link statically with GLEW" OFF)
find_package(GLEW REQUIRED)
-include("${colobot_SOURCE_DIR}/cmake/FindLibSndFile.cmake")
-
if (${OPENAL_SOUND})
find_package(OpenAL REQUIRED)
+ include("${colobot_SOURCE_DIR}/cmake/FindLibSndFile.cmake")
endif()
@@ -229,11 +228,19 @@ if(${TESTS})
endif()
# Installation paths defined before compiling sources
-set(COLOBOT_INSTALL_BIN_DIR ${CMAKE_INSTALL_PREFIX}/games CACHE PATH "Colobot binary directory")
-set(COLOBOT_INSTALL_DATA_DIR ${CMAKE_INSTALL_PREFIX}/share/games/colobot CACHE PATH "Colobot shared data directory")
-set(COLOBOT_INSTALL_LIB_DIR ${CMAKE_INSTALL_PREFIX}/lib/colobot CACHE PATH "Colobot libraries directory")
-set(COLOBOT_INSTALL_DOC_DIR ${CMAKE_INSTALL_PREFIX}/share/doc/colobot CACHE PATH "Colobot documentation directory")
-set(COLOBOT_INSTALL_I18N_DIR ${CMAKE_INSTALL_PREFIX}/share/locale CACHE PATH "Colobot translations directory")
+if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
+ set(COLOBOT_INSTALL_BIN_DIR ${CMAKE_INSTALL_PREFIX}/ CACHE PATH "Colobot binary directory")
+ set(COLOBOT_INSTALL_LIB_DIR ${CMAKE_INSTALL_PREFIX}/ CACHE PATH "Colobot libraries directory")
+ set(COLOBOT_INSTALL_DATA_DIR ${CMAKE_INSTALL_PREFIX}/data CACHE PATH "Colobot shared data directory")
+ set(COLOBOT_INSTALL_I18N_DIR ${CMAKE_INSTALL_PREFIX}/ CACHE PATH "Colobot translations directory")
+ set(COLOBOT_INSTALL_DOC_DIR ${CMAKE_INSTALL_PREFIX}/doc CACHE PATH "Colobot documentation directory")
+else()
+ set(COLOBOT_INSTALL_BIN_DIR ${CMAKE_INSTALL_PREFIX}/games CACHE PATH "Colobot binary directory")
+ set(COLOBOT_INSTALL_LIB_DIR ${CMAKE_INSTALL_PREFIX}/lib/colobot CACHE PATH "Colobot libraries directory")
+ set(COLOBOT_INSTALL_DATA_DIR ${CMAKE_INSTALL_PREFIX}/share/games/colobot CACHE PATH "Colobot shared data directory")
+ set(COLOBOT_INSTALL_I18N_DIR ${CMAKE_INSTALL_PREFIX}/share/locale CACHE PATH "Colobot translations directory")
+ set(COLOBOT_INSTALL_DOC_DIR ${CMAKE_INSTALL_PREFIX}/share/doc/colobot CACHE PATH "Colobot documentation directory")
+endif()
# Subdirectory with sources
add_subdirectory(src bin)