abuild: fail with dignity if mainboard does not exist.
authorStefan Reinauer <stepan@coresystems.de>
Mon, 29 Mar 2010 16:23:42 +0000 (16:23 +0000)
committerStefan Reinauer <stepan@openbios.org>
Mon, 29 Mar 2010 16:23:42 +0000 (16:23 +0000)
Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Stefan Reinauer <stepan@coresystems.de>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5312 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1

util/abuild/abuild

index fbb801ec8288309271d8aac9d26f2d3527baa9da..6c32cacead5cffc40e1f82cc2e1674baac405009 100755 (executable)
@@ -590,6 +590,11 @@ if [ "$target" != "" ]; then
        VENDOR=`printf $target|cut -f1 -d/`
        MAINBOARD=`printf $target|cut -f2 -d/`
        CONFIG=`printf $target|cut -f3 -d/`
+       if [ ! -r $ROOT/src/mainboard/$target ]; then
+               printf "No such target: $target\n"
+               xml '</abuild>'
+               exit 1
+       fi
        build_target $VENDOR $MAINBOARD $CONFIG
        test_target $VENDOR $MAINBOARD
 else