Revision 25823,
1.2 KB
checked in by jdreed, 12 years ago
(diff) |
Fix typo in stderr redirect on line 45
Use correct quoting (i.e. none) for SBUILD_EXTRA_ARGS
|
-
Property svn:executable set to
*
|
Rev | Line | |
---|
[22687] | 1 | #!/bin/sh |
---|
| 2 | |
---|
[22688] | 3 | # Wrapper around sbuild. The main purpose is to append a |
---|
| 4 | # distribution-dependent string like "~ubuntu7.10" to the binary |
---|
[24259] | 5 | # package version |
---|
[22688] | 6 | |
---|
[23072] | 7 | # This script us normally run as "da sbuildhack filename.dsc". |
---|
| 8 | |
---|
| 9 | # This script will skip dists listed in ./nobuild. |
---|
| 10 | |
---|
[22687] | 11 | usage() { |
---|
| 12 | echo "Usage: $0 <dist>-<arch> ..." >&2 |
---|
| 13 | exit 1 |
---|
| 14 | } |
---|
| 15 | |
---|
[25747] | 16 | : ${DA_SCRIPTS_DIR="$(dirname "$0")"} |
---|
| 17 | . "$DA_SCRIPTS_DIR"/debian-versions.sh |
---|
[22748] | 18 | |
---|
[22687] | 19 | dist_arch=$1; shift |
---|
| 20 | if [ -z "$dist_arch" ]; then usage; fi |
---|
| 21 | IFS=- read dist arch <<EOF |
---|
| 22 | $dist_arch |
---|
| 23 | EOF |
---|
| 24 | if [ -z "$dist" ] || [ -z "$arch" ]; then usage; fi |
---|
[23072] | 25 | |
---|
[25498] | 26 | if [ -e nobuild ] && fgrep -q "$dist" nobuild; then |
---|
| 27 | echo "Skipping $dist since it is listed in ./nobuild." |
---|
[23072] | 28 | exit |
---|
| 29 | fi |
---|
| 30 | |
---|
[25822] | 31 | SBUILD_EXTRA_ARGS= |
---|
| 32 | if [ "$DEBATHENA_PRESERVE_CHROOT" = "yes" ]; then |
---|
| 33 | SBUILD_EXTRA_ARGS="--purge=never --purge-session=never --purge-deps=never" |
---|
| 34 | fi |
---|
| 35 | |
---|
[25792] | 36 | env DEBATHENA_BUILD_DIST="$dist" \ |
---|
[24259] | 37 | sbuild --append-to-version=`gettag "$dist"` \ |
---|
| 38 | -d "$dist" --arch="$arch" \ |
---|
| 39 | --apt-update --apt-distupgrade \ |
---|
[25747] | 40 | --setup-hook="$(readlink -f "$DA_SCRIPTS_DIR/chroot-sources")" \ |
---|
[25823] | 41 | -v $SBUILD_EXTRA_ARGS "$@" |
---|
[25822] | 42 | rc=$? |
---|
| 43 | if [ "$DEBATHENA_PRESERVE_CHROOT" = "yes" ]; then |
---|
| 44 | echo "NOTE: build chroot has been preserved. Clean it up manually" >&2 |
---|
[25823] | 45 | echo "with schroot -e." >&2 |
---|
[25822] | 46 | fi |
---|
| 47 | exit $rc |
---|
Note: See
TracBrowser
for help on using the repository browser.