1 # Copyright (C) 2007-2012 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
20 FIND_PACKAGE(SWIG REQUIRED)
21 INCLUDE(${SWIG_USE_FILE})
23 SET_SOURCE_FILES_PROPERTIES(libMEDSPLITTER_Swig.i PROPERTIES CPLUSPLUS ON)
24 SET_SOURCE_FILES_PROPERTIES(libMEDSPLITTER_Swig.i PROPERTIES SWIG_DEFINITIONS "-shadow")
27 ${PYTHON_INCLUDE_DIRS}
31 ${CMAKE_CURRENT_SOURCE_DIR}
32 ${CMAKE_CURRENT_SOURCE_DIR}/../MEDSPLITTER
33 ${CMAKE_CURRENT_SOURCE_DIR}/../MEDMEM
34 ${CMAKE_CURRENT_SOURCE_DIR}/../MEDMEM_SWIG
35 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL
36 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/Bases
37 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/Geometric2D
38 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/ExprEval
39 ${CMAKE_CURRENT_SOURCE_DIR}/../INTERP_KERNEL/GaussPoints
42 SWIG_ADD_MODULE(libMEDSPLITTER_Swig python libMEDSPLITTER_Swig.i)
43 SWIG_LINK_LIBRARIES(libMEDSPLITTER_Swig ${PYTHON_LIBS} medsplittercpp)
44 SET_TARGET_PROPERTIES(_libMEDSPLITTER_Swig PROPERTIES COMPILE_FLAGS "${BOOST_DEFINITIONS} ${PLATFORM_DEFINITIONS}")
45 IF(${MACHINE} STREQUAL WINDOWS)
46 SET_TARGET_PROPERTIES(_libMEDSPLITTER_Swig PROPERTIES DEBUG_OUTPUT_NAME _libMEDSPLITTER_Swig_d)
47 ENDIF(${MACHINE} STREQUAL WINDOWS)
48 INSTALL(TARGETS _libMEDSPLITTER_Swig DESTINATION ${MED_salomepythondir})
49 INSTALL(FILES libMEDSPLITTER_Swig.i DESTINATION ${MED_salomeinclude_HEADERS})
50 INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/libMEDSPLITTER_Swig.py DESTINATION ${MED_salomepythondir})
51 INSTALL(FILES MEDSPLITTER.py test_MEDSPLITTER.py DESTINATION ${MED_salomescript_DATA})