From: bert hubert Date: Fri, 9 Jan 2015 19:55:28 +0000 (+0100) Subject: with this commit ./dist-recursor ; ./buid-recursor gets you debs and RPMs. Old 'speci... X-Git-Tag: rec-3.7.0-rc1~36 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d5ec83001a536d2246ab899352839d3a793d34a5;p=thirdparty%2Fpdns.git with this commit ./dist-recursor ; ./buid-recursor gets you debs and RPMs. Old 'specify version' syntax still works. --- diff --git a/pdns/build-recursor b/pdns/build-recursor index 887663e317..e7d58719c8 100755 --- a/pdns/build-recursor +++ b/pdns/build-recursor @@ -1,17 +1,30 @@ #!/bin/sh set -e set -x -cd pdns-recursor-$1 + +if [ -z "$1" ]; then + VERSION=$(git describe --always --dirty=+ 2>/dev/null || true) + if [ -z "$VERSION" ]; then + VERSION="UNKNOWN" + else + VERSION="git-"$VERSION + fi + DIST_HOST="$(id -u -n)@$(hostname -f || hostname)" +else + VERSION=$1 +fi + +cd pdns-recursor-$VERSION export DEBFULLNAME="PowerDNS.COM BV" -if echo $1 | grep -q ^git +if echo $VERSION | grep -q ^git then - DEBPKGNAME=pdns-recursor_0.0-$1 + DEBPKGNAME=pdns-recursor_0.0-$VERSION else - DEBPKGNAME=pdns-recursor_$1 + DEBPKGNAME=pdns-recursor_$VERSION fi -dh_make -e powerdns.support@powerdns.com -s -f ../pdns-recursor-$1.tar.bz2 -p $DEBPKGNAME < /dev/null +dh_make -e powerdns.support@powerdns.com -s -f ../pdns-recursor-$VERSION.tar.bz2 -p $DEBPKGNAME < /dev/null cp pdns-recursor.init.d debian/init.d -#[ -e debian/control ] || dh_make -e powerdns.support@powerdns.com -s -r cdbs -f ../pdns-recursor-$1.tar.bz2 < /dev/null +#[ -e debian/control ] || dh_make -e powerdns.support@powerdns.com -s -r cdbs -f ../pdns-recursor-$VERSION.tar.bz2 < /dev/null perl -i -pe 's/Description: <.*>/Description: extremely powerful and versatile recursing nameserver/' debian/control # only to be nice to people usind the generated .dsc perl -i -pe 's/(Build-Depends: .*)/$1, libboost-dev, libboost-serialization-dev, liblua5.1-0-dev/' debian/control