ADD_SUBDIRECTORY(MEDCoupling)
IF(MEDCOUPLING_ENABLE_PYTHON)
ADD_SUBDIRECTORY(MEDCoupling_Swig)
+ ADD_SUBDIRECTORY(PyWrapping)
ENDIF(MEDCOUPLING_ENABLE_PYTHON)
IF(NOT MEDCOUPLING_MICROMED)
${PROJECT_BINARY_DIR}/doc
)
+
+IF(NOT MEDCOUPLING_MICROMED)
+ LIST(APPEND SWIG_MODULE_medcoupling_EXTRA_FLAGS -DWITH_MED_FILE)
+ENDIF(NOT MEDCOUPLING_MICROMED)
+
SWIG_ADD_MODULE(medcoupling python medcoupling.i)
-SWIG_LINK_LIBRARIES(medcoupling ${PYTHON_LIBRARIES} ${PLATFORM_LIBS} medloader medcouplingcpp)
\ No newline at end of file
+SWIG_LINK_LIBRARIES(medcoupling ${PYTHON_LIBRARIES} ${PLATFORM_LIBS} medloader medcouplingremapper)
+SWIG_CHECK_GENERATION(medcoupling)
+IF(WIN32)
+ SET_TARGET_PROPERTIES(_medcoupling PROPERTIES DEBUG_OUTPUT_NAME _medcoupling_d)
+ENDIF(WIN32)
+
+INSTALL(TARGETS _medcoupling DESTINATION ${MEDCOUPLING_INSTALL_PYTHON})
+INSTALL(FILES medcoupling.i DESTINATION ${MEDCOUPLING_INSTALL_HEADERS})
+SALOME_INSTALL_SCRIPTS(${CMAKE_CURRENT_BINARY_DIR}/medcoupling.py ${MEDCOUPLING_INSTALL_PYTHON})
%include "MEDCouplingRemapperImpl.i"
- // TO DO ifdef
+#ifdef WITH_MED_FILE
%include "MEDLoaderImpl.i"
- // TO DO endif
+#endif
%pythoncode %{
def MEDCouplingDataArrayDoubleIadd(self,*args):
%include "MEDCouplingFinalize.i"
+#ifdef WITH_MED_FILE
%include "MEDLoaderFinalize.i"
+#endif