aboutsummaryrefslogtreecommitdiff
path: root/network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild')
-rw-r--r--network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild39
1 files changed, 31 insertions, 8 deletions
diff --git a/network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild b/network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild
index 0e4079c0bcaa..cd0e0dd1a598 100644
--- a/network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild
+++ b/network/dnscrypt-wrapper/dnscrypt-wrapper.SlackBuild
@@ -23,7 +23,7 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=dnscrypt-wrapper
-VERSION=${VERSION:-0.1.10}
+VERSION=${VERSION:-0.1.11}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -54,31 +54,54 @@ else
LIBDIRSUFFIX=""
fi
+# argparse is a git submodule required for building...
+ARGPARSEVERSION=${ARGPARSEVERSION:-2f310edc35e5adacaf738ccb9d73d9c23f4e38b1}
+
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
-rm -rf $PRGNAM-$VERSION
+rm -rf $PRGNAM-$VERSION argparse-$ARGPARSEVERSION
if [ -e $CWD/v$VERSION.tar.gz ]; then
tar xvf $CWD/v$VERSION.tar.gz
else
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
fi
+if [ -e $CWD/$ARGPARSEVERSION.tar.gz ]; then
+ tar xvf $CWD/$ARGPARSEVERSION.tar.gz
+else
+ tar xvf $CWD/argparse-$ARGPARSEVERSION.tar.gz
+fi
+# argparse source is expected in dnscrypt source...
+mv argparse-$ARGPARSEVERSION/* $PRGNAM-$VERSION/argparse/
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 {} \;
+# Patch out git submodule init. Already have argparse anyway, and this is not
+# a git repo (so it would fail)...
+patch -p0 < $CWD/Makefile.patch
+
+make configure
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
+./configure \
+ --prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --mandir=/usr/man \
+ --docdir=/usr/doc/$PRGNAM-$VERSION \
+ --build=$ARCH-slackware-linux
+
make
-# A Makefile patch would be larger than this, so...
mkdir -p $PKG/usr/bin
-install -m 755 -t $PKG/usr/bin dnscrypt-wrapper
+make install BINDIR=$PKG/usr/bin
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