summaryrefslogtreecommitdiff
path: root/development/ldns
diff options
context:
space:
mode:
authorLarry Hajali <larryhaja@gmail.com>2016-08-14 21:18:50 -0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2016-08-20 07:51:32 +0700
commitd75f24e6f741be9264a5dcce2176a45653722bee (patch)
treee3d8c175a32742754eea4ea74e9d6608c03ed0b1 /development/ldns
parenta8679b3917a13c07ca417762d09f6a7aaf6015d0 (diff)
downloadslackbuilds-d75f24e6f741be9264a5dcce2176a45653722bee.tar.gz
development/ldns: Script cleanup
Signed-off-by: Larry Hajali <larryhaja[at]gmail[dot]com>
Diffstat (limited to 'development/ldns')
-rw-r--r--development/ldns/ldns-config-libversion.patch12
-rw-r--r--development/ldns/ldns.SlackBuild30
2 files changed, 28 insertions, 14 deletions
diff --git a/development/ldns/ldns-config-libversion.patch b/development/ldns/ldns-config-libversion.patch
new file mode 100644
index 0000000000..87ed867434
--- /dev/null
+++ b/development/ldns/ldns-config-libversion.patch
@@ -0,0 +1,12 @@
+diff -Naur ldns-1.6.17.orig/packaging/ldns-config.in ldns-1.6.17/packaging/ldns-config.in
+--- ldns-1.6.17.orig/packaging/ldns-config.in 2014-01-10 21:04:41.000000000 +0000
++++ ldns-1.6.17/packaging/ldns-config.in 2016-08-15 02:32:32.794747069 +0000
+@@ -9,7 +9,7 @@
+ LIBS="@LIBS@ @LIBSSL_LIBS@"
+ LIBDIR="@libdir@"
+ INCLUDEDIR="@includedir@"
+-LIBVERSION="@LIBLDNS_CURRENT@.@LIBLDNS_REVISION@.@LIBLDNS_AGE@"
++LIBVERSION="@PACKAGE_VERSION@"
+
+ for arg in $@
+ do
diff --git a/development/ldns/ldns.SlackBuild b/development/ldns/ldns.SlackBuild
index e97a36ded9..8665d7afd4 100644
--- a/development/ldns/ldns.SlackBuild
+++ b/development/ldns/ldns.SlackBuild
@@ -3,7 +3,7 @@
# Copyright 2008, 2009 Eric Hameleers, Eindhoven, NL
# Copyright 2008, 2009 Patrick J. Volkerding, Sebeka, MN USA
# Copyright 2010, R. Andrew Bailey, Chantilly, VA USA
-# Copyright 2014 Larry Hajali <larryhaja[at]gmail[dot]com>
+# Copyright 2014-2016 Larry Hajali <larryhaja[at]gmail[dot]com>
# All rights reserved.
#
# Permission to use, copy, modify, and distribute this software for
@@ -36,7 +36,7 @@
PRGNAM=ldns
VERSION=${VERSION:-1.6.17}
TAG=${TAG:-_SBo}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -70,19 +70,20 @@ set -e
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 $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
chown -R root:root .
find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
- -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
# Fix manpage building with perl-5.22 (thanks to Arch Linux)
patch -p1 < $CWD/perl-recent.patch
+# Fix ldns-config.
+patch -p1 < $CWD/ldns-config-libversion.patch
CXXFLAGS="$SLKCFLAGS" \
CFLAGS="$SLKCFLAGS" \
@@ -119,13 +120,14 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr
find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm -f || true
find $PKG -depth -type d -empty -delete || true
+# Install pkgconfig file.
+mkdir $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig
+install -m 0644 packaging/lib${PRGNAM}.pc $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig
+
# Create the root.key file
mkdir -p $PKG/etc/$PRGNAM
sed -n '/Zone/,$p' $CWD/root-anchors.xml | sed -e 's|<[^>]*>||g' | \
- while read line; do
- echo -n " $line"
- done | sed 's|\.|\. IN DS|' | \
- xargs > $PKG/etc/$PRGNAM/root.key.new
+ xargs | sed 's|\.|\. IN DS|' > $PKG/etc/$PRGNAM/root.key.new
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a Changelog LICENSE README* doc/TODO $PKG/usr/doc/$PRGNAM-$VERSION