CMakeLists.txt 829 Bytes
Newer Older
Ken Leiter (Civ's avatar
Ken Leiter (Civ committed
1 2 3 4 5 6 7 8 9
project(Xdmf2)
cmake_minimum_required(VERSION 2.6)

include_directories(${CMAKE_CURRENT_SOURCE_DIR})

set(BUILD_SHARED_LIBS true)

find_package(Boost REQUIRED)
if(Boost_FOUND)
10 11
	include_directories(${Boost_INCLUDE_DIRS})
	message(${Boost_INCLUDE_DIRS})
Ken Leiter (Civ's avatar
Ken Leiter (Civ committed
12 13 14 15
endif(Boost_FOUND)

find_package(PythonLibs REQUIRED)
if(PYTHONLIBS_FOUND)
16
	include_directories(${PYTHON_INCLUDE_DIRS})
Ken Leiter (Civ's avatar
Ken Leiter (Civ committed
17 18 19
endif(PYTHONLIBS_FOUND)

set(XdmfSources
20 21 22 23
	XdmfGeometry
	XdmfGrid
	XdmfObject
	XdmfTopology
Ken Leiter (Civ's avatar
Ken Leiter (Civ committed
24 25 26 27
)

add_library(Xdmf ${XdmfSources})

28 29 30 31 32 33 34 35 36 37 38
#add_library(_Xdmf MODULE XdmfPython)
#set_target_properties(_Xdmf PROPERTIES PREFIX "")
#target_link_libraries(_Xdmf Xdmf)
#configure_file(Xdmf.py Xdmf.py COPYONLY)

option(BUILD_TESTING OFF)
if(BUILD_TESTING)
	add_subdirectory(tests)
	add_executable(XdmfTest test.cpp)
	target_link_libraries(XdmfTest Xdmf)
endif(BUILD_TESTING)