NIFTYREGConfig.cmake: find_package is case sensitive
Variables in NiftyRegConfig.cmake are written as `NIFTYREG`, despite the filename being written as `NiftyReg`. This causes problems for case-sensitive systems (e.g., linux) using Cmake's `find_package`.
Simplest solution is just to change the filename to `NIFTYREGConfig.cmake`, such that we needn't change all the variable names.
@@ -18,8 +18,8 @@ set (NIFTYREG_INCLUDE_DIRS "include")
string(SUBSTRING "${NIFTYREG_LIBRARIES}" 1 -1 NIFTYREG_LIBRARIES)
CONFIGURE_PACKAGE_CONFIG_FILE(
- "NiftyRegConfig.cmake.in"
- "${CMAKE_CURRENT_BINARY_DIR}/NiftyRegConfig.cmake"
+ "NIFTYREGConfig.cmake.in"
+ "${CMAKE_CURRENT_BINARY_DIR}/NIFTYREGConfig.cmake"
INSTALL_DESTINATION "${ConfigPackageLocation}"
PATH_VARS NIFTYREG_INCLUDE_DIRS
)
@@ -27,8 +27,8 @@ CONFIGURE_PACKAGE_CONFIG_FILE(
# install NiftyReg components
install(
FILES
- "${CMAKE_CURRENT_BINARY_DIR}/NiftyRegConfig.cmake"
- "${CMAKE_CURRENT_BINARY_DIR}/NiftyRegConfigVersion.cmake"
+ "${CMAKE_CURRENT_BINARY_DIR}/NIFTYREGConfig.cmake"
+ "${CMAKE_CURRENT_BINARY_DIR}/NIFTYREGConfigVersion.cmake"
DESTINATION "${ConfigPackageLocation}"
)
