Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add build system support to distinguish ITAPS components

  • Loading branch information...
commit 5456e73cb6ecdd808ab929795c0c6d0fa03bbdea 1 parent b61dee1
@jedbrown authored
Showing with 18 additions and 2 deletions.
  1. +15 −1 CMakeLists.txt
  2. +1 −1  cmake-modules
  3. +2 −0  dohpconfig.h.in
View
16 CMakeLists.txt
@@ -8,6 +8,12 @@ find_package (PETSc REQUIRED)
find_package (ITAPS COMPONENTS MESH GEOM REL)
find_package (GDAL)
find_package (HDF5)
+if (ITAPS_REL_FOUND)
+ set (dHAVE_ITAPS_REL TRUE)
+endif ()
+if (ITAPS_GEOM_FOUND)
+ set (dHAVE_ITAPS_GEOM TRUE)
+endif ()
if (GDAL_FOUND)
set (dHAVE_GDAL TRUE)
endif ()
@@ -76,7 +82,15 @@ add_custom_target (etags
include_directories ("${Dohp_SOURCE_DIR}/include" "${Dohp_BINARY_DIR}/include" ${PETSC_INCLUDES} ${ITAPS_INCLUDES} ${HDF5_INCLUDE_DIRS})
add_definitions (${PETSC_DEFINITIONS})
-set (Dohp_DEPENDENT_LIBRARIES "${ITAPS_REL_LIBRARIES}" "${ITAPS_MESH_LIBRARIES}" "${ITAPS_GEOM_LIBRARIES}" "${PETSC_LIBRARIES}" "${HDF5_LIBRARIES}")
+set (Dohp_ITAPS_LIBRARIES)
+if (dHAVE_ITAPS_REL)
+ list (APPEND Dohp_ITAPS_LIBRARIES "${ITAPS_REL_LIBRARIES}")
+endif ()
+if (dHAVE_ITAPS_GEOM)
+ list (APPEND Dohp_ITAPS_LIBRARIES "${ITAPS_GEOM_LIBRARIES}")
+endif ()
+list (APPEND Dohp_ITAPS_LIBRARIES "${ITAPS_MESH_LIBRARIES}")
+set (Dohp_DEPENDENT_LIBRARIES "${Dohp_ITAPS_LIBRARIES}" "${PETSC_LIBRARIES}" "${HDF5_LIBRARIES}")
set (Dohp_LIBRARIES dohp ${Dohp_DEPENDENT_LIBRARIES})
set (CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${Dohp_BINARY_DIR}/lib CACHE PATH "Output directory for Dohp archives")
2  cmake-modules
@@ -1 +1 @@
-Subproject commit c6fcaeedbbb8078f0a926325c37a788ab8f32915
+Subproject commit 38c7494e37ab139880f6f8a4a5231105494ce86c
View
2  dohpconfig.h.in
@@ -7,5 +7,7 @@
#cmakedefine dUSE_VALGRIND
#cmakedefine dHAVE_PRAGMA_GCC
#cmakedefine dHAVE_GDAL
+#cmakedefine dHAVE_ITAPS_GEOM
+#cmakedefine dHAVE_ITAPS_REL
#endif
Please sign in to comment.
Something went wrong with that request. Please try again.