summaryrefslogtreecommitdiffstats
path: root/perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild')
-rw-r--r--perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild16
1 files changed, 13 insertions, 3 deletions
diff --git a/perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild b/perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild
index effca09493..76d99dddf8 100644
--- a/perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild
+++ b/perl/perl-Audio-FLAC-Header/perl-Audio-FLAC-Header.SlackBuild
@@ -1,13 +1,16 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for perl-Audio-FLAC-Header
# Written by Mark Grocock <mark@grocock.me.uk>
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=perl-Audio-FLAC-Header
VERSION=${VERSION:-2.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
SRCNAM=Audio-FLAC-Header
@@ -19,7 +22,14 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# 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
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -81,4 +91,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE