DISTDIR='pdns/dnsdistdist'
fi
+if [ -z "$RELEASE" ];then
+ echo 'Please set $RELEASE' >&2
+ exit 1
+fi
+
set -e
set -x
cd $DISTDIR
cat > debian/changelog << EOF
-dnsdist (${VERSION}-1) unstable; urgency=medium
+dnsdist (${VERSION}-${RELEASE}) unstable; urgency=medium
* Automatic build
exit 1
fi
+if [ -z "$RELEASE" ];then
+ echo 'Please set $RELEASE' >&2
+ exit 1
+fi
+
set -e
set -x
exit 1
fi
-DIST=''
# libsodium is not available on all RPM platforms (like CentOS 7)
SODIUM_BUILDREQUIRES=''
Fedora\ *\ 21*)
SODIUM_BUILDREQUIRES='BuildRequires: libsodium-devel'
SODIUM_CONFIGURE='--enable-libsodium'
- DIST='.fc21'
;;
CentOS\ *\ 6*)
INIT_BUILDREQUIRES=''
INIT_FILES='%{_initrddir}/dnsdist'
SETUP='%setup -n %{name}-%{version}'
RPMBUILD_COMMAND="scl enable devtoolset-2 -- ${RPMBUILD_COMMAND}"
- DIST='.el6'
;;
CentOS\ Linux\ *\ 7*)
- DIST='.el7'
;;
*)
echo "No support for $OS (yet?)"
cat > dnsdist.spec << EOF
Name: dnsdist
Version: ${VERSION}
-Release: 1${DIST}
+Release: ${RELEASE}
Summary: Powerful and scriptable DNS loadbalancer
License: GPLv2
Vendor: PowerDNS.COM BV
${RPMBUILD_COMMAND}
-mv $HOME/rpmbuild/RPMS/x86_64/dnsdist-${VERSION}-1${DIST}.x86_64.rpm .
+mv $HOME/rpmbuild/RPMS/x86_64/dnsdist-${VERSION}-${RELEASE}.x86_64.rpm .