From patchwork Wed Jul 9 15:26:05 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Trevor Woerner X-Patchwork-Id: 33331 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f200.google.com (mail-ie0-f200.google.com [209.85.223.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id D835C208CF for ; Wed, 9 Jul 2014 15:26:15 +0000 (UTC) Received: by mail-ie0-f200.google.com with SMTP id tr6sf9618498ieb.3 for ; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=naaL0NsuyFSofJ0iS1bT6jufFVRcVPsBiXrLkkdasDE=; b=XAwg+HLoRQzQ/mIx1agwo7X0RQITg7r1mf4dDC/ElwCg59E5tF5ZzsXXIWXwaS7TXA 7t/J1ujYG+DYUhQY4sVtYb0OMMshg5H0H7fWFuYQ8XvUJmmbQR5z+RFXxLHzg+rCDKB3 okq/W4oZ1T8mj2tcfSXPBhGpOJNMRBP4JrJvw9Mwh1NV3FFOlrwfe5EuYes4YzmzuOIf w0nAokwG1X01hmpMgWEKsVlqYa2z1n71nk6mhcVYiIbNB9y0P0Tp021+AjvrN60oNUc9 +FEJcZQbpVv/QN0PDxgfU/Ih/pAUuubGHjdgvbbM79S6jC7fxP/IbPkRM1VeWWiG5GNQ z0bg== X-Gm-Message-State: ALoCoQnb64y3CYuQYue4wmG6Xc+yvdCCCGfPpGcHyXvjKV1NrJVzMywo6Y1vIgkJqRi7q6B6yLzK X-Received: by 10.42.151.67 with SMTP id d3mr9950604icw.6.1404919575413; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.25.248 with SMTP id 111ls498857qgt.45.gmail; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) X-Received: by 10.52.133.202 with SMTP id pe10mr627292vdb.78.1404919575328; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) Received: from mail-vc0-f182.google.com (mail-vc0-f182.google.com [209.85.220.182]) by mx.google.com with ESMTPS id gm6si21696614vec.75.2014.07.09.08.26.15 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 09 Jul 2014 08:26:15 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.182 as permitted sender) client-ip=209.85.220.182; Received: by mail-vc0-f182.google.com with SMTP id il7so7327073vcb.27 for ; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) X-Received: by 10.58.220.230 with SMTP id pz6mr40338735vec.9.1404919575258; Wed, 09 Jul 2014 08:26:15 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp56594vcb; Wed, 9 Jul 2014 08:26:14 -0700 (PDT) X-Received: by 10.42.210.74 with SMTP id gj10mr48516469icb.46.1404919574775; Wed, 09 Jul 2014 08:26:14 -0700 (PDT) Received: from mail-ie0-f177.google.com (mail-ie0-f177.google.com [209.85.223.177]) by mx.google.com with ESMTPS id i4si8527707igj.19.2014.07.09.08.26.14 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 09 Jul 2014 08:26:14 -0700 (PDT) Received-SPF: pass (google.com: domain of trevor.woerner@linaro.org designates 209.85.223.177 as permitted sender) client-ip=209.85.223.177; Received: by mail-ie0-f177.google.com with SMTP id tr6so1659070ieb.8 for ; Wed, 09 Jul 2014 08:26:14 -0700 (PDT) X-Received: by 10.43.79.71 with SMTP id zp7mr47308613icb.38.1404919574551; Wed, 09 Jul 2014 08:26:14 -0700 (PDT) Received: from openSUSE-i7.site (69-165-220-158.dsl.teksavvy.com. [69.165.220.158]) by mx.google.com with ESMTPSA id hu10sm16256686igb.22.2014.07.09.08.26.12 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 09 Jul 2014 08:26:14 -0700 (PDT) From: Trevor Woerner To: meta-freescale@yoctoproject.org Cc: patches@linaro.org, Otavio Salvador , Timur Aydin , Alexandre Belloni , Mario Domenech Goulart Subject: [PATCH][fsl-community-bsp-base] setup-environment: conditionally show MACHINEs Date: Wed, 9 Jul 2014 11:26:05 -0400 Message-Id: <1404919565-11014-1-git-send-email-trevor.woerner@linaro.org> X-Mailer: git-send-email 2.0.0.5.gbce14aa X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: trevor.woerner@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.182 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Before trying to show the supported MACHINEs, make sure they can be found, otherwise the error message to "ls" will be displayed (which users might find confusing). Tested on: bash, dash, zsh. Signed-off-by: Trevor Woerner --- setup-environment | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/setup-environment b/setup-environment index d3f89ce..b8787ba 100755 --- a/setup-environment +++ b/setup-environment @@ -47,13 +47,18 @@ usage() : specifies the build directory location (required) If undefined, this script will set \$MACHINE to 'imx6qsabresd'. +" + ls sources/*/conf/machine/*.conf > /dev/null 2>&1 + if [ $? -eq 0 ]; then + echo -e " Supported machines: `echo; ls sources/*/conf/machine/*.conf \ | sed s/\.conf//g | sed -r 's/^.+\///' | xargs -I% echo -e "\t%"` To build for a machine listed above, run this script as: MACHINE= source $PROGNAME " + fi } clean_up()