diff options
author | Erik Schnetter <schnetter@gmail.com> | 2016-09-20 05:15:37 -0400 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2016-09-20 02:15:37 -0700 |
commit | 70424b511eeed84f875393b2e8fee9c47993004d (patch) | |
tree | 6cdeb3f5e0f7fae591d087e2b744980bd93545c0 | |
parent | 2a558e9d7adeaf4ee94120654b4f558262919333 (diff) | |
download | spack-70424b511eeed84f875393b2e8fee9c47993004d.tar.gz spack-70424b511eeed84f875393b2e8fee9c47993004d.tar.bz2 spack-70424b511eeed84f875393b2e8fee9c47993004d.tar.xz spack-70424b511eeed84f875393b2e8fee9c47993004d.zip |
Work around cmake problems in VTK (#1761)
The cmake scripts can't handle the semicolons in gcc's version output. Filter them out before detecting the version.
-rw-r--r-- | var/spack/repos/builtin/packages/vtk/gcc.patch | 21 | ||||
-rw-r--r-- | var/spack/repos/builtin/packages/vtk/package.py | 2 |
2 files changed, 23 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/vtk/gcc.patch b/var/spack/repos/builtin/packages/vtk/gcc.patch new file mode 100644 index 0000000000..37ba5ac45a --- /dev/null +++ b/var/spack/repos/builtin/packages/vtk/gcc.patch @@ -0,0 +1,21 @@ +--- old/CMake/vtkCompilerExtras.cmake ++++ new/CMake/vtkCompilerExtras.cmake +@@ -26,6 +26,8 @@ + execute_process(COMMAND ${CMAKE_C_COMPILER} --version + OUTPUT_VARIABLE _gcc_version_info + ERROR_VARIABLE _gcc_version_info) ++ ++ string (REPLACE ";" "" _gcc_version_info "${_gcc_version_info}") + + string (REGEX MATCH "[345]\\.[0-9]\\.[0-9]" + _gcc_version "${_gcc_version_info}") +--- old/CMake/GenerateExportHeader.cmake ++++ new/CMake/GenerateExportHeader.cmake +@@ -166,6 +166,7 @@ + execute_process(COMMAND ${CMAKE_C_COMPILER} --version + OUTPUT_VARIABLE _gcc_version_info + ERROR_VARIABLE _gcc_version_info) ++ string (REPLACE ";" "" _gcc_version_info "${_gcc_version_info}") + string(REGEX MATCH "[345]\\.[0-9]\\.[0-9]" + _gcc_version "${_gcc_version_info}") + # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the diff --git a/var/spack/repos/builtin/packages/vtk/package.py b/var/spack/repos/builtin/packages/vtk/package.py index 087c0e93eb..f7015904b0 100644 --- a/var/spack/repos/builtin/packages/vtk/package.py +++ b/var/spack/repos/builtin/packages/vtk/package.py @@ -40,6 +40,8 @@ class Vtk(Package): version('6.1.0', '25e4dfb3bad778722dcaec80cd5dab7d') + patch("gcc.patch") + depends_on('cmake', type='build') depends_on("qt") |