mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-10-05 01:49:02 +00:00
changed to CMake files based on Robert's feedback
This commit is contained in:
parent
ca0ce4de7b
commit
ff0b8fd0bb
@ -18,6 +18,7 @@
|
||||
# -DVTKm_INSTALL_INCLUDE_DIR=<VTKm_INSTALL_INCLUDE_DIR>
|
||||
# -DVTKm_ENABLE_RENDERING=<VTKm_ENABLE_RENDERING>
|
||||
# -DVTKm_ENABLE_LOGGING=<VTKm_ENABLE_LOGGING>
|
||||
# -DVTKm_ENABLE_HDF5_IO=<VTKm_ENABLE_HDF5_IO>
|
||||
# -P <VTKm_SOURCE_DIR>/CMake/testing/VTKMCheckSourceInInstall.cmake
|
||||
##
|
||||
|
||||
@ -39,7 +40,9 @@ endif ()
|
||||
if (NOT DEFINED VTKm_ENABLE_LOGGING)
|
||||
message(FATAL_ERROR "VTKm_ENABLE_LOGGING not defined.")
|
||||
endif ()
|
||||
|
||||
if (NOT DEFINED VTKm_ENABLE_HDF5_IO)
|
||||
message(FATAL_ERROR "VTKm_ENABLE_HDF5_IO not defined.")
|
||||
endif()
|
||||
|
||||
include(CMakeParseArguments)
|
||||
# -----------------------------------------------------------------------------
|
||||
@ -121,13 +124,6 @@ function(do_verify root_dir prefix)
|
||||
cont/StorageVirtual.hxx
|
||||
)
|
||||
|
||||
if (NOT VTKm_ENABLE_HDF5_IO)
|
||||
set(file_exceptions ${file_exceptions}
|
||||
io/ImageWriterHDF5.h
|
||||
io/ImageReaderHDF5.h
|
||||
)
|
||||
endif()
|
||||
|
||||
#by default every header in a testing directory doesn't need to be installed
|
||||
set(directory_exceptions ".*/testing" )
|
||||
# These exceptions should be based on the status of the associated
|
||||
@ -138,7 +134,12 @@ function(do_verify root_dir prefix)
|
||||
if(NOT VTKm_ENABLE_LOGGING)
|
||||
list(APPEND directory_exceptions thirdparty/loguru)
|
||||
endif()
|
||||
|
||||
if (NOT VTKm_ENABLE_HDF5_IO)
|
||||
list(APPEND file_exceptions
|
||||
io/ImageWriterHDF5.h
|
||||
io/ImageReaderHDF5.h
|
||||
)
|
||||
endif()
|
||||
#Step 2. Verify the installed files match what headers are listed in each
|
||||
# source directory
|
||||
verify_install_per_dir("${VTKm_SOURCE_DIR}/vtkm"
|
||||
|
@ -17,6 +17,7 @@ function(vtkm_test_install )
|
||||
"-DVTKm_INSTALL_INCLUDE_DIR=${VTKm_INSTALL_INCLUDE_DIR}"
|
||||
"-DVTKm_ENABLE_RENDERING=${VTKm_ENABLE_RENDERING}"
|
||||
"-DVTKm_ENABLE_LOGGING=${VTKm_ENABLE_LOGGING}"
|
||||
"-DVTKm_ENABLE_HDF5_IO=${VTKm_ENABLE_HDF5_IO}"
|
||||
)
|
||||
|
||||
#By having this as separate tests using fixtures, it will allow us in
|
||||
|
@ -95,9 +95,6 @@ vtkm_option(VTKm_USE_64BIT_IDS "Use 64-bit indices." ON)
|
||||
vtkm_option(VTKm_ENABLE_HDF5_IO "Enable HDF5 support" OFF)
|
||||
if (VTKm_ENABLE_HDF5_IO)
|
||||
find_package(HDF5 REQUIRED COMPONENTS HL)
|
||||
if (HDF5_FOUND)
|
||||
include_directories(${HDF5_INCLUDE_DIR})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# VTK-m will turn on logging by default, but will set the default
|
||||
|
@ -91,8 +91,10 @@ vtkm_library(
|
||||
|
||||
target_link_libraries(vtkm_io PUBLIC vtkm_cont PRIVATE vtkm_lodepng)
|
||||
if (VTKm_ENABLE_HDF5_IO)
|
||||
target_include_directories(vtkm_io PRIVATE $<BUILD_INTERFACE:${HDF5_INCLUDE_DIR}>)
|
||||
target_link_libraries(vtkm_io PRIVATE ${HDF5_HL_LIBRARIES})
|
||||
endif()
|
||||
|
||||
add_subdirectory(internal)
|
||||
add_subdirectory(reader)
|
||||
add_subdirectory(writer)
|
||||
|
Loading…
Reference in New Issue
Block a user