Blame SOURCES/0041-curl-7.29.0-b2dcf034.patch

105fd7
From ac2121bf962ecc054dd103ccd42a93912051672e Mon Sep 17 00:00:00 2001
105fd7
From: Kamil Dudka <kdudka@redhat.com>
105fd7
Date: Tue, 21 Jun 2016 12:40:26 +0200
105fd7
Subject: [PATCH] curl-compilers.m4: improve detection of GCC's -fvisibility=
105fd7
 flag
105fd7
105fd7
Some builds of GCC produce output on both stdout and stderr when --help
105fd7
--verbose is used.  The 2>&1 redirection caused them to be arbitrarily
105fd7
interleaved with each other because of stream buffering.  Consequently,
105fd7
grep failed to match the fvisibility= string in the mixed output, even
105fd7
though the string was present in GCC's standard output.
105fd7
105fd7
This led to silently disabling symbol hiding in some builds of curl.
105fd7
105fd7
Upstream-commit: b2dcf0347f1ee5041cccd64632bb8dd7ccbbae91
105fd7
Signed-off-by: Kamil Dudka <kdudka@redhat.com>
105fd7
---
105fd7
 configure            | 2 +-
105fd7
 m4/curl-compilers.m4 | 4 ++--
105fd7
 2 files changed, 3 insertions(+), 3 deletions(-)
105fd7
105fd7
diff --git a/configure b/configure
105fd7
index 4797e02..fc260ee 100755
105fd7
--- a/configure
105fd7
+++ b/configure
105fd7
@@ -17636,7 +17636,7 @@ $as_echo_n "checking if compiler supports hiding library internal symbols... " >
105fd7
       ;;
105fd7
     GNU_C)
105fd7
             if test "$compiler_num" -ge "304"; then
105fd7
-        if $CC --help --verbose 2>&1 | grep fvisibility= > /dev/null ; then
105fd7
+        if $CC --help --verbose 2>/dev/null | grep fvisibility= >/dev/null ; then
105fd7
           tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
105fd7
           tmp_CFLAGS="-fvisibility=hidden"
105fd7
           supports_symbol_hiding="yes"
105fd7
diff --git a/m4/curl-compilers.m4 b/m4/curl-compilers.m4
105fd7
index ca064dd..77371de 100644
105fd7
--- a/m4/curl-compilers.m4
105fd7
+++ b/m4/curl-compilers.m4
105fd7
@@ -21,7 +21,7 @@
105fd7
 #***************************************************************************
105fd7
 
105fd7
 # File version for 'aclocal' use. Keep it a single number.
105fd7
-# serial 65
105fd7
+# serial 66
105fd7
 
105fd7
 
105fd7
 dnl CURL_CHECK_COMPILER
105fd7
@@ -1391,7 +1391,7 @@ AC_DEFUN([CURL_CHECK_COMPILER_SYMBOL_HIDING], [
105fd7
     GNU_C)
105fd7
       dnl Only gcc 3.4 or later
105fd7
       if test "$compiler_num" -ge "304"; then
105fd7
-        if $CC --help --verbose 2>&1 | grep fvisibility= > /dev/null ; then
105fd7
+        if $CC --help --verbose 2>/dev/null | grep fvisibility= >/dev/null ; then
105fd7
           tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
105fd7
           tmp_CFLAGS="-fvisibility=hidden"
105fd7
           supports_symbol_hiding="yes"
105fd7
-- 
105fd7
2.5.5
105fd7