]> SALOME platform Git repositories - modules/geom.git/blob - src/CurveCreator/CMakeLists.txt
Salome HOME
Old development made for salome Hydro:
[modules/geom.git] / src / CurveCreator / CMakeLists.txt
1 # Copyright (C) 2012-2020  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 IF(SALOME_BUILD_GUI)
21   INCLUDE(UseQtExt)
22 ENDIF(SALOME_BUILD_GUI)
23
24 # --- options ---
25
26 # additional include directories
27 INCLUDE_DIRECTORIES(
28   ${PTHREAD_INCLUDE_DIR}
29   ${CAS_INCLUDE_DIR}
30   ${KERNEL_INCLUDE_DIRS}
31   ${GUI_INCLUDE_DIRS}
32   ${PROJECT_SOURCE_DIR}/src/GEOMUtils
33 )
34
35 # additional preprocessor / compiler flags
36 ADD_DEFINITIONS(
37   ${CAS_DEFINITIONS}
38   ${OpenCASCADE_DEFINITIONS}
39   ${QT_DEFINITIONS}
40 )
41
42 # libraries to link to
43 SET(_link_LIBRARIES
44   ${CAS_KERNEL}
45   ${CAS_TKernel}
46   GEOMUtils
47 )
48 IF(SALOME_BUILD_GUI)
49   LIST(APPEND _link_LIBRARIES
50     ${GUI_qtx}
51     ${GUI_suit}
52     ${GUI_OCCViewer}
53   )
54 ENDIF(SALOME_BUILD_GUI)
55
56 # --- headers ---
57
58 IF(SALOME_BUILD_GUI)
59   # header files / to be processed by moc
60   SET(_moc_HEADERS
61     CurveCreator_NewSectionDlg.h
62     CurveCreator_TableView.h
63     CurveCreator_TreeView.h
64     CurveCreator_Widget.h
65   )
66 ENDIF(SALOME_BUILD_GUI)
67
68 # header files / no processing
69 SET(_other_HEADERS
70   CurveCreator.hxx
71   CurveCreator_Curve.hxx
72   CurveCreator_ShapeFilter.hxx
73   CurveCreator_Diff.hxx
74   CurveCreator_Displayer.hxx
75   CurveCreator_ICurve.hxx
76   CurveCreator_Macro.hxx
77   CurveCreator_Operation.hxx
78   CurveCreator_PosPoint.hxx
79   CurveCreator_Section.hxx
80   CurveCreator_UtilsICurve.hxx
81   CurveCreator_Utils.hxx
82 )
83
84 # header files / to install
85 SET(CurveCreator_HEADERS ${_moc_HEADERS} ${_other_HEADERS})
86
87 # --- sources ---
88
89 IF(SALOME_BUILD_GUI)
90   # sources / moc wrappings
91   QT_WRAP_MOC(_moc_SOURCES ${_moc_HEADERS})
92 ENDIF(SALOME_BUILD_GUI)
93
94 # sources / static
95 SET(_other_SOURCES
96   CurveCreator_Curve.cxx
97   CurveCreator_Diff.cxx
98   CurveCreator_Displayer.cxx
99   CurveCreator_ShapeFilter.cxx
100   CurveCreator_Operation.cxx
101   CurveCreator_Section.cxx
102   CurveCreator_Utils.cxx
103   CurveCreator_UtilsICurve.cxx
104 )
105 IF(SALOME_BUILD_GUI)
106   LIST(APPEND _other_SOURCES
107     CurveCreator_NewSectionDlg.cxx
108     CurveCreator_TableView.cxx
109     CurveCreator_TreeView.cxx
110     CurveCreator_Widget.cxx
111   )
112 ENDIF(SALOME_BUILD_GUI)
113
114 # sources / to compile
115 SET(CurveCreator_SOURCES ${_other_SOURCES} ${_moc_SOURCES})
116
117 # --- rules ---
118
119 ADD_LIBRARY(CurveCreator ${CurveCreator_SOURCES})
120 TARGET_LINK_LIBRARIES(CurveCreator ${_link_LIBRARIES})
121 INSTALL(TARGETS CurveCreator EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
122
123 INSTALL(FILES ${CurveCreator_HEADERS} DESTINATION ${SALOME_INSTALL_HEADERS})