1 # Copyright (C) 2012-2013 CEA/DEN, EDF R&D
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.
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.
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
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 ADD_SUBDIRECTORY(Test)
25 ${PARMETIS_INCLUDE_DIRS}
27 ${SCOTCH_INCLUDE_DIRS}
29 ${LIBXML_INCLUDE_DIRS}
33 ${PTHREADS_INCLUDE_DIRS}
34 ${CMAKE_CURRENT_SOURCE_DIR}/../MEDLoader
35 ${CMAKE_CURRENT_SOURCE_DIR}/../MEDCoupling
36 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL
37 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/Bases
38 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/Geometric2D
39 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/ExprEval
40 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/GaussPoints
43 SET(medpartitionercpp_HEADERS_HXX
44 MEDPARTITIONER_MeshCollection.hxx
45 MEDPARTITIONER_MeshCollectionDriver.hxx
46 MEDPARTITIONER_MeshCollectionMedXmlDriver.hxx
47 MEDPARTITIONER_MeshCollectionMedAsciiDriver.hxx
48 MEDPARTITIONER_ParallelTopology.hxx
49 MEDPARTITIONER_JointFinder.hxx
50 MEDPARTITIONER_Graph.hxx
51 MEDPARTITIONER_UserGraph.hxx
52 MEDPARTITIONER_Utils.hxx
54 MEDPARTITIONER_ParaDomainSelector.hxx
55 MEDPARTITIONER_ConnectZone.hxx
56 MEDPARTITIONER_SkyLineArray.hxx
57 MEDPARTITIONER_Topology.hxx
60 SET(medpartitionercpp_SOURCES
61 MEDPARTITIONER_MeshCollection.cxx
62 MEDPARTITIONER_MeshCollectionDriver.cxx
63 MEDPARTITIONER_MeshCollectionMedXmlDriver.cxx
64 MEDPARTITIONER_MeshCollectionMedAsciiDriver.cxx
65 MEDPARTITIONER_ParallelTopology.cxx
66 MEDPARTITIONER_Graph.cxx
67 MEDPARTITIONER_UserGraph.cxx
68 MEDPARTITIONER_Utils.cxx
69 MEDPARTITIONER_ParaDomainSelector.cxx
70 MEDPARTITIONER_ConnectZone.cxx
71 MEDPARTITIONER_SkyLineArray.cxx
72 MEDPARTITIONER_metis.c
75 SET(medpartitionercpp_DEFINITIONS "${HDF5_DEFINITIONS} ${MED3_DEFINITIONS} ${LIBXML_DEFINITIONS} ${MPI_DEFINITIONS}")
76 SET(medpartitionercpp_LDFLAGS
86 IF(MED_ENABLE_PARMETIS)
87 SET(medpartitionercpp_HEADERS_HXX ${medpartitionercpp_HEADERS_HXX} MEDPARTITIONER_ParMetisGraph.hxx)
88 SET(medpartitionercpp_SOURCES ${medpartitionercpp_SOURCES} MEDPARTITIONER_ParMetisGraph.cxx)
89 SET(medpartitionercpp_DEFINITIONS "${medpartitionercpp_DEFINITIONS} ${PARMETIS_DEFINITIONS}")
90 SET(medpartitionercpp_LDFLAGS ${medpartitionercpp_LDFLAGS} ${PARMETIS_LIBS})
91 ENDIF(MED_ENABLE_PARMETIS)
93 SET(medpartitionercpp_HEADERS_HXX ${medpartitionercpp_HEADERS_HXX} MEDPARTITIONER_MetisGraph.hxx)
94 SET(medpartitionercpp_SOURCES ${medpartitionercpp_SOURCES} MEDPARTITIONER_MetisGraph.cxx)
95 SET(medpartitionercpp_DEFINITIONS "${medpartitionercpp_DEFINITIONS} ${METIS_DEFINITIONS}")
96 SET(medpartitionercpp_LDFLAGS ${medpartitionercpp_LDFLAGS} ${METIS_LIBS})
97 ENDIF(MED_ENABLE_METIS)
99 SET(medpartitionercpp_HEADERS_HXX ${medpartitionercpp_HEADERS_HXX} MEDPARTITIONER_ScotchGraph.hxx)
100 SET(medpartitionercpp_SOURCES ${medpartitionercpp_SOURCES} MEDPARTITIONER_ScotchGraph.cxx)
101 SET(medpartitionercpp_DEFINITIONS "${medpartitionercpp_DEFINITIONS} ${SCOTCH_DEFINITIONS}")
102 SET(medpartitionercpp_LDFLAGS ${medpartitionercpp_LDFLAGS} ${SCOTCH_LIBS})
103 ENDIF(MED_ENABLE_SCOTCH)
106 SET(medpartitionercpp_SOURCES ${medpartitionercpp_SOURCES}
107 MEDPARTITIONER_UtilsPara.cxx
108 MEDPARTITIONER_JointFinder.cxx
112 ADD_LIBRARY(medpartitionercpp SHARED ${medpartitionercpp_SOURCES})
113 SET_TARGET_PROPERTIES(medpartitionercpp PROPERTIES COMPILE_FLAGS "${PLATFORM_DEFINITIONS} ${medpartitionercpp_DEFINITIONS}")
114 TARGET_LINK_LIBRARIES(medpartitionercpp ${medpartitionercpp_LDFLAGS} ${PLATFORM_LIBS} ${PTHREAD_LIBS})
115 INSTALL(TARGETS medpartitionercpp DESTINATION ${MED_salomelib_LIBS})
117 IF(MED_ENABLE_PARMETIS)
118 ADD_EXECUTABLE(medpartitioner_para medpartitioner_para.cxx)
119 SET_TARGET_PROPERTIES(medpartitioner_para PROPERTIES COMPILE_FLAGS "${medpartitionercpp_DEFINITIONS}")
120 TARGET_LINK_LIBRARIES(medpartitioner_para medpartitionercpp ${medpartitionercpp_LDFLAGS})
121 INSTALL(TARGETS medpartitioner_para DESTINATION ${MED_salomebin_BINS})
122 ENDIF(MED_ENABLE_PARMETIS)
124 ADD_EXECUTABLE(medpartitioner medpartitioner.cxx)
125 SET_TARGET_PROPERTIES(medpartitioner PROPERTIES COMPILE_FLAGS "${PLATFORM_DEFINITIONS} ${medpartitionercpp_DEFINITIONS}")
126 TARGET_LINK_LIBRARIES(medpartitioner medpartitionercpp ${medpartitionercpp_LDFLAGS})
127 INSTALL(TARGETS medpartitioner DESTINATION ${MED_salomebin_BINS})
129 INSTALL(FILES ${medpartitionercpp_HEADERS_HXX} DESTINATION ${MED_salomeinclude_HEADERS})