summaryrefslogtreecommitdiff
path: root/sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch
diff options
context:
space:
mode:
Diffstat (limited to 'sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch')
-rw-r--r--sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch65
1 files changed, 65 insertions, 0 deletions
diff --git a/sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch b/sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch
new file mode 100644
index 000000000000..3b8a628b0384
--- /dev/null
+++ b/sci-libs/hdf5/files/hdf5-1.14.4-0003-Drop-broken-Werror-stripping.patch
@@ -0,0 +1,65 @@
+From 014f4857dc0e5883cb07393d5875412806855d28 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Sun, 17 Dec 2023 09:27:18 +0000
+Subject: [PATCH 3/3] Drop broken -Werror stripping
+
+The stripping is broken and mangles -Werror=x -> -x [0].
+
+[0] https://github.com/HDFGroup/hdf5/commit/41526f68f3482f2b3a7aa581288bc86e9c6dcb43#r100076265
+
+Bug: https://bugs.gentoo.org/917448
+Signed-off-by: Sam James <sam@gentoo.org>
+---
+ configure.ac | 36 ------------------------------------
+ 1 file changed, 36 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index fc44a39..2117303 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -193,42 +193,6 @@ saved_user_JAVAFLAGS="$JAVAFLAGS"
+ saved_user_LDFLAGS="$LDFLAGS"
+ saved_user_CPPFLAGS="$CPPFLAGS"
+
+-## Strip out -Werror from CFLAGS since that can cause checks to fail when
+-## compiling test programs fails due to warnings
+-##
+-## Regex:
+-##
+-## -Werror Literal -Werror
+-## \( Start optional capturing group
+-## = Literal equals sign
+-## [^[:space:]] Non-space characters
+-## \+ 1 or more of the above
+-## \) End optional capturing group
+-## \? 0 or 1 capturing group matches
+-##
+-## Note that the outer pair of '[]' ends up getting removed
+-WERROR_SED='s/-Werror\(=[[^[:space:]]]\+\)\?//g'
+-CFLAGS_SED="`echo $CFLAGS | sed -e $WERROR_SED`"
+-if test $? -eq 0; then
+- CFLAGS="$CFLAGS_SED"
+-fi
+-CXXFLAGS_SED="`echo $CXXFLAGS | sed -e $WERROR_SED`"
+-if test $? -eq 0; then
+- CXXFLAGS="$CXXFLAGS_SED"
+-fi
+-FCFLAGS_SED="`echo $FCFLAGS | sed -e $WERROR_SED`"
+-if test $? -eq 0; then
+- FCFLAGS="$FCFLAGS_SED"
+-fi
+-JAVACFLAGS_SED="`echo $JAVACFLAGS | sed -e $WERROR_SED`"
+-if test $? -eq 0; then
+- JAVACFLAGS="$JAVACFLAGS_SED"
+-fi
+-CPPFLAGS_SED="`echo $CPPFLAGS | sed -e $WERROR_SED`"
+-if test $? -eq 0; then
+- CPPFLAGS="$CPPFLAGS_SED"
+-fi
+-
+ ## Support F9X variable to define Fortran compiler if FC variable is
+ ## not used. This should be deprecated in the future.
+ if test "x" = "x$FC"; then
+--
+2.44.0
+