X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=SalomePARAVISConfig.cmake.in;h=07fe64e2325940bb6c559af84104464729ffe56f;hb=fb576423db54e3b895b4496d35c9f0f6a255ff9b;hp=d90d4bac980127294977f77f2cc66598de185bc2;hpb=65f3f594f8105b6a6dc3f08aa1ef18893a84bb02;p=modules%2Fparavis.git diff --git a/SalomePARAVISConfig.cmake.in b/SalomePARAVISConfig.cmake.in index d90d4bac..07fe64e2 100644 --- a/SalomePARAVISConfig.cmake.in +++ b/SalomePARAVISConfig.cmake.in @@ -5,28 +5,24 @@ # ############################################################### -# Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE +# Copyright (C) 2007-2014 CEA/DEN, EDF R&D # -# Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License, or (at your option) any later version. # -# This library is free software; you can redistribute it and/or -# modify it under the terms of the GNU Lesser General Public -# License as published by the Free Software Foundation; either -# version 2.1 of the License. +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. # -# This library is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Lesser General Public License for more details. +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # -# You should have received a copy of the GNU Lesser General Public -# License along with this library; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com # -# See http://www.salome-platform.org/ or -# email : webmaster.salome@opencascade.com -############################################################### ### Initialisation performed by CONFIGURE_PACKAGE_CONFIG_FILE: @PACKAGE_INIT@ @@ -34,7 +30,7 @@ # Load the dependencies for the libraries of @PROJECT_NAME@ # (contains definitions for IMPORTED targets). This is only # imported if we are not built as a subproject (in this case targets are already there) -IF(NOT TARGET Event AND NOT @PROJECT_NAME@_BINARY_DIR) +IF(NOT TARGET PARAVIS AND NOT @PROJECT_NAME@_BINARY_DIR) INCLUDE("@PACKAGE_SALOME_INSTALL_CMAKE_LOCAL@/@PROJECT_NAME@Targets.cmake") ENDIF() @@ -44,7 +40,7 @@ SET_AND_CHECK(PARAVIS_ROOT_DIR_EXP "@PACKAGE_CMAKE_INSTALL_PREFIX@") # Include directories SET_AND_CHECK(PARAVIS_INCLUDE_DIRS "${PARAVIS_ROOT_DIR_EXP}/@SALOME_INSTALL_HEADERS@") SET(PARAVIS_INCLUDE_DIRS "${PARAVIS_INCLUDE_DIRS};@_SalomePARAVIS_EXTRA_HEADERS@") -SET(PARAVIS_DEFINITIONS "@KERNEL_DEFINITIONS@") +SET(PARAVIS_DEFINITIONS "@GUI_DEFINITIONS@") # Package specific environment variables @_SalomePARAVIS_EXTRA_ENV_FULL@ @@ -52,9 +48,9 @@ SET(PARAVIS_DEFINITIONS "@KERNEL_DEFINITIONS@") #### Now the specificities # Options exported by the package: -SET(SALOME_BUILD_DOC @SALOME_BUILD_DOC@) -SET(SALOME_BUILD_TESTS @SALOME_BUILD_TESTS@) -SET(SALOME_LIGHT_ONLY @SALOME_LIGHT_ONLY@) +SET(SALOME_PARAVIS_BUILD_DOC @SALOME_BUILD_DOC@) +SET(SALOME_PARAVIS_BUILD_TESTS @SALOME_BUILD_TESTS@) +SET(SALOME_PARAVIS_LIGHT_ONLY @SALOME_LIGHT_ONLY@) # Advanced options SET(SALOME_USE_OCCVIEWER @SALOME_USE_OCCVIEWER@) @@ -64,9 +60,12 @@ SET(SALOME_USE_PLOT2DVIEWER @SALOME_USE_PLOT2DVIEWER@) # Level 1 prerequisites: SET_AND_CHECK(KERNEL_ROOT_DIR_EXP "@PACKAGE_KERNEL_ROOT_DIR@") -SET_AND_CHECK(SIP_ROOT_DIR_EXP "@PACKAGE_SIP_ROOT_DIR@") -SET_AND_CHECK(QT4_ROOT_DIR_EXP "@PACKAGE_QT4_ROOT_DIR@") -SET_AND_CHECK(PYQT4_ROOT_DIR_EXP "@PACKAGE_PYQT4_ROOT_DIR@") +SET_AND_CHECK(GUI_ROOT_DIR_EXP "@PACKAGE_GUI_ROOT_DIR@") +IF(SALOME_PARAVIS_BUILD_PLUGINS) + SET_AND_CHECK(MED_ROOT_DIR_EXP "@PACKAGE_MED_ROOT_DIR@") + LIST(APPEND PARAVIS_DEFINITIONS "@MED_DEFINITIONS@") +ENDIF() +SET_AND_CHECK(MEDFILE_ROOT_DIR_EXP "@PACKAGE_MEDFILE_ROOT_DIR@") # Optional level 1 prerequisites: @@ -77,26 +76,28 @@ SET(_PREREQ @_PREREQ_LIST@) SET(_PREREQ_CONFIG_DIR @_PREREQ_DIR_LIST@) SET(_PREREQ_COMPONENTS "@_PREREQ_COMPO_LIST@") LIST(LENGTH _PREREQ_CONFIG_DIR _list_len) -# Another CMake stupidity - FOREACH(... RANGE r) generates r+1 numbers ... -MATH(EXPR _range "${_list_len}-1") -FOREACH(_p RANGE ${_range}) - LIST(GET _PREREQ ${_p} _pkg ) - LIST(GET _PREREQ_CONFIG_DIR ${_p} _pkg_dir) - LIST(GET _PREREQ_COMPONENTS ${_p} _pkg_compo) - MESSAGE(STATUS "===> Reloading targets from ${_pkg} ...") - IF(NOT _pkg_compo) - FIND_PACKAGE(${_pkg} REQUIRED NO_MODULE +IF(NOT _list_len EQUAL 0) + # Another CMake stupidity - FOREACH(... RANGE r) generates r+1 numbers ... + MATH(EXPR _range "${_list_len}-1") + FOREACH(_p RANGE ${_range}) + LIST(GET _PREREQ ${_p} _pkg ) + LIST(GET _PREREQ_CONFIG_DIR ${_p} _pkg_dir) + LIST(GET _PREREQ_COMPONENTS ${_p} _pkg_compo) + MESSAGE(STATUS "===> Reloading targets from ${_pkg} ...") + IF(NOT _pkg_compo) + FIND_PACKAGE(${_pkg} REQUIRED NO_MODULE PATHS "${_pkg_dir}" NO_DEFAULT_PATH) - ELSE() - STRING(REPLACE "," ";" _compo_lst "${_pkg_compo}") - MESSAGE(STATUS "===> (components: ${_pkg_compo})") - FIND_PACKAGE(${_pkg} REQUIRED NO_MODULE + ELSE() + STRING(REPLACE "," ";" _compo_lst "${_pkg_compo}") + MESSAGE(STATUS "===> (components: ${_pkg_compo})") + FIND_PACKAGE(${_pkg} REQUIRED NO_MODULE COMPONENTS ${_compo_lst} PATHS "${_pkg_dir}" NO_DEFAULT_PATH) - ENDIF() -ENDFOREACH() + ENDIF() + ENDFOREACH() +ENDIF() # Installation directories SET(SALOME_INSTALL_BINS "@SALOME_INSTALL_BINS@") @@ -116,9 +117,20 @@ SET(SALOME_INSTALL_RES "@SALOME_INSTALL_RES@") SET(SALOME_INSTALL_DOC "@SALOME_INSTALL_DOC@") SET(SALOME_INSTALL_AMCONFIG_LOCAL "@SALOME_INSTALL_AMCONFIG_LOCAL@") -# Include KERNEL targets if they were not already loaded: -IF(NOT (TARGET SALOMEBasics)) - INCLUDE("${KERNEL_ROOT_DIR_EXP}/${SALOME_INSTALL_CMAKE}/SalomeKERNELTargets.cmake") +# Include GUI targets if they were not already loaded: +IF(NOT (TARGET Event)) + INCLUDE("${GUI_ROOT_DIR_EXP}/${SALOME_INSTALL_CMAKE_LOCAL}/SalomeGUITargets.cmake") +ENDIF() +IF(SALOME_PARAVIS_BUILD_PLUGINS) + # Include MED targets if they were not already loaded: + IF(NOT (TARGET SalomeIDLMED)) + INCLUDE("${MED_ROOT_DIR_EXP}/${SALOME_INSTALL_CMAKE_LOCAL}/SalomeMEDTargets.cmake") + ENDIF() ENDIF() # Exposed PARAVIS targets: +SET(PARAVIS_SalomeIDLPARAVIS SalomeIDLPARAVIS) +SET(PARAVIS_PARAVIS PARAVIS) +SET(PARAVIS_PARAVISEngine PARAVISEngine) +SET(PARAVIS_PVViewer PVViewer) +