Skip to content

Commit 1ec96c9

Browse files
committed
patch 8.0.1156: trouble from removing one -W argument from Perl CFLAGS
Problem: Removing one -W argument from Perl CFLAGS may cause trouble. Solution: Remove all -W flags. (Christian Brabandt)
1 parent d1bc96c commit 1ec96c9

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

src/auto/configure

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5717,10 +5717,12 @@ $as_echo "OK" >&6; }
57175717
fi
57185718
done
57195719

5720-
perlcppflags=`$vi_cv_path_perl -Mlib=$srcdir -MExtUtils::Embed \
5720+
perlcppflags=`$vi_cv_path_perl -Mlib=$srcdir -MExtUtils::Embed \
57215721
-e 'ccflags;perl_inc;print"\n"' | sed -e 's/-fno[^ ]*//' \
57225722
-e 's/-fdebug-prefix-map[^ ]*//g' \
5723-
-e 's/\(-Wp,\)\?-D_FORTIFY_SOURCE=.//g'`
5723+
-e 's/-pipe //' \
5724+
-e 's/-W[^ ]*//g' \
5725+
-e 's/-D_FORTIFY_SOURCE=.//g'`
57245726
perllibs=`cd $srcdir; $vi_cv_path_perl -MExtUtils::Embed -e 'ldopts' | \
57255727
sed -e '/Warning/d' -e '/Note (probably harmless)/d' \
57265728
-e 's/-bE:perl.exp//' -e 's/-lc //'`
@@ -5761,7 +5763,7 @@ rm -f core conftest.err conftest.$ac_objext \
57615763
LDFLAGS=$ldflags_save
57625764
if test $perl_ok = yes; then
57635765
if test "X$perlcppflags" != "X"; then
5764-
PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[^ ]*//'`
5766+
PERL_CFLAGS=$perlcppflags
57655767
fi
57665768
if test "X$perlldflags" != "X"; then
57675769
if test "X`echo \"$LDFLAGS\" | $FGREP -e \"$perlldflags\"`" = "X"; then

src/configure.ac

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1006,10 +1006,13 @@ if test "$enable_perlinterp" = "yes" -o "$enable_perlinterp" = "dynamic"; then
10061006
dnl Remove "-fno-something", it breaks using cproto.
10071007
dnl Remove "-fdebug-prefix-map", it isn't supported by clang.
10081008
dnl Remove "FORTIFY_SOURCE", it will be defined twice.
1009+
dnl remove -pipe and -Wxxx, it confuses cproto
10091010
perlcppflags=`$vi_cv_path_perl -Mlib=$srcdir -MExtUtils::Embed \
10101011
-e 'ccflags;perl_inc;print"\n"' | sed -e 's/-fno[[^ ]]*//' \
10111012
-e 's/-fdebug-prefix-map[[^ ]]*//g' \
1012-
-e 's/\(-Wp,\)\?-D_FORTIFY_SOURCE=.//g'`
1013+
-e 's/-pipe //' \
1014+
-e 's/-W[[^ ]]*//g' \
1015+
-e 's/-D_FORTIFY_SOURCE=.//g'`
10131016
dnl Remove "-lc", it breaks on FreeBSD when using "-pthread".
10141017
perllibs=`cd $srcdir; $vi_cv_path_perl -MExtUtils::Embed -e 'ldopts' | \
10151018
sed -e '/Warning/d' -e '/Note (probably harmless)/d' \
@@ -1037,8 +1040,7 @@ if test "$enable_perlinterp" = "yes" -o "$enable_perlinterp" = "dynamic"; then
10371040
LDFLAGS=$ldflags_save
10381041
if test $perl_ok = yes; then
10391042
if test "X$perlcppflags" != "X"; then
1040-
dnl remove -pipe and -Wxxx, it confuses cproto
1041-
PERL_CFLAGS=`echo "$perlcppflags" | sed -e 's/-pipe //' -e 's/-W[[^ ]]*//'`
1043+
PERL_CFLAGS=$perlcppflags
10421044
fi
10431045
if test "X$perlldflags" != "X"; then
10441046
if test "X`echo \"$LDFLAGS\" | $FGREP -e \"$perlldflags\"`" = "X"; then

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -761,6 +761,8 @@ static char *(features[]) =
761761

762762
static int included_patches[] =
763763
{ /* Add new patch number below this line */
764+
/**/
765+
1156,
764766
/**/
765767
1155,
766768
/**/

0 commit comments

Comments
 (0)