]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
CMake: Fixed bug at installation: directories should be set after
authorbruneton <bruneton>
Fri, 21 Jun 2013 06:46:25 +0000 (06:46 +0000)
committerbruneton <bruneton>
Fri, 21 Jun 2013 06:46:25 +0000 (06:46 +0000)
prerequisite detection to have the correct Python version string.

CMakeLists.txt

index fc4c75bb2bfd22c179597e334d99fc2f0cc3c6b2..b4c0ef9f94bbfd6f85f782e45194c5f877739f6b 100755 (executable)
@@ -67,39 +67,6 @@ OPTION(SALOME_PACO_PARALLEL "Build with PACO in parallel" OFF)
 OPTION(SALOME_LAUNCHER_ONLY "Build only the Launcher part" OFF)
 MARK_AS_ADVANCED(SALOME_LIGHT_ONLY SALOME_USE_LIBBATCH SALOME_PACO_PARALLEL SALOME_LAUNCHER_ONLY)
 
-# Directories
-# ===========
-SET(SALOME_INSTALL_BINS bin/salome CACHE PATH "Install path: SALOME binaries")
-SET(SALOME_INSTALL_LIBS lib/salome CACHE PATH "Install path: SALOME libs")
-SET(SALOME_INSTALL_IDLS idl/salome CACHE PATH "Install path: SALOME IDL files")
-SET(SALOME_INSTALL_HEADERS include/salome CACHE PATH "Install path: SALOME headers")
-SET(SALOME_INSTALL_SCRIPT_SCRIPTS ${SALOME_INSTALL_BINS} CACHE PATH 
-   "Install path: SALOME scripts")
-SET(SALOME_INSTALL_SCRIPT_DATA ${SALOME_INSTALL_BINS} CACHE PATH 
-   "Install path: SALOME script data")
-SET(SALOME_INSTALL_SCRIPT_PYTHON ${SALOME_INSTALL_BINS} CACHE PATH 
-   "Install path: SALOME Python scripts")
-SET(SALOME_INSTALL_APPLISKEL_SCRIPTS ${SALOME_INSTALL_BINS}/appliskel CACHE PATH 
-   "Install path: SALOME application skeleton - scripts")
-SET(SALOME_INSTALL_APPLISKEL_PYTHON ${SALOME_INSTALL_BINS}/appliskel CACHE PATH 
-   "Install path: SALOME application skeleton - Python")
-SET(SALOME_INSTALL_CMAKE salome_adm/cmake_files CACHE PATH "Install path: SALOME CMake files")
-
-FIND_PACKAGE(PythonInterp)
-SET(_pydir lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages)
-SET(SALOME_INSTALL_PYTHON ${_pydir}/salome CACHE PATH "Install path: SALOME Python stuff")
-SET(SALOME_INSTALL_PYTHON_SHARED ${SALOME_INSTALL_PYTHON}/shared_modules CACHE PATH 
-   "Install path: SALOME Python shared modules")
-
-# Kernel specific:
-SET(SALOME_KERNEL_INSTALL_RES_DATA share/salome/resources/kernel CACHE PATH "Install path: SALOME KERNEL specific data")
-SET(SALOME_KERNEL_INSTALL_RES_SCRIPTS share/salome/resources/kernel CACHE PATH "Install path: SALOME KERNEL specific scripts")
-
-MARK_AS_ADVANCED(SALOME_INSTALL_BINS SALOME_INSTALL_LIBS SALOME_INSTALL_IDLS SALOME_INSTALL_HEADERS)
-MARK_AS_ADVANCED(SALOME_INSTALL_SCRIPT_SCRIPTS SALOME_INSTALL_SCRIPT_DATA SALOME_INSTALL_SCRIPT_PYTHON)
-MARK_AS_ADVANCED(SALOME_INSTALL_APPLISKEL_SCRIPTS  SALOME_INSTALL_APPLISKEL_PYTHON SALOME_INSTALL_CMAKE)
-MARK_AS_ADVANCED(SALOME_INSTALL_PYTHON SALOME_INSTALL_PYTHON_SHARED SALOME_KERNEL_INSTALL_RES_DATA SALOME_KERNEL_INSTALL_RES_SCRIPTS)
-
 # Required prerequisites
 #   Find "big" prerequisites first - they reference themselves many others
 #   -> this can help finding the smaller prerequisites and detect conficts.
@@ -148,6 +115,42 @@ IF(SALOME_BUILD_DOC)
   FIND_PACKAGE(SalomeSphinx REQUIRED)
 ENDIF()
 
+# Directories
+#
+# Directories have to be given after prerequisites (to be able to use
+# Python version string for example).
+# ===========
+SET(SALOME_INSTALL_BINS bin/salome CACHE PATH "Install path: SALOME binaries")
+SET(SALOME_INSTALL_LIBS lib/salome CACHE PATH "Install path: SALOME libs")
+SET(SALOME_INSTALL_IDLS idl/salome CACHE PATH "Install path: SALOME IDL files")
+SET(SALOME_INSTALL_HEADERS include/salome CACHE PATH "Install path: SALOME headers")
+SET(SALOME_INSTALL_SCRIPT_SCRIPTS ${SALOME_INSTALL_BINS} CACHE PATH 
+   "Install path: SALOME scripts")
+SET(SALOME_INSTALL_SCRIPT_DATA ${SALOME_INSTALL_BINS} CACHE PATH 
+   "Install path: SALOME script data")
+SET(SALOME_INSTALL_SCRIPT_PYTHON ${SALOME_INSTALL_BINS} CACHE PATH 
+   "Install path: SALOME Python scripts")
+SET(SALOME_INSTALL_APPLISKEL_SCRIPTS ${SALOME_INSTALL_BINS}/appliskel CACHE PATH 
+   "Install path: SALOME application skeleton - scripts")
+SET(SALOME_INSTALL_APPLISKEL_PYTHON ${SALOME_INSTALL_BINS}/appliskel CACHE PATH 
+   "Install path: SALOME application skeleton - Python")
+SET(SALOME_INSTALL_CMAKE salome_adm/cmake_files CACHE PATH "Install path: SALOME CMake files")
+
+FIND_PACKAGE(PythonInterp)
+SET(_pydir lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages)
+SET(SALOME_INSTALL_PYTHON ${_pydir}/salome CACHE PATH "Install path: SALOME Python stuff")
+SET(SALOME_INSTALL_PYTHON_SHARED ${SALOME_INSTALL_PYTHON}/shared_modules CACHE PATH 
+   "Install path: SALOME Python shared modules")
+
+# Kernel specific:
+SET(SALOME_KERNEL_INSTALL_RES_DATA share/salome/resources/kernel CACHE PATH "Install path: SALOME KERNEL specific data")
+SET(SALOME_KERNEL_INSTALL_RES_SCRIPTS share/salome/resources/kernel CACHE PATH "Install path: SALOME KERNEL specific scripts")
+
+MARK_AS_ADVANCED(SALOME_INSTALL_BINS SALOME_INSTALL_LIBS SALOME_INSTALL_IDLS SALOME_INSTALL_HEADERS)
+MARK_AS_ADVANCED(SALOME_INSTALL_SCRIPT_SCRIPTS SALOME_INSTALL_SCRIPT_DATA SALOME_INSTALL_SCRIPT_PYTHON)
+MARK_AS_ADVANCED(SALOME_INSTALL_APPLISKEL_SCRIPTS  SALOME_INSTALL_APPLISKEL_PYTHON SALOME_INSTALL_CMAKE)
+MARK_AS_ADVANCED(SALOME_INSTALL_PYTHON SALOME_INSTALL_PYTHON_SHARED SALOME_KERNEL_INSTALL_RES_DATA SALOME_KERNEL_INSTALL_RES_SCRIPTS)
+
 # Sources 
 # ========
 IF(NOT SALOME_LIGHT_ONLY)