aboutsummaryrefslogtreecommitdiff
path: root/perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild
diff options
context:
space:
mode:
authorNicholas Hubbard <nicholashubbard@posteo.net>2022-10-06 12:00:18 +0100
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2022-10-08 09:12:46 +0700
commit96f06adaa8c27761fc9b0d6d937e3d43a7ead475 (patch)
tree8ac26619c5da0c357dda114182d4c946ff98feab /perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild
parenteabd709c721b53a776035067a0ab64187a9a90d3 (diff)
perl/perl-Parser-MGC: Updated for version 0.21.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild')
-rw-r--r--perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild50
1 files changed, 16 insertions, 34 deletions
diff --git a/perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild b/perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild
index f34c9326f334..1d75cdf8f9d4 100644
--- a/perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild
+++ b/perl/perl-Parser-MGC/perl-Parser-MGC.SlackBuild
@@ -1,8 +1,8 @@
#!/bin/bash
-# Slackware build script for Parser-MGC
+# Slackware build script for perl-Parser-MGC
-# Copyright 2017 Randall Sawyer, Scarborough ME, USA
+# Copyright 2022 Nicholas Hubbard <nicholashubbard@posteo.net>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -25,20 +25,14 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=perl-Parser-MGC
-VERSION=${VERSION:-0.16}
+VERSION=${VERSION:-0.21}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
SRCNAM="$(printf $PRGNAM | cut -d- -f2-)"
-if [ -z "$ARCH" ]; then
- case "$( uname -m )" in
- i?86) ARCH=i586 ;;
- arm*) ARCH=arm ;;
- *) ARCH=$( uname -m ) ;;
- esac
-fi
+ARCH=noarch
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
@@ -52,20 +46,6 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i586" ]; then
- SLKCFLAGS="-O2 -march=i586 -mtune=i686"
- LIBDIRSUFFIX=""
-elif [ "$ARCH" = "i686" ]; then
- SLKCFLAGS="-O2 -march=i686 -mtune=i686"
- LIBDIRSUFFIX=""
-elif [ "$ARCH" = "x86_64" ]; then
- SLKCFLAGS="-O2 -fPIC"
- LIBDIRSUFFIX="64"
-else
- SLKCFLAGS="-O2"
- LIBDIRSUFFIX=""
-fi
-
set -e
rm -rf $PKG
@@ -81,14 +61,16 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-perl Makefile.PL \
- PREFIX=/usr \
- INSTALLDIRS=vendor \
- INSTALLVENDORMAN1DIR=/usr/man/man1 \
- INSTALLVENDORMAN3DIR=/usr/man/man3
-make
-make test
-make install DESTDIR=$PKG
+perl Build.PL \
+ --prefix=/usr \
+ --installdirs=vendor \
+ --install_path libdoc=/usr/man/man3
+perl Build
+perl Build test
+perl Build install --destdir=$PKG
+
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
@@ -98,8 +80,8 @@ find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm -f
find $PKG -depth -type d -empty -delete || true
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -ar \
- Changes LICENSE README examples \
+cp -a \
+ Changes LICENSE README* \
$PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild