Salome HOME
show GUI in salome
[tools/solverlab.git] / CoreFlows / gui / CMakeLists.txt
1 # Copyright (C) 2012-2021  CEA/DEN, EDF R&D, OPEN CASCADE
2 #
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
7 #
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 # Lesser General Public License for more details.
12 #
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 #
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 #
19
20
21
22 SET(GUI_bin_SCRIPTS
23     ${CMAKE_CURRENT_SOURCE_DIR}/CoreFlows_Standalone.py
24 )
25
26 SET(GUI_lib_SCRIPTS
27     ${CMAKE_CURRENT_SOURCE_DIR}/CFDesktop.py
28 )
29
30
31 IF   ( (EXISTS $ENV{CONFIGURATION_ROOT_DIR}) AND (EXISTS $ENV{KERNEL_ROOT_DIR}) AND (EXISTS $ENV{GUI_ROOT_DIR}) )
32   ADD_SUBDIRECTORY(salome)
33 ELSE ( (EXISTS $ENV{CONFIGURATION_ROOT_DIR}) AND (EXISTS $ENV{KERNEL_ROOT_DIR}) AND (EXISTS $ENV{GUI_ROOT_DIR}) )
34   INSTALL(FILES ${GUI_bin_SCRIPTS} DESTINATION bin/salome)
35   INSTALL(FILES ${GUI_lib_SCRIPTS} DESTINATION lib/python)
36
37   # Configure file SalomePyQt_MockUp.py
38   SET(SGPYQT_RES_DIR "share/salome/resources")
39   configure_file(
40       SalomePyQt_MockUp.py.in
41       SalomePyQt_MockUp.py
42       @ONLY
43   )
44   INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/SalomePyQt_MockUp.py DESTINATION lib/python)
45   # Configure file utils.py
46   SET(SALOME_INSTALL_PYTHON "lib/python"${PYTHON_VERSION}"/site-packages/salome")#This is to use the same variable as salome
47   configure_file(
48       utils.py.in
49       utils.py
50       @ONLY
51   )
52   INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/utils.py DESTINATION lib/python)
53 ENDIF( (EXISTS $ENV{CONFIGURATION_ROOT_DIR}) AND (EXISTS $ENV{KERNEL_ROOT_DIR}) AND (EXISTS $ENV{GUI_ROOT_DIR}) )
54
55 ADD_SUBDIRECTORY(ui)
56