3 NAME=`head debian/changelog -n1 | sed -n 's/^\(.*\) (\(.*\)) .*/\1-\2/p'`
4 [[ -z $NAME ]] && { echo "Could not extract package name and version from debian/changelog" 2>&1; exit 1; }
7 cp -r ../`basename $PWD` ../$NAME
10 find . -depth -name .svn -type d -exec rm -r {} \;
11 find . -name '*~' -exec rm {} \;
13 LD_LIBRARY_PATH=/usr/lib dpkg-buildpackage -rfakeroot $*