pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/lang/perl5 perl5: Fix CFLAGS.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7a1537b86820
branches:  trunk
changeset: 373956:7a1537b86820
user:      jperkin <jperkin%pkgsrc.org@localhost>
date:      Fri Jan 12 11:32:20 2018 +0000

description:
perl5: Fix CFLAGS.

We need to remove -std=c89 so that compilers which default to C99 don't fail,
and don't automatically add -fstack-protector flags, leave it to the user to
decide via PKGSRC_USE_SSP.  Fixes clang on SmartOS.  Bump PKGREVISION.

diffstat:

 lang/perl5/Makefile                |   4 +-
 lang/perl5/distinfo                |   5 ++-
 lang/perl5/patches/patch-Configure |  51 ++++++++++++++++++++++---------------
 lang/perl5/patches/patch-cflags.SH |  15 +++++++++++
 4 files changed, 50 insertions(+), 25 deletions(-)

diffs (242 lines):

diff -r c9f395828a15 -r 7a1537b86820 lang/perl5/Makefile
--- a/lang/perl5/Makefile       Fri Jan 12 09:08:05 2018 +0000
+++ b/lang/perl5/Makefile       Fri Jan 12 11:32:20 2018 +0000
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.243 2017/11/16 10:28:26 wiz Exp $
+# $NetBSD: Makefile,v 1.244 2018/01/12 11:32:20 jperkin Exp $
 
 .include "license.mk"
 .include "Makefile.common"
 
-PKGREVISION=   1
+PKGREVISION=   2
 COMMENT=       Practical Extraction and Report Language
 
 CONFLICTS+=    perl-base-[0-9]* perl-thread-[0-9]*
diff -r c9f395828a15 -r 7a1537b86820 lang/perl5/distinfo
--- a/lang/perl5/distinfo       Fri Jan 12 09:08:05 2018 +0000
+++ b/lang/perl5/distinfo       Fri Jan 12 11:32:20 2018 +0000
@@ -1,10 +1,10 @@
-$NetBSD: distinfo,v 1.147 2017/11/16 10:28:26 wiz Exp $
+$NetBSD: distinfo,v 1.148 2018/01/12 11:32:20 jperkin Exp $
 
 SHA1 (perl-5.26.1.tar.bz2) = fadec45b7b48a06b3d2adab91c13f568dce717cd
 RMD160 (perl-5.26.1.tar.bz2) = fff5bf2e6ad6488b8866bf300c32707972b8ffc6
 SHA512 (perl-5.26.1.tar.bz2) = 821a4b78a22d24d6f79b56f68ed4a36db24bddc4dbe36c9d2622cd15d7abf6548186c037dea3d3745c1781af83339d0b54297f8094aa538046c0e57a953b5547
 Size (perl-5.26.1.tar.bz2) = 14492844 bytes
-SHA1 (patch-Configure) = d65082b236c81c310eb683a07c8ab60fc2a3e2f0
+SHA1 (patch-Configure) = 6f3aa5c8d971e2c58dbd3e348f9edd59e298c181
 SHA1 (patch-MANIFEST) = b27b0e1754fe2c4484931219fa17c562db88d41a
 SHA1 (patch-Makefile.SH) = e9353181a286f52303d09cb4ce0b2c04ec104217
 SHA1 (patch-aa) = 3a2b39c9eb903e68ef7d03ae448c51c147c19aa1
@@ -12,6 +12,7 @@
 SHA1 (patch-ac) = 4baa8f80695687abb53d4f4e1830cf86db5b2bf7
 SHA1 (patch-aq) = 4bf5a76f0277b0939b2ca7720f4bb045a788b5cc
 SHA1 (patch-caretx.c) = 9f53a9133f8dd2f962b448d7288b5b20454c86fb
+SHA1 (patch-cflags.SH) = 018eb664f14b2a37df02a13769f572566443d81b
 SHA1 (patch-ch) = 5b6a89c82e158bab0a5f06add48c28e600678099
 SHA1 (patch-ck) = 483e93a782e5627d3c7334d930ee11010fe7f7d8
 SHA1 (patch-cn) = d1877383e213a414562b5bb4c1e8aa785926fab7
diff -r c9f395828a15 -r 7a1537b86820 lang/perl5/patches/patch-Configure
--- a/lang/perl5/patches/patch-Configure        Fri Jan 12 09:08:05 2018 +0000
+++ b/lang/perl5/patches/patch-Configure        Fri Jan 12 11:32:20 2018 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-Configure,v 1.4 2017/07/07 05:54:24 wiz Exp $
+$NetBSD: patch-Configure,v 1.5 2018/01/12 11:32:21 jperkin Exp $
 
 * Use "uname -r" to get OS version for *BSD.
 * Move $loclibpth to the end of $dlist, instead of the beginning.
@@ -6,9 +6,9 @@
 * Honor more ldflags in shared objects.
 * Several other changes.
 
---- Configure.orig     2017-05-30 09:57:56.000000000 +0000
-+++ Configure  2017-07-07 05:44:48.961150149 +0000
-@@ -3485,13 +3485,14 @@
+--- Configure.orig     2017-09-22 14:27:02.000000000 +0000
++++ Configure
+@@ -3485,13 +3485,14 @@ EOM
                        osvers="$3"
                        ;;
                dragonfly) osname=dragonfly
@@ -25,7 +25,7 @@
                genix)  osname=genix ;;
                gnu)    osname=gnu
                        osvers="$3" ;;
-@@ -3514,7 +3515,7 @@
+@@ -3514,7 +3515,7 @@ EOM
                MiNT)   osname=mint
                        ;;
                netbsd*) osname=netbsd
@@ -34,7 +34,7 @@
                        ;;
                news-os) osvers="$3"
                        case "$3" in
-@@ -3524,7 +3525,7 @@
+@@ -3524,7 +3525,7 @@ EOM
                        ;;
                nonstop-ux) osname=nonstopux ;;
                openbsd) osname=openbsd
@@ -43,7 +43,7 @@
                        ;;
                os2)    osname=os2
                        osvers="$4"
-@@ -3539,6 +3540,9 @@
+@@ -3539,6 +3540,9 @@ EOM
                qnx) osname=qnx
                        osvers="$4"
                        ;;
@@ -53,7 +53,7 @@
                solaris) osname=solaris
                        case "$3" in
                        5*) osvers=`echo $3 | $sed 's/^5/2/g'` ;;
-@@ -4977,7 +4981,7 @@
+@@ -4977,7 +4981,7 @@ esac
  # If using gcc or clang, we can get better values for libpth, incpth
  # and usrinc directly from the compiler.
  # Note that ccname for clang is also gcc.
@@ -62,7 +62,7 @@
      gcc)
        $echo 'extern int foo;' > try.c
        set X `$cppstdin -v try.c 2>&1 | $awk '/^#include </,/^End of search /'|$cppfilter $grep '/include'`
-@@ -5053,14 +5057,14 @@
+@@ -5053,14 +5057,14 @@ case "$plibpth" in
  esac
  case "$libpth" in
  ' ') dlist='';;
@@ -79,7 +79,7 @@
                case " $libpth " in
                *" $xxx "*) ;;
                *) libpth="$libpth $xxx";;
-@@ -5176,7 +5180,7 @@
+@@ -5176,7 +5180,7 @@ lib_ext=$_a
  obj_ext=$_o
  path_sep=$p_
  
@@ -88,7 +88,16 @@
  
  : Which makefile gets called first.  This is used by make depend.
  case "$firstmakefile" in
-@@ -6492,6 +6496,15 @@
+@@ -5507,7 +5511,7 @@ default|recommended)
+       # thing. (NWC)
+       case "$osname" in
+       amigaos) ;; # -fstack-protector builds but doesn't work
+-      *)      case "$gccversion" in
++      nothing) case "$gccversion" in
+               ?*)     set stack-protector-strong -fstack-protector-strong
+                       eval $checkccflag
+                       case "$dflt" in
+@@ -6492,6 +6496,15 @@ case "$nm_so_opt" in
        ;;
  esac
  
@@ -104,7 +113,7 @@
  : Figure out where the libc is located
  case "$runnm" in
  true)
-@@ -7626,7 +7639,9 @@
+@@ -7626,7 +7639,9 @@ rp='Pathname for the site-specific libra
  . ./getfile
  prefixvar=sitelib
  . ./setprefixvar
@@ -115,7 +124,7 @@
  
  : Determine list of previous versions to include in @INC
  $cat > getverlist <<EOPL
-@@ -8038,7 +8053,9 @@
+@@ -8038,7 +8053,9 @@ case "$vendorprefix" in
        vendorlibexp="$ansexp"
        ;;
  esac
@@ -126,7 +135,7 @@
  prefixvar=vendorlib
  . ./installprefix
  
-@@ -8580,6 +8597,7 @@
+@@ -8580,6 +8597,7 @@ EOM
                          esac
                          ;;
                    *linux*|irix*|gnu*)  dflt="-shared $optimize" ;;
@@ -134,7 +143,7 @@
                    solaris) # See [perl #66604].
                            # On Solaris 11, gcc -m64 on amd64
                            # appears not to understand -G.  gcc versions at
-@@ -8619,7 +8637,7 @@
+@@ -8619,7 +8637,7 @@ EOM
        esac
        for thisflag in $ldflags; do
            case "$thisflag" in
@@ -143,7 +152,7 @@
                    case " $dflt " in
                        *" $thisflag "*) ;;
                        *) dflt="$dflt $thisflag" ;;
-@@ -8878,6 +8896,10 @@
+@@ -8878,6 +8896,10 @@ if "$useshrplib"; then
        bsdos|linux|irix*|dec_osf|gnu*|haiku)
                xxx="-Wl,-rpath,$shrpdir"
                ;;
@@ -154,7 +163,7 @@
        hpux*)
                # hpux doesn't like the default, either.
                tmp_shrpenv="env LDOPTS=\"+s +b${shrpdir}\""
-@@ -8885,6 +8907,9 @@
+@@ -8885,6 +8907,9 @@ if "$useshrplib"; then
        cygwin)
                # cygwin needs only ldlibpth
                ;;
@@ -164,7 +173,7 @@
        *)
                tmp_shrpenv="env LD_RUN_PATH=$shrpdir"
                ;;
-@@ -9966,6 +9991,13 @@
+@@ -9966,6 +9991,13 @@ esac
  : Check if we want perlio
  useperlio="$define"
  
@@ -178,7 +187,7 @@
  : Set the vendorbin variables
  case "$vendorprefix" in
  '')   d_vendorbin="$undef"
-@@ -20424,7 +20456,15 @@
+@@ -20424,7 +20456,15 @@ RCAT(Rei,ser)
  ACAT(Cir,cus)
  EOCP
  $cppstdin $cppflags $cppminus <cpp_stuff.c >cpp_stuff.out 2>&1
@@ -195,7 +204,7 @@
        echo "Oh!  Smells like ANSI's been here." >&4
        echo "We can catify or stringify, separately or together!"
        cpp_stuff=42
-@@ -23296,6 +23336,21 @@
+@@ -23296,6 +23336,21 @@ eval $inhdr
  set fenv.h i_fenv
  eval $inhdr
  
@@ -217,7 +226,7 @@
  : see if this is a fp.h system
  set fp.h i_fp
  eval $inhdr
-@@ -25665,4 +25720,3 @@
+@@ -25665,4 +25720,3 @@ $rm -f kit*isdone ark*isdone
  $rm -rf UU
  
  : End of Configure
diff -r c9f395828a15 -r 7a1537b86820 lang/perl5/patches/patch-cflags.SH
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/perl5/patches/patch-cflags.SH        Fri Jan 12 11:32:20 2018 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-cflags.SH,v 1.1 2018/01/12 11:32:21 jperkin Exp $
+
+Don't add -std=c89, requires c99.
+
+--- cflags.SH.orig     2017-07-18 22:49:30.000000000 +0000
++++ cflags.SH
+@@ -186,7 +186,7 @@ Intel*) ;; # # Is that you, Intel C++?
+ # -std=c89 before -ansi
+ # -pedantic* before -Werror=d-a-s
+ #
+-*)  for opt in -std=c89 -ansi $pedantic \
++*)  for opt in -ansi $pedantic \
+               -Werror=declaration-after-statement \
+               -Wextra -W \
+               -Wc++-compat -Wwrite-strings



Home | Main Index | Thread Index | Old Index