summaryrefslogtreecommitdiff
path: root/source/n/yptools/yptools.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/n/yptools/yptools.SlackBuild')
-rwxr-xr-xsource/n/yptools/yptools.SlackBuild21
1 files changed, 17 insertions, 4 deletions
diff --git a/source/n/yptools/yptools.SlackBuild b/source/n/yptools/yptools.SlackBuild
index 3b876935..1205874d 100755
--- a/source/n/yptools/yptools.SlackBuild
+++ b/source/n/yptools/yptools.SlackBuild
@@ -1,6 +1,6 @@
-#!/bin/sh
+#!/bin/bash
-# Copyright 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2016 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2016, 2017, 2018 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -20,10 +20,12 @@
# 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)
# Package version number:
+PKGNAM=yptools
VERSION=2.14
-BUILD=${BUILD:-7}
+BUILD=${BUILD:-10}
YPTOOLS=$VERSION
YPBINDMT=1.38
@@ -40,6 +42,14 @@ if [ -z "$ARCH" ]; then
esac
fi
+# 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 "$PKGNAM-$VERSION-$ARCH-$BUILD.txz"
+ exit 0
+fi
+
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
@@ -54,7 +64,6 @@ else
LIBDIRSUFFIX=""
fi
-CWD=$(pwd)
TMP=${TMP:-/tmp}
PKG=$TMP/package-yptools
rm -rf $PKG
@@ -84,6 +93,9 @@ make clean
--disable-domainname \
$ARCH-slackware-linux
make CFLAGS="$SLKCFLAGS" || exit 1
+
+mkdir -p $PKG/etc/default
+cat $CWD/yp.default > $PKG/etc/default/yp.new
mkdir -p $PKG/var/yp
cat etc/nicknames > $PKG/var/yp/nicknames.new
mkdir -p $PKG/usr/share/locale/de/LC_MESSAGES
@@ -279,6 +291,7 @@ fi
config etc/nsswitch.conf-nis.new
config etc/netgroup.new
config etc/yp.conf.new
+config etc/default/yp.new
config etc/rc.d/rc.yp.new
config var/yp/nicknames.new
config var/yp/Makefile.new