Clean up install/VTK issues in VTKmConfig.cmake.
This commit is contained in:
parent
30f4151bf8
commit
c0a7315906
@ -50,16 +50,12 @@ if(CMAKE_CURRENT_LIST_DIR STREQUAL "@VTKm_BINARY_DIR@/@VTKm_INSTALL_CONFIG_DIR@"
|
||||
set(VTKm_PACKAGE_IN_BUILD TRUE)
|
||||
endif()
|
||||
|
||||
# The VTKm include file directories.
|
||||
set_and_check(VTKm_INCLUDE_DIRS "@PACKAGE_VTKm_INSTALL_INCLUDE_DIR@")
|
||||
if(VTKm_PACKAGE_IN_BUILD)
|
||||
set(VTKm_INCLUDE_DIRS ${VTKm_INCLUDE_DIRS} "@VTKm_SOURCE_DIR@")
|
||||
endif()
|
||||
|
||||
if(NOT VTKm_PACKAGE_IN_BUILD)
|
||||
set_and_check(VTKm_CMAKE_MODULE_PATH "@PACKAGE_VTKm_INSTALL_CMAKE_MODULE_DIR@")
|
||||
else()
|
||||
set_and_check(VTKm_CMAKE_MODULE_PATH "@VTKm_SOURCE_DIR@/CMake")
|
||||
set_and_check(VTKm_INCLUDE_DIRS ${VTKm_INCLUDE_DIRS} "@VTKm_SOURCE_DIR@")
|
||||
else()
|
||||
set_and_check(VTKm_CMAKE_MODULE_PATH "@PACKAGE_VTKm_INSTALL_CMAKE_MODULE_DIR@")
|
||||
set_and_check(VTKm_INCLUDE_DIRS "@PACKAGE_VTKm_INSTALL_INCLUDE_DIR@")
|
||||
endif()
|
||||
|
||||
set(VTKm_BUILD_SHARED_LIBS "@BUILD_SHARED_LIBS@")
|
||||
@ -70,7 +66,7 @@ set(VTKm_ENABLE_RENDERING "@VTKm_ENABLE_RENDERING@")
|
||||
|
||||
# Load the library exports, but only if not compiling VTK-m itself
|
||||
set_and_check(VTKm_CONFIG_DIR "@PACKAGE_VTKm_INSTALL_CONFIG_DIR@")
|
||||
if(NOT "${CMAKE_BINARY_DIR}" STREQUAL "@VTKm_BINARY_DIR@")
|
||||
if(NOT "${CMAKE_BINARY_DIR}" STREQUAL "@CMAKE_BINARY_DIR@")
|
||||
include(${VTKm_CONFIG_DIR}/VTKmTargets.cmake)
|
||||
endif()
|
||||
|
||||
|
@ -327,7 +327,7 @@ install(
|
||||
|
||||
# Create and install exports for external projects
|
||||
export(EXPORT ${VTKm_EXPORT_NAME}
|
||||
FILE ${CMAKE_BINARY_DIR}/${VTKm_INSTALL_CONFIG_DIR}/VTKmTargets.cmake
|
||||
FILE ${VTKm_BINARY_DIR}/${VTKm_INSTALL_CONFIG_DIR}/VTKmTargets.cmake
|
||||
)
|
||||
install(EXPORT ${VTKm_EXPORT_NAME}
|
||||
DESTINATION ${VTKm_INSTALL_CONFIG_DIR}
|
||||
|
Loading…
Reference in New Issue
Block a user