summaryrefslogtreecommitdiff
path: root/lang/perl5
diff options
context:
space:
mode:
authorsevan <sevan@pkgsrc.org>2018-10-29 14:25:25 +0000
committersevan <sevan@pkgsrc.org>2018-10-29 14:25:25 +0000
commitf0d603131e6724ca8f0925f4765df8cdf0f3e995 (patch)
treec1b0c9f5f70912f81f3a783bafcf5072fa68dfc6 /lang/perl5
parentfc85c4a8781e1ba3459b245c5bce812fe6c0a172 (diff)
downloadpkgsrc-f0d603131e6724ca8f0925f4765df8cdf0f3e995.tar.gz
Add support for Minix
Diffstat (limited to 'lang/perl5')
-rw-r--r--lang/perl5/Makefile6
-rw-r--r--lang/perl5/distinfo5
-rw-r--r--lang/perl5/files/cpan-DB_File-hints-minix.pl6
-rw-r--r--lang/perl5/patches/patch-Configure56
-rw-r--r--lang/perl5/patches/patch-hints_minix.sh155
5 files changed, 203 insertions, 25 deletions
diff --git a/lang/perl5/Makefile b/lang/perl5/Makefile
index 6509d60f25f..312ade01d78 100644
--- a/lang/perl5/Makefile
+++ b/lang/perl5/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.249 2018/10/15 03:01:37 taca Exp $
+# $NetBSD: Makefile,v 1.250 2018/10/29 14:25:25 sevan Exp $
.include "license.mk"
.include "Makefile.common"
@@ -207,6 +207,7 @@ LIBSWANTED.HPUX= cl pthread $$libswanted # see Perl's README.hpux
LIBSWANTED.IRIX= m crypt
LIBSWANTED.Interix= m dl
LIBSWANTED.Linux= m crypt dl nsl
+LIBSWANTED.Minix= m crypt c
LIBSWANTED.MirBSD= m crypt
LIBSWANTED.NetBSD= m crypt
LIBSWANTED.OpenBSD= m crypt
@@ -226,6 +227,7 @@ SYSLIBPATH.Darwin= /usr/lib
SYSLIBPATH.DragonFly= /usr/lib
SYSLIBPATH.FreeBSD= /usr/lib
SYSLIBPATH.Interix= /usr/lib
+SYSLIBPATH.Minix= /usr/lib
SYSLIBPATH.MirBSD= /usr/lib
SYSLIBPATH.NetBSD= /usr/lib
SYSLIBPATH.OpenBSD= /usr/lib
@@ -289,6 +291,8 @@ post-extract:
${WRKSRC}/cpan/DB_File/hints/netbsd.pl
cp ${FILESDIR}/cpan-DB_File-hints-openbsd.pl \
${WRKSRC}/cpan/DB_File/hints/openbsd.pl
+ cp ${FILESDIR}/cpan-DB_File-hints-minix.pl \
+ ${WRKSRC}/cpan/DB_File/hints/minix.pl
pre-configure:
cd ${WRKSRC} && find `pwd` -name "*.orig" -type f -exec ${RM} -f {} \;
diff --git a/lang/perl5/distinfo b/lang/perl5/distinfo
index 87a60d34781..22ee75efc0f 100644
--- a/lang/perl5/distinfo
+++ b/lang/perl5/distinfo
@@ -1,10 +1,10 @@
-$NetBSD: distinfo,v 1.154 2018/10/15 03:01:37 taca Exp $
+$NetBSD: distinfo,v 1.155 2018/10/29 14:25:25 sevan Exp $
SHA1 (perl-5.28.0.tar.xz) = c0e9e7a0dea97ec9816687d865fd461a99ef185c
RMD160 (perl-5.28.0.tar.xz) = 34c9ad0560a2eed134e09282696bfae307cbeb6a
SHA512 (perl-5.28.0.tar.xz) = de701e37371b81cecf06098bb2c09017bde9cebaf9537d58838d0adf605ac2ecf739897b0a73576a7adb74d4cf65591ec4d2ed1f94b7191e695f88cb7e214a39
Size (perl-5.28.0.tar.xz) = 12410536 bytes
-SHA1 (patch-Configure) = e4ae2c84bece8823ec1bf98415706b4d2491a5e9
+SHA1 (patch-Configure) = 00754ccc8bbeb38f8a0363d1bfba908fea9ef4d6
SHA1 (patch-Makefile.SH) = febb87d876a44091a761d3ef99c649f3e4bdd394
SHA1 (patch-aa) = 3a2b39c9eb903e68ef7d03ae448c51c147c19aa1
SHA1 (patch-ab) = 0ad5988b7cadfb13d9646a59a57f6cf884a6238a
@@ -14,6 +14,7 @@ SHA1 (patch-cflags.SH) = 7ad64e5a17b876bff4bbe238abc4a57354acf4fe
SHA1 (patch-dist_Storable_Makefile.PL) = fd8964cf3c94ba811caaf71be21650b29e4c8e50
SHA1 (patch-doio.c) = 684563a5416604a61632bd9cf70f4f225cce81e5
SHA1 (patch-hints_cygwin.sh) = 1b21d927d6b7379754c4cd64a2b05d3632c35470
+SHA1 (patch-hints_minix.sh) = cb62ad0be5c38ca5b79f180252ca0843a0444f8a
SHA1 (patch-hints_netbsd.sh) = 0d549a48800372d75fe34b783529a78cba90f646
SHA1 (patch-hints_solaris__2.sh) = 0e54889648a6f0f2a0232c5e01bef89d245c213d
SHA1 (patch-ta) = a9d13eeec22733e4087942f217a0d47a19498a6f
diff --git a/lang/perl5/files/cpan-DB_File-hints-minix.pl b/lang/perl5/files/cpan-DB_File-hints-minix.pl
new file mode 100644
index 00000000000..f3443e9fd7b
--- /dev/null
+++ b/lang/perl5/files/cpan-DB_File-hints-minix.pl
@@ -0,0 +1,6 @@
+# $NetBSD: cpan-DB_File-hints-minix.pl,v 1.1 2018/10/29 14:25:25 sevan Exp $
+
+# cpan/DB_File:
+# Minix through NetBSD does not provide -ldb, so avoid linking to it
+
+$self->{LIBS} = [''];
diff --git a/lang/perl5/patches/patch-Configure b/lang/perl5/patches/patch-Configure
index 4364ee070fa..9a72daaaa70 100644
--- a/lang/perl5/patches/patch-Configure
+++ b/lang/perl5/patches/patch-Configure
@@ -1,14 +1,15 @@
-$NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
+$NetBSD: patch-Configure,v 1.7 2018/10/29 14:25:25 sevan Exp $
* Use "uname -r" to get OS version for *BSD.
* Move $loclibpth to the end of $dlist, instead of the beginning.
* Detect systems which have <fenv.h> but where using it fails.
* Honor more ldflags in shared objects.
+* Add Minix
* Several other changes.
---- Configure.orig 2018-05-21 12:29:23.000000000 +0000
-+++ Configure
-@@ -3471,13 +3471,14 @@ EOM
+--- Configure.orig Mon May 21 12:29:23 2018
++++ Configure Mon Oct 29 01:18:22 2018
+@@ -3471,13 +3471,14 @@
osvers="$3"
;;
dragonfly) osname=dragonfly
@@ -25,16 +26,20 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
genix) osname=genix ;;
gnu) osname=gnu
osvers="$3" ;;
-@@ -3500,7 +3501,7 @@ EOM
+@@ -3499,8 +3500,11 @@
+ ;;
MiNT) osname=mint
;;
++ minix*) osname=minix
++ osvers=`$uname -r`
++ ;;
netbsd*) osname=netbsd
- osvers="$3"
+ osvers=`$uname -r | UU/tr '[A-Z]' '[a-z]'`
;;
news-os) osvers="$3"
case "$3" in
-@@ -3510,7 +3511,7 @@ EOM
+@@ -3510,7 +3514,7 @@
;;
nonstop-ux) osname=nonstopux ;;
openbsd) osname=openbsd
@@ -43,7 +48,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
;;
os2) osname=os2
osvers="$4"
-@@ -3525,6 +3526,9 @@ EOM
+@@ -3525,6 +3529,9 @@
qnx) osname=qnx
osvers="$4"
;;
@@ -53,7 +58,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
solaris) osname=solaris
case "$3" in
5*) osvers=`echo $3 | $sed 's/^5/2/g'` ;;
-@@ -4963,7 +4967,7 @@ esac
+@@ -4963,7 +4970,7 @@
# 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 +67,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
gcc)
$echo 'extern int foo;' > try.c
set X `$cppstdin -v try.c 2>&1 | $awk '/^#include </,/^End of search /'|$cppfilter $grep '/include'`
-@@ -5039,14 +5043,14 @@ case "$plibpth" in
+@@ -5039,14 +5046,14 @@
esac
case "$libpth" in
' ') dlist='';;
@@ -79,7 +84,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
case " $libpth " in
*" $xxx "*) ;;
*) libpth="$libpth $xxx";;
-@@ -5162,7 +5166,7 @@ lib_ext=$_a
+@@ -5162,7 +5169,7 @@
obj_ext=$_o
path_sep=$p_
@@ -88,7 +93,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
: Which makefile gets called first. This is used by make depend.
case "$firstmakefile" in
-@@ -5493,7 +5497,7 @@ default|recommended)
+@@ -5493,7 +5500,7 @@
# thing. (NWC)
case "$osname" in
amigaos) ;; # -fstack-protector builds but doesn't work
@@ -97,7 +102,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
?*) set stack-protector-strong -fstack-protector-strong
eval $checkccflag
case "$dflt" in
-@@ -6477,6 +6481,15 @@ case "$nm_so_opt" in
+@@ -6477,6 +6484,15 @@
;;
esac
@@ -113,7 +118,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
: Figure out where the libc is located
case "$runnm" in
true)
-@@ -7604,7 +7617,9 @@ rp='Pathname for the site-specific libra
+@@ -7604,7 +7620,9 @@
. ./getfile
prefixvar=sitelib
. ./setprefixvar
@@ -124,7 +129,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
: Determine list of previous versions to include in @INC
$cat > getverlist <<EOPL
-@@ -8015,7 +8030,9 @@ case "$vendorprefix" in
+@@ -8015,7 +8033,9 @@
vendorlibexp="$ansexp"
;;
esac
@@ -135,7 +140,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
prefixvar=vendorlib
. ./installprefix
-@@ -8511,6 +8528,7 @@ EOM
+@@ -8511,6 +8531,7 @@
esac
;;
*linux*|irix*|gnu*) dflt="-shared $optimize" ;;
@@ -143,7 +148,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
solaris) # See [perl #66604].
# On Solaris 11, gcc -m64 on amd64
# appears not to understand -G. gcc versions at
-@@ -8550,7 +8568,7 @@ EOM
+@@ -8550,7 +8571,7 @@
esac
for thisflag in $ldflags; do
case "$thisflag" in
@@ -152,7 +157,14 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
case " $dflt " in
*" $thisflag "*) ;;
*) dflt="$dflt $thisflag" ;;
-@@ -8809,6 +8827,10 @@ if "$useshrplib"; then
+@@ -8803,12 +8824,16 @@
+ solaris)
+ xxx="-R $shrpdir"
+ ;;
+- freebsd|mirbsd|netbsd|openbsd|interix|dragonfly|bitrig)
++ freebsd|minix|mirbsd|netbsd|openbsd|interix|dragonfly|bitrig)
+ xxx="-Wl,-R$shrpdir"
+ ;;
bsdos|linux|irix*|dec_osf|gnu*|haiku)
xxx="-Wl,-rpath,$shrpdir"
;;
@@ -163,7 +175,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
hpux*)
# hpux doesn't like the default, either.
tmp_shrpenv="env LDOPTS=\"+s +b${shrpdir}\""
-@@ -8816,6 +8838,9 @@ if "$useshrplib"; then
+@@ -8816,6 +8841,9 @@
cygwin)
# cygwin needs only ldlibpth
;;
@@ -173,7 +185,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
*)
tmp_shrpenv="env LD_RUN_PATH=$shrpdir"
;;
-@@ -9896,6 +9921,13 @@ esac
+@@ -9896,6 +9924,13 @@
: Check if we want perlio
useperlio="$define"
@@ -187,7 +199,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
: Set the vendorbin variables
case "$vendorprefix" in
'') d_vendorbin="$undef"
-@@ -19825,7 +19857,15 @@ RCAT(Rei,ser)
+@@ -19825,7 +19860,15 @@
ACAT(Cir,cus)
EOCP
$cppstdin $cppflags $cppminus <cpp_stuff.c >cpp_stuff.out 2>&1
@@ -204,7 +216,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
echo "Oh! Smells like ANSI's been here." >&4
echo "We can catify or stringify, separately or together!"
cpp_stuff=42
-@@ -22641,6 +22681,21 @@ eval $inhdr
+@@ -22641,6 +22684,21 @@
set fenv.h i_fenv
eval $inhdr
@@ -226,7 +238,7 @@ $NetBSD: patch-Configure,v 1.6 2018/08/22 08:37:46 wiz Exp $
: see if this is a fp.h system
set fp.h i_fp
eval $inhdr
-@@ -25015,4 +25070,3 @@ $rm -f kit*isdone ark*isdone
+@@ -25015,4 +25073,3 @@
$rm -rf UU
: End of Configure
diff --git a/lang/perl5/patches/patch-hints_minix.sh b/lang/perl5/patches/patch-hints_minix.sh
new file mode 100644
index 00000000000..c5430d63ec7
--- /dev/null
+++ b/lang/perl5/patches/patch-hints_minix.sh
@@ -0,0 +1,155 @@
+$NetBSD: patch-hints_minix.sh,v 1.1 2018/10/29 14:25:25 sevan Exp $
+
+Add a hints file for Minix, derived from the NetBSD one but stripped back to
+remove most of the legacy parts.
+
+--- hints/minix.sh.orig Mon Oct 29 01:00:03 2018
++++ hints/minix.sh Mon Oct 29 00:59:50 2018
+@@ -0,0 +1,147 @@
++# hints/minix.sh
++#
++# Please check with packages@netbsd.org before making modifications
++# to this file.
++
++case "$archname" in
++'')
++ archname=`uname -m`-${osname}
++ ;;
++esac
++
++# NetBSD keeps dynamic loading dl*() functions in /usr/lib/crt0.o,
++# so Configure doesn't find them (unless you abandon the nm scan).
++#
++case "$osvers" in
++*)
++ if test -f /usr/libexec/ld.elf_so; then
++ # ELF
++ d_dlopen=$define
++ d_dlerror=$define
++ cccdlflags="-DPIC -fPIC $cccdlflags"
++ lddlflags="-shared $lddlflags"
++ rpathflag="-Wl,-rpath,"
++ ccdlflags="-Wl,-E $ccdlflags"
++ elif test -f /usr/libexec/ld.so; then
++ # a.out
++ d_dlopen=$define
++ d_dlerror=$define
++ cccdlflags="-DPIC -fPIC $cccdlflags"
++ lddlflags="-Bshareable $lddlflags"
++ rpathflag="-R"
++ else
++ d_dlopen=$undef
++ rpathflag=
++ fi
++ d_getprotoent_r="$undef"
++ d_getprotobyname_r="$undef"
++ d_getprotobynumber_r="$undef"
++ d_setprotoent_r="$undef"
++ d_endprotoent_r="$undef"
++ d_getservent_r="$undef"
++ d_getservbyname_r="$undef"
++ d_getservbyport_r="$undef"
++ d_setservent_r="$undef"
++ d_endservent_r="$undef"
++ d_gethostbyname_r="$undef"
++ d_gethostbyaddr2_r="$undef"
++ d_gethostbyaddr_r="$undef"
++ d_sethostent_r="$undef"
++ d_gethostent_r="$undef"
++ d_endhostent_r="$undef"
++ d_getprotoent_r_proto="0"
++ d_getprotobyname_r_proto="0"
++ d_getprotobynumber_r_proto="0"
++ d_setprotoent_r_proto="0"
++ d_endprotoent_r_proto="0"
++ d_getservent_r_proto="0"
++ d_getservbyname_r_proto="0"
++ d_getservbyport_r_proto="0"
++ d_setservent_r_proto="0"
++ d_endservent_r_proto="0"
++ d_gethostbyname_r_proto="0"
++ d_gethostbyaddr2_r_proto="0"
++ d_gethostbyaddr_r_proto="0"
++ d_sethostent_r_proto="0"
++ d_endhostent_r_proto="0"
++ d_gethostent_r_proto="0"
++ ;;
++esac
++
++# there's no problem with vfork.
++usevfork=true
++
++# This is there but in machine/ieeefp_h.
++ieeefp_h="define"
++
++# This script UU/usethreads.cbu will get 'called-back' by Configure
++# after it has prompted the user for whether to use threads.
++cat > UU/usethreads.cbu <<'EOCBU'
++case "$usethreads" in
++$define|true|[yY]*)
++ lpthread=
++ for xxx in pthread; do
++ for yyy in $loclibpth $plibpth $glibpth dummy; do
++ zzz=$yyy/lib$xxx.a
++ if test -f "$zzz"; then
++ lpthread=$xxx
++ break;
++ fi
++ zzz=$yyy/lib$xxx.so
++ if test -f "$zzz"; then
++ lpthread=$xxx
++ break;
++ fi
++ zzz=`ls $yyy/lib$xxx.so.* 2>/dev/null`
++ if test "X$zzz" != X; then
++ lpthread=$xxx
++ break;
++ fi
++ done
++ if test "X$lpthread" != X; then
++ break;
++ fi
++ done
++ if test "X$lpthread" != X; then
++ # Add -lpthread.
++ libswanted="$libswanted $lpthread"
++ # There is no libc_r as of NetBSD 1.5.2, so no c -> c_r.
++ # This will be revisited when NetBSD gains a native pthreads
++ # implementation.
++ else
++ echo "$0: No POSIX threads library (-lpthread) found. " \
++ "You may want to install GNU pth. Aborting." >&4
++ exit 1
++ fi
++ unset lpthread
++esac
++EOCBU
++
++# Set sensible defaults for Minix: look for local software in
++# /usr/local, plus the build prefix, which might or might not be
++# /usr/pkg.
++#
++loclibpth="/usr/local/lib ${prefix}/lib"
++locincpth="/usr/local/include ${prefix}/include"
++
++case "$rpathflag" in
++'')
++ ldflags=
++ ;;
++*)
++ ldflags=
++ for yyy in $loclibpth; do
++ ldflags="$ldflags $rpathflag$yyy"
++ done
++ ;;
++esac
++
++# malloc wrap works
++case "$usemallocwrap" in
++'') usemallocwrap='define' ;;
++esac
++
++# don't use perl malloc by default
++case "$usemymalloc" in
++'') usemymalloc=n ;;
++esac