]> git.kernelconcepts.de Git - karo-tx-redboot.git/blobdiff - build.sh
karo: tx51: update ReleaseNotes.txt
[karo-tx-redboot.git] / build.sh
index b09c9afa451447ee668a735a4bdeaa60de23ab29..eca1640393ba18c56fe33e9c06aaf3569834b148 100644 (file)
--- a/build.sh
+++ b/build.sh
@@ -1,5 +1,5 @@
 #!/bin/bash
-options="cnqrR"
+options="cnqrRp:"
 release=false
 tools_dir="$PWD/tools/bin"
 ecosconfig="$tools_dir/tools/configtool/standalone/common/ecosconfig"
@@ -9,11 +9,14 @@ clean=false
 rebuild=false
 doit=true
 make_opts=
+pattern="*"
 
 error() {
+    rc=$?
     if [ -n "${target}" ];then
        echo "${target} build aborted"
     fi
+    return $rc
 }
 
 build_host_tools() {
@@ -56,6 +59,9 @@ while getopts "$options" opt;do
            doit=false
            make_opts="${make_opts} -n"
            ;;
+       p)
+           pattern="$OPTARG"
+           ;;
        q)
            quiet=true
            ;;
@@ -78,7 +84,7 @@ shift $(($OPTIND - 1))
 if [ $# -gt 0 ];then
     targets="$@"
 else
-    targets=$(cd config;ls *.ecc)
+    targets=$(cd config;ls $pattern.ecc)
 fi
 
 set -e