@@ -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
0 commit comments