vinaigrette/scripts/pbuilder/build-sources

31 lines
675 B
Text
Raw Normal View History

2017-08-29 17:17:25 +02:00
#!/bin/bash
PKG_PATH=$1
apt-get -q update
VERSION=$(sed 's/\..*//' /etc/debian_version)
if [[ "$VERSION" == '7' ]]; then
apt-get -q -y -t wheezy-backports install devscripts
fi
cd $PKG_PATH
echo \
"******************************************************************************"
echo "Installing build-dependencies..."
mk-build-deps -i -r -t "apt-get --no-install-recommends -y" \
|| (echo "Error." && exit 1)
rm -f *build-deps*_all.deb
echo \
"******************************************************************************"
echo "Creating source package..."
# Creating source package without signing it
debuild -S -sa -uc
# Be sure to clean directory
debclean