diff options
Diffstat (limited to 'network/opensmtpd-extras/opensmtpd-extras.SlackBuild')
-rw-r--r-- | network/opensmtpd-extras/opensmtpd-extras.SlackBuild | 25 |
1 files changed, 18 insertions, 7 deletions
diff --git a/network/opensmtpd-extras/opensmtpd-extras.SlackBuild b/network/opensmtpd-extras/opensmtpd-extras.SlackBuild index 5bd451b169..d88626fa12 100644 --- a/network/opensmtpd-extras/opensmtpd-extras.SlackBuild +++ b/network/opensmtpd-extras/opensmtpd-extras.SlackBuild @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for opensmtpd-extras # Yth | Pont-en-Royans, France | yth@ythogtha.org # @@ -19,10 +19,14 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=opensmtpd-extras -VERSION=${VERSION:-6.4.0} +SRCNAM=OpenSMTPD-extras +VERSION=${VERSION:-6.7.1} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -32,7 +36,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} @@ -96,9 +107,9 @@ rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP -rm -rf $PRGNAM-$VERSION -tar xvf $CWD/$PRGNAM-$VERSION.tar.gz -cd $PRGNAM-$VERSION +rm -rf $SRCNAM-$VERSION +tar xvf $CWD/$SRCNAM-$VERSION.tar.gz +cd $SRCNAM-$VERSION chown -R root:root . find -L . \ @@ -177,4 +188,4 @@ mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG -/sbin/makepkg -l y -p -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} +/sbin/makepkg -l y -p -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |