Salome HOME
Introduction of CMake build procedure for YACS module.
[modules/yacs.git] / src / salomewrap / CMakeLists.txt
1 # Copyright (C) 2012-2013  CEA/DEN, EDF R&D
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.
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 INCLUDE(${QT_USE_FILE})
21
22 # --- options ---
23
24 IF(SALOME_YACS_USE_KERNEL)
25   SET(SALOME_INCL_PATH ${KERNEL_INCLUDE_DIRS})
26 ENDIF(SALOME_YACS_USE_KERNEL)
27
28 # additional include directories
29 INCLUDE_DIRECTORIES(
30   ${OMNIORB_INCLUDE_DIR}
31   ${QT_INCLUDE_DIR}
32   ${SALOME_INCL_PATH}
33   ${GUI_INCLUDE_DIRS}
34   ${PROJECT_SOURCE_DIR}/src/bases
35   )
36
37 # additional preprocessor / compiler flags
38 ADD_DEFINITIONS(
39   -DYACS_PTHREAD
40   ${PYTHON_DEFINITIONS}
41   ${OMNIORB_DEFINITIONS}
42   ${BOOST_DEFINITIONS}
43   ${QT_DEFINITIONS}
44   )
45
46 # libraries to link to
47 SET(_link_LIBRARIES
48   QtCore
49   QtGui
50   ${OMNIORB_LIBRARIES}
51   YACSlibEngine
52   SalomeIDLKernel
53   CAM
54   suit
55   LightApp
56   qtx
57   QxScene
58   ObjBrowser
59   SalomeApp
60   )
61
62 # header files / to be processed by moc
63 SET(_moc_HEADERS
64   SalomeWrap_Module.hxx
65   WrapGraphicsView.hxx
66   )
67
68 # --- sources ---
69
70 # sources / moc wrappings
71 QT4_WRAP_CPP(_moc_SOURCES ${_moc_HEADERS})
72
73 SET(SalomeWrap_SOURCES
74   SalomeWrapExport.hxx
75   SalomeWrap_Module.hxx
76   SalomeWrap_Module.cxx
77   SalomeWrap_DataModel.hxx
78   SalomeWrap_DataModel.cxx
79   SuitWrapper.hxx
80   SuitWrapper.cxx
81   WrapGraphicsView.hxx
82   WrapGraphicsView.cxx
83   ${_moc_SOURCES}
84   )
85
86 # --- rules ---
87
88 ADD_LIBRARY(SalomeWrap ${SalomeWrap_SOURCES})
89 TARGET_LINK_LIBRARIES(SalomeWrap ${_link_LIBRARIES})
90 INSTALL(TARGETS SalomeWrap EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})