From patchwork Sun Aug 12 20:27:07 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yann E. MORIN" X-Patchwork-Id: 176803 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from silver.osuosl.org (silver.osuosl.org [140.211.166.136]) by ozlabs.org (Postfix) with ESMTP id 959832C0091 for ; Mon, 13 Aug 2012 06:27:22 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id AB42E24F7E; Sun, 12 Aug 2012 20:27:19 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KTpJO-mwuX4K; Sun, 12 Aug 2012 20:27:17 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 081BA24CAC; Sun, 12 Aug 2012 20:27:17 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 1AF048F753 for ; Sun, 12 Aug 2012 20:27:15 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id D63B48E154 for ; Sun, 12 Aug 2012 20:27:14 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OHppBPuFo2E0 for ; Sun, 12 Aug 2012 20:27:11 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from smtp.smtpout.orange.fr (smtp04.smtpout.orange.fr [80.12.242.126]) by whitealder.osuosl.org (Postfix) with ESMTP id DBF138E175 for ; Sun, 12 Aug 2012 20:27:10 +0000 (UTC) Received: from treguer.bzh.lan ([90.32.165.248]) by mwinf5d51 with ME id lwT71j00X5MspoA03wT8TC; Sun, 12 Aug 2012 22:27:09 +0200 From: "Yann E. MORIN" To: buildroot@busybox.net Date: Sun, 12 Aug 2012 22:27:07 +0200 Message-Id: <1344803227-9472-1-git-send-email-yann.morin.1998@free.fr> X-Mailer: git-send-email 1.7.2.5 Cc: Thomas Petazzoni , "Yann E. MORIN" Subject: [Buildroot] [PATCH] support/graph-depends: fix out-of-tree usage X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net graph-depends calls make to get the list of packages, and the dependencies of each package. When called out-of-tree, the Makefile is a wrapper that calls the real Makefile, so make will spit out a line like: make -C /path/to/buildroot O=/path/to/build-dir show-targets which graph-depends wrongly believes is part of the target list. Be silent when calling make, as we really only want the target and dependency lists. Signed-off-by: "Yann E. MORIN" --- Note we do not silence the Makefile wrapper, because it can be usefull to see what buildroot dir is being used during the build. For example, I happen to have a few buildroot clones, and seeing the one being actually being used allows me to be sure I am not using the wrong once. --- support/scripts/graph-depends | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/support/scripts/graph-depends b/support/scripts/graph-depends index da050da..409c123 100755 --- a/support/scripts/graph-depends +++ b/support/scripts/graph-depends @@ -53,7 +53,7 @@ unknownpkgs = [] # list is used as the starting point for full dependency graphs def get_targets(): sys.stderr.write("Getting targets\n") - cmd = ["make", "show-targets"] + cmd = ["make", "-s", "show-targets"] p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) output = p.communicate()[0].strip() if p.returncode != 0: @@ -67,7 +67,7 @@ def get_targets(): # formatted as a Python list. def get_depends(pkg): sys.stderr.write("Getting dependencies for %s\n" % pkg) - cmd = ["make", "%s-show-depends" % pkg] + cmd = ["make", "-s", "%s-show-depends" % pkg] p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) output = p.communicate()[0].strip() if p.returncode != 0: