CMakeLists.txt
changeset 8333 416cb5e5a405
parent 8331 217c3fd72a2d
child 8347 716c05f19401
--- a/CMakeLists.txt	Thu Dec 27 13:24:57 2012 +0100
+++ b/CMakeLists.txt	Thu Dec 27 15:32:48 2012 +0100
@@ -23,9 +23,11 @@
 option(ANDROID "Enable Android build [default: off]" OFF)
 option(NOAUTOUPDATE "Disable OS X Sparkle update checking" OFF)
 option(MINIMAL_FLAGS "Respect system flags as much as possible [default: off]" OFF)
-set(FPFLAGS "" CACHE STRING "Additional Freepascal flags" FORCE)
-set(GHFLAGS "" CACHE STRING "Additional Haskell flags" FORCE)
-
+set(FPFLAGS "" CACHE STRING "Additional Freepascal flags")
+set(GHFLAGS "" CACHE STRING "Additional Haskell flags")
+if(UNIX AND NOT APPLE)
+    set(DATA_INSTALL_DIR "share/hedgewars" CACHE STRING "Resource folder path")
+endif()
 
 #detect Mercurial revision (if present)
 if(NOT NOREVISION)
@@ -72,11 +74,7 @@
 if(UNIX AND NOT APPLE)
     set(target_binary_install_dir "bin")
     set(target_library_install_dir "lib")
-    if(DEFINED DATA_INSTALL_DIR)
-        set(SHAREPATH "${DATA_INSTALL_DIR}/")
-    else()
-        set(SHAREPATH "share/hedgewars/")
-    endif()
+    set(SHAREPATH "${DATA_INSTALL_DIR}/")
 else()
     set(target_binary_install_dir "./")