Skip to content

Commit

Permalink
BUG: Configuration errors visible on Windows
Browse files Browse the repository at this point in the history
* Tries to link against PUBLIC.lib when PUBLIC is just a CMake keyword.
* Keeps VTK configuration artifacts 'debug' and 'optimized' which are
interpreted as library names and lead to linkage errors.
  • Loading branch information
Francois Budin committed Mar 18, 2019
1 parent 0de0b75 commit abd8318
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,14 @@ else()
${_wrap_module}
)
endif()
# An artifact of the VTKPythonPackage build configuration
# Artifacts of the VTKPythonPackage build configuration
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
"libpython-not-needed-symbols")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
"optimized")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
"debug")


# The VTK DICOMParser and vtkmetaio includes conflict with the ITK
# versions. Here we remove them from the include directories.
Expand Down Expand Up @@ -137,9 +142,13 @@ else()
set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS \${ITKVtkGlue_VTK_DEFINITIONS})
# An artifact of the VTKPythonPackage build configuration
# Artifacts of the VTKPythonPackage build configuration
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"libpython-not-needed-symbols\")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"optimized\")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"debug\")
endif()
")
set(ITKVtkGlue_EXPORT_CODE_BUILD "
Expand Down Expand Up @@ -186,9 +195,13 @@ if(NOT ITK_BINARY_DIR)
set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS \${ITKVtkGlue_VTK_DEFINITIONS})
endif()
# An artifact of the VTKPythonPackage build configuration
# Artifacts of the VTKPythonPackage build configuration
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"libpython-not-needed-symbols\")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"optimized\")
list(FILTER ITKVtkGlue_VTK_LIBRARIES EXCLUDE REGEX
\"debug\")
endif()
")

Expand Down

0 comments on commit abd8318

Please sign in to comment.