Index: emdebian/trunk/buildcross/trunk/buildcross =================================================================== --- emdebian/trunk/buildcross/trunk/buildcross (revision 3252) +++ emdebian/trunk/buildcross/trunk/buildcross (working copy) @@ -1,11 +1,10 @@ #!/bin/bash -# $Header: /var/emdebian/svn/tools/buildcross/branch/buildcross,v 0.3 2007/07/18 01:10:03 zumbi Exp $ # -# Copyright (C) 2000, 2007 Emdebian +# Copyright (C) 2000, 2007, 2008 Emdebian # # This program should call buildcross to build a certain outdated # package. It runs buildcross in a modular way. This program should -# check if there is a need of building a certain package. +# check if there is a need for building a certain package. # # PSEUDO CODE: # For all arches do @@ -38,26 +37,26 @@ # # Distributed under the terms of the GNU General Public License v2 -source conf_vars.sh +. conf_vars.sh if [ ! -d $LOGPATH ]; then mkdir -p $LOGPATH fi -usage(){ +usage () { echo "Usage: ${0##*/} [OPTION]" - echo "Build Debian cross toolchain system." - echo cat << EOF - -h displays this help - -v displays version number - -b no output, runs completely on background +Build Debian cross toolchain. + + -h display this help + -v display version number + -b no output, runs completely in the background WARNING: You can not stop it, just using kill. - If you are in a chroot beware proc is mounted. + If you are in a chroot then make sure proc is mounted. -c no output mode -d Show output. Recommended for first time. - Check log.html file (bug: libs always is marked as failed) + Check log.html file (bug: libs is always marked as failed) All log info is under logs/ build.log buildcross log 1-2-3.log package log @@ -68,16 +67,13 @@ } case $1 in - -h) - usage - exit 0 - ;; -v) echo "Version: 0.2" + exit 0 ;; -b) - echo "Buildcross has no output with -b option, so it runs on background." - echo "Check log.html when time is displayed" + echo "Running in the background." + echo "Check $LOGPATH/build.log" time ./em_wrap.sh &> $LOGPATH/build.log & ;; -c) @@ -86,5 +82,9 @@ -d) time ./em_wrap.sh | tee $LOGPATH/build.log ;; +*) + usage + exit 0 + ;; esac