[vtk6] 01/03: Update gcc tests patch Closes: #853703

Gert Wollny gewo at moszumanska.debian.org
Tue Jul 11 01:06:11 UTC 2017


This is an automated email from the git hooks/post-receive script.

gewo pushed a commit to branch master
in repository vtk6.

commit 1789b1b038122d760bb620e2269fdba490e7e7c4
Author: Gert Wollny <gewo at debian.org>
Date:   Mon Jul 10 18:59:43 2017 +0000

    Update gcc tests patch Closes: #853703
---
 debian/patches/104_fix_gcc_version_6.patch | 86 +++++++++++++++++++++---------
 1 file changed, 61 insertions(+), 25 deletions(-)

diff --git a/debian/patches/104_fix_gcc_version_6.patch b/debian/patches/104_fix_gcc_version_6.patch
index db8d70e..46bba97 100644
--- a/debian/patches/104_fix_gcc_version_6.patch
+++ b/debian/patches/104_fix_gcc_version_6.patch
@@ -1,30 +1,66 @@
-Description: Fix to be able to compile with gcc-6
-Author: Gerardo Malazdrewicz <gerardo at malazdrewicz.com.ar>
+Description: Remove gcc version checks, since we know on Debian
+ the compiler is new enough
+Author: Gert Wollny <gewo at debian.org>
 Bug: https://bugs.debian.org/812296
+Bug: https://bugs.debian.org/853703
 
-Index: VTK-6.3.0/CMake/GenerateExportHeader.cmake
-===================================================================
---- VTK-6.3.0.orig/CMake/GenerateExportHeader.cmake
-+++ VTK-6.3.0/CMake/GenerateExportHeader.cmake
-@@ -166,7 +166,7 @@ macro(_test_compiler_hidden_visibility)
-     execute_process(COMMAND ${CMAKE_C_COMPILER} ARGS --version
-       OUTPUT_VARIABLE _gcc_version_info
-       ERROR_VARIABLE _gcc_version_info)
+--- a/CMake/GenerateExportHeader.cmake
++++ b/CMake/GenerateExportHeader.cmake
+@@ -163,21 +163,7 @@
+ macro(_test_compiler_hidden_visibility)
+ 
+   if(CMAKE_COMPILER_IS_GNUCXX)
+-    execute_process(COMMAND ${CMAKE_C_COMPILER} ARGS --version
+-      OUTPUT_VARIABLE _gcc_version_info
+-      ERROR_VARIABLE _gcc_version_info)
 -    string(REGEX MATCH "[345]\\.[0-9]\\.[0-9]*"
-+    string(REGEX MATCH "[3456]\\.[0-9]\\.[0-9]*"
-       _gcc_version "${_gcc_version_info}")
-     # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the
-     # patch level, handle this here:
-Index: VTK-6.3.0/CMake/vtkCompilerExtras.cmake
-===================================================================
---- VTK-6.3.0.orig/CMake/vtkCompilerExtras.cmake
-+++ VTK-6.3.0/CMake/vtkCompilerExtras.cmake
-@@ -32,7 +32,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
-     OUTPUT_VARIABLE _gcc_version_info
-     ERROR_VARIABLE _gcc_version_info)
+-      _gcc_version "${_gcc_version_info}")
+-    # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the
+-    # patch level, handle this here:
+-    if(NOT _gcc_version)
+-      string(REGEX REPLACE ".*\\(GCC\\).*([34]\\.[0-9]).*" "\\1.0"
+-        _gcc_version "${_gcc_version_info}")
+-    endif()
+-
+-    if(${_gcc_version} VERSION_LESS "4.2")
+-      set(GCC_TOO_OLD TRUE)
+-    endif()
++      set(GCC_TOO_OLD FALSE)
+   endif()
+ 
+   if(CMAKE_CXX_COMPILER_ID MATCHES "Intel")
+--- a/CMake/vtkCompilerExtras.cmake
++++ b/CMake/vtkCompilerExtras.cmake
+@@ -27,31 +27,7 @@
+       "${VTK_EXTRA_SHARED_LINKER_FLAGS} -Wl,--no-undefined -lc ${CMAKE_SHARED_LINKER_FLAGS}")
+   endif()
  
+-  # Now check if we can use visibility to selectively export symbols
+-  execute_process(COMMAND ${CMAKE_C_COMPILER} ARGS --version
+-    OUTPUT_VARIABLE _gcc_version_info
+-    ERROR_VARIABLE _gcc_version_info)
+-
 -  string (REGEX MATCH "[345]\\.[0-9]\\.[0-9]*"
-+  string (REGEX MATCH "[3456]\\.[0-9]\\.[0-9]*"
-     _gcc_version "${_gcc_version_info}")
-   if(NOT _gcc_version)
-     string (REGEX REPLACE ".*\\(GCC\\).*([34]\\.[0-9]).*" "\\1.0"
+-    _gcc_version "${_gcc_version_info}")
+-  if(NOT _gcc_version)
+-    string (REGEX REPLACE ".*\\(GCC\\).*([34]\\.[0-9]).*" "\\1.0"
+-      _gcc_version "${_gcc_version_info}")
+-  endif()
+-
+-  # GCC visibility support, on by default and in testing.
+-  check_cxx_compiler_flag(-fvisibility=hidden HAVE_GCC_VISIBILITY)
+-  option(VTK_USE_GCC_VISIBILITY "Use GCC visibility support if available." OFF)
+-  mark_as_advanced(VTK_USE_GCC_VISIBILITY)
+-
+-  if(${_gcc_version} VERSION_GREATER 4.2.0 AND BUILD_SHARED_LIBS
+-    AND HAVE_GCC_VISIBILITY AND VTK_USE_GCC_VISIBILITY
+-    AND NOT MINGW AND NOT CYGWIN)
+-    # Should only be set if GCC is newer than 4.2.0
+-    set(VTK_ABI_CXX_FLAGS "-fvisibility=hidden -fvisibility-inlines-hidden")
+-  else()
+-    set(VTK_ABI_CXX_FLAGS "")
+-  endif()
++  set(VTK_ABI_CXX_FLAGS "-fvisibility=hidden -fvisibility-inlines-hidden")
+ 
+   # Set up the debug CXX_FLAGS for extra warnings
+   option(VTK_EXTRA_COMPILER_WARNINGS

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/vtk6.git



More information about the debian-science-commits mailing list