From patchwork Wed Nov 20 04:23:57 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 292647 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id CBE022C00C5 for ; Wed, 20 Nov 2013 15:24:26 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 18DAA4A836; Wed, 20 Nov 2013 05:24:25 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id i3Sydv4ufWiT; Wed, 20 Nov 2013 05:24:24 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id DE3664A839; Wed, 20 Nov 2013 05:24:22 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 74E2E4A836 for ; Wed, 20 Nov 2013 05:24:15 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id SFmncgWoSx9C for ; Wed, 20 Nov 2013 05:24:09 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from smtp.mei.co.jp (smtp.mei.co.jp [133.183.100.20]) by theia.denx.de (Postfix) with ESMTP id B6C804A7F2 for ; Wed, 20 Nov 2013 05:24:02 +0100 (CET) Received: from mail-gw.jp.panasonic.com ([157.8.1.157]) by smtp.mei.co.jp (8.12.11.20060614/3.7W/kc-maile13) with ESMTP id rAK4Nx9j024708 for ; Wed, 20 Nov 2013 13:24:00 +0900 (JST) Received: from epochmail.jp.panasonic.com ([157.8.1.130]) by mail.jp.panasonic.com (8.11.6p2/3.7W/kc-maili11) with ESMTP id rAK4NxR06646 for ; Wed, 20 Nov 2013 13:23:59 +0900 Received: by epochmail.jp.panasonic.com (8.12.11.20060308/3.7W/lomi11) id rAK4NxQg018041; Wed, 20 Nov 2013 13:23:59 +0900 Received: from poodle by lomi11.jp.panasonic.com (8.12.11.20060308/3.7W) with ESMTP id rAK4NxwT018022; Wed, 20 Nov 2013 13:23:59 +0900 Received: from beagle.diag.org (beagle.diag.org [10.184.179.16]) by poodle (Postfix) with ESMTP id 7A0052740043; Wed, 20 Nov 2013 13:23:59 +0900 (JST) From: Masahiro Yamada To: u-boot@lists.denx.de Date: Wed, 20 Nov 2013 13:23:57 +0900 Message-Id: <1384921437-14132-1-git-send-email-yamada.m@jp.panasonic.com> X-Mailer: git-send-email 1.8.3.2 Subject: [U-Boot] [PATCH] MAKEALL: add -b (--board) option X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Some board have multiple configurations. For example, the board "m54455evb" has many configurations: M54455EVB, M54455EVB_a66, M54455EVB_i66, M54455EVB_intel, ... When we modify board-related files, we need to test all configurations based on such a board. In such a case, the new option -b is usefull. Signed-off-by: Masahiro Yamada --- MAKEALL | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/MAKEALL b/MAKEALL index 80cd4f8..a74f0fc 100755 --- a/MAKEALL +++ b/MAKEALL @@ -18,6 +18,7 @@ usage() -c CPU, --cpu CPU Build all boards with cpu CPU -v VENDOR, --vendor VENDOR Build all boards with vendor VENDOR -s SOC, --soc SOC Build all boards with soc SOC + -b BOARD, --board BOARD Build all boards with board name BOARD -l, --list List all targets to be built -m, --maintainers List all targets and maintainer email -M, --mails List all targets and all affilated emails @@ -59,8 +60,8 @@ usage() exit ${ret} } -SHORT_OPTS="ha:c:v:s:lmMCnr" -LONG_OPTS="help,arch:,cpu:,vendor:,soc:,list,maintainers,mails,check,continue,rebuild-errors" +SHORT_OPTS="ha:c:v:s:b:lmMCnr" +LONG_OPTS="help,arch:,cpu:,vendor:,soc:,board:,list,maintainers,mails,check,continue,rebuild-errors" # Option processing based on util-linux-2.13/getopt-parse.bash @@ -121,6 +122,17 @@ while true ; do fi SELECTED='y' shift 2 ;; + -b|--board) + # echo "Option BOARD: argument \`$2'" + if [ "$opt_b" ] ; then + opt_b="${opt_b%)} || \$6 == \"$2\" || \$7 == \"$2\")" + else + # We need to check the 7th field too + # for boards whose 6th field is "-" + opt_b="(\$6 == \"$2\" || \$7 == \"$2\")" + fi + SELECTED='y' + shift 2 ;; -C|--check) CHECK='C=1' shift ;; @@ -158,6 +170,7 @@ FILTER="\$1 !~ /^#/" [ "$opt_c" ] && FILTER="${FILTER} && $opt_c" [ "$opt_s" ] && FILTER="${FILTER} && $opt_s" [ "$opt_v" ] && FILTER="${FILTER} && $opt_v" +[ "$opt_b" ] && FILTER="${FILTER} && $opt_b" if [ "$SELECTED" ] ; then SELECTED=$(awk '('"$FILTER"') { print $7 }' boards.cfg)