Commit aff6b1fa authored by Andrew J. Burns (Cont's avatar Andrew J. Burns (Cont

Fixes to python wrappers for python wrappers when TIFF isn't available

parent d1392477
......@@ -160,6 +160,9 @@ if(XDMF_WRAP_PYTHON)
set(CMAKE_SWIG_FLAGS ${CMAKE_SWIG_FLAGS} -DXDMF_BUILD_DSM_THREADS)
endif ()
endif ()
if (TIFF_FOUND)
set(CMAKE_SWIG_FLAGS ${CMAKE_SWIG_FLAGS} -DXDMF_BUILD_TIFF)
endif ()
set_source_files_properties(${python_name}.i PROPERTIES CPLUSPLUS ON)
set(swig_extra_generated_files "")
swig_add_module(${python_name}Python python ${python_name}.i)
......
......@@ -3,6 +3,7 @@ XdmfCorePython.cpp:
swig -v -c++ -python -o XdmfCorePython.cpp XdmfCore.i
*/
#ifdef XDMF_BUILD_TIFF
%module XdmfCore
%{
......@@ -33,6 +34,38 @@ swig -v -c++ -python -o XdmfCorePython.cpp XdmfCore.i
#include <ProjectVersion.hpp>
%}
#else
%module XdmfCore
%{
#include <XdmfArray.hpp>
#include <XdmfArrayReference.hpp>
#include <XdmfArrayType.hpp>
#include <XdmfCore.hpp>
#include <XdmfCoreItemFactory.hpp>
#include <XdmfCoreReader.hpp>
#include <XdmfError.hpp>
#include <XdmfFunction.hpp>
#include <XdmfHeavyDataController.hpp>
#include <XdmfHeavyDataWriter.hpp>
#include <XdmfHDF5Controller.hpp>
#include <XdmfHDF5Writer.hpp>
#include <XdmfInformation.hpp>
#include <XdmfItem.hpp>
#include <XdmfItemProperty.hpp>
#include <XdmfSharedPtr.hpp>
#include <XdmfSparseMatrix.hpp>
#include <XdmfSubset.hpp>
#include <XdmfSystemUtils.hpp>
#include <XdmfVersion.hpp>
#include <XdmfVisitor.hpp>
#include <XdmfWriter.hpp>
#include <ProjectVersion.hpp>
%}
#endif
// Ignoring C Wrappers
// XdmfItem
......@@ -1263,7 +1296,9 @@ swig -v -c++ -python -o XdmfCorePython.cpp XdmfCore.i
%shared_ptr(XdmfItemProperty)
%shared_ptr(XdmfSparseMatrix)
%shared_ptr(XdmfSubset)
%shared_ptr(XdmfTIFFController)
#ifdef XDMF_BUILD_TIFF
%shared_ptr(XdmfTIFFController)
#endif
%shared_ptr(XdmfVisitor)
%shared_ptr(XdmfWriter)
......@@ -1292,7 +1327,9 @@ swig -v -c++ -python -o XdmfCorePython.cpp XdmfCore.i
%include XdmfInformation.hpp
%include XdmfHDF5Controller.hpp
%include XdmfHDF5Writer.hpp
%include XdmfTIFFController.hpp
#ifdef XDMF_BUILD_TIFF
%include XdmfTIFFController.hpp
#endif
%include XdmfWriter.hpp
%include CMake/VersionSuite/ProjectVersion.hpp
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment