[ooo-build-commit] bin/tinbuild
Jan Holesovsky
kendy at kemper.freedesktop.org
Wed Dec 16 12:30:46 PST 2009
bin/tinbuild | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
New commits:
commit 79dd9a9f4f481139b9aaa09f3cd2169cba4cd9f7
Author: Jan Holesovsky <kendy at suse.cz>
Date: Wed Dec 16 21:20:32 2009 +0100
Add -i (for ionice) and -n (for nice) to allow builds on background.
* bin/tinbuild: ionice/nice
diff --git a/bin/tinbuild b/bin/tinbuild
index 73e1da2..f5553f1 100755
--- a/bin/tinbuild
+++ b/bin/tinbuild
@@ -4,6 +4,7 @@
PAUSE_SECONDS=$((15*60))
HTML_OUTPUT=0
SEND_MAIL=0
+NICE=
## subroutines
usage ()
@@ -11,8 +12,10 @@ usage ()
echo "Usage: $0 [options]"
echo "Options:"
echo "-w <N> specify timeout in secs between subsequent pull requests"
+ echo "-i when given: run with ionice -c3, can be combined with -n"
echo "-l when given: write html build log"
echo "-m when given: mail errors to last committer"
+ echo "-n when given: run with nice, can be combined with -i"
echo "-h this help"
}
@@ -30,11 +33,13 @@ reportError ()
}
## code
-while getopts w:lmh opt ; do
+while getopts w:ilmnh opt ; do
case "$opt" in
w) PAUSE_SECONDS="$OPTARG" ;;
+ i) NICE="$NICE ionice -c3"
l) HTML_OUTPUT=1 ;;
m) SEND_MAIL=1 ;;
+ n) NICE="$NICE nice"
h) usage; exit ;;
?) usage; exit ;;
esac
@@ -51,14 +56,14 @@ while true; do
err_msg=""
# cleanup
- make clean-local
+ $NICE make clean-local
# try to build
if ! err_msg=$(./autogen.sh 2>&1); then
reportError "autogen.sh / configure failed - error is:" $'\n' "$err_msg"
elif ! err_msg=$(./download 2>&1); then
reportError "download failed - error is:" $'\n' "$err_msg"
- elif ! make dev-install >build.log 2>&1 ; then
+ elif ! $NICE make dev-install >build.log 2>&1 ; then
reportError "building failed - error is:" $'\n' $(tail -n50 build.log)
else
echo build done
More information about the ooo-build-commit
mailing list