X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;f=id-deb-build%2Fid-pbuild-root.sh;h=1707786693a948d21c1e868754d1684f2b9a63ce;hb=f84aec471c349d3055cb1ffd06e84d842e8e13e8;hp=3eeb85e43da31afba6c4b7f963cda114913896aa;hpb=327a998e2b3be2c7f0574c2862e18eadd5070947;p=git-tools-moved-to-github.git diff --git a/id-deb-build/id-pbuild-root.sh b/id-deb-build/id-pbuild-root.sh index 3eeb85e..1707786 100755 --- a/id-deb-build/id-pbuild-root.sh +++ b/id-deb-build/id-pbuild-root.sh @@ -8,6 +8,10 @@ Options: [--dsc=dscfile] [--dist=distribution] [--arch=architecture] + [--home=home] + +This script is should be called with root privilege. It is meant to be +called by id-pbuild.sh. EOF exit $1 } @@ -28,8 +32,11 @@ while test $# -gt 0; do --dsc=*) dsc=$optarg ;; + --home=*) + HOME=$optarg + ;; -*) - do_help=yes + usage 1 ;; esac shift @@ -37,8 +44,16 @@ done PBUILDER=/usr/sbin/pbuilder +if test -z "$dist" -o -z "$arch"; then + echo "dist and arch must be given" + usage 1 +fi rm -fr ${dist}-${arch} +if test ! -f $HOME/.pbuilderrc; then + echo "$HOME/.pbuilderrc missing" + exit 1 +fi if test "$dsc"; then if test ! -f /var/cache/pbuilder/${dist}-${arch}-base.tgz; then DIST=$dist ARCH=$arch $PBUILDER --create