aboutsummaryrefslogtreecommitdiff
path: root/pdebuild
blob: a8ece8cafc44735bb7f8d1582ccf389557d94bca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#! /bin/bash
set -e

while ! test -d ./debian -o "$(pwd)" = "/" ; do
    cd ..;
done

if test ! -d ./debian; then
    echo "Cannot find ./debian dir"
    exit 1
fi;

. /usr/lib/pbuilder/pbuilder-checkparams
$BUILDSOURCEROOTCMD dpkg-buildpackage -S -us -uc || true
$PBUILDERROOTCMD pbuilder build "$@" ../$(dpkg-parsechangelog|sed -n 's/^Source: //p')_$(dpkg-parsechangelog|sed -n 's/^Version: \(.*:\|\)//p').dsc