From patchwork Thu Jul 18 21:24:15 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yann E. MORIN" X-Patchwork-Id: 260160 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id DDC9C2C0077 for ; Fri, 19 Jul 2013 07:24:56 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 5E8AF9D857; Thu, 18 Jul 2013 21:24:50 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ESbPO8q5VT1s; Thu, 18 Jul 2013 21:24:48 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 2E69F9D40F; Thu, 18 Jul 2013 21:24:47 +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 168711BF9B4 for ; Thu, 18 Jul 2013 21:24:36 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 3F74982D15 for ; Thu, 18 Jul 2013 21:24:29 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HRCO8J1Frxg4 for ; Thu, 18 Jul 2013 21:24:28 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wg0-f42.google.com (mail-wg0-f42.google.com [74.125.82.42]) by whitealder.osuosl.org (Postfix) with ESMTPS id 96F1381480 for ; Thu, 18 Jul 2013 21:24:28 +0000 (UTC) Received: by mail-wg0-f42.google.com with SMTP id z11so1146463wgg.3 for ; Thu, 18 Jul 2013 14:24:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:in-reply-to:references; bh=8Yq7VL5rBIcw7SoQK4eoG/bTu+D8dAMU+7VnKQ0w9fQ=; b=R6CDeqYjXZ3b37PIOlTMgNE19YxjX31mbLTENFLEhU+1lIvDEnUV1u2KYZ+LaiPKel ArfRs+spYGXN8tOTtJkFfuB4ohUQW5rzj/QWyDyg4dKQ9hjUFnnvds0dMr7sYo6DvzQw kv0glzXAWWm+CmJF8afciBAqWC2WzwlGlOkeoofQMNF5wt6AnDxbfkf2xyYzMQ9yzUNW CAcPQHTCir6K+gRkqMAvXDuauQ0oOILAApYf+wYZfkmX9WY89s+99C5pN8+bDwzZ3R6L QhktZKeRPspK+f+8FSzQFBsnQ54DIDz7m3WyLPQYf58tZ+o8kyGeBPsuaDQQCszOJJBF zx+Q== X-Received: by 10.180.183.180 with SMTP id en20mr20295652wic.58.1374182666828; Thu, 18 Jul 2013 14:24:26 -0700 (PDT) Received: from gourin.bzh.lan (ks3095497.kimsufi.com. [94.23.60.27]) by mx.google.com with ESMTPSA id fb9sm44579649wid.2.2013.07.18.14.24.25 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 18 Jul 2013 14:24:26 -0700 (PDT) From: "Yann E. MORIN" To: buildroot@busybox.net Date: Thu, 18 Jul 2013 23:24:15 +0200 Message-Id: <574ef0eb7e941dcc6c9dba3540f4aa1c213472bc.1374182572.git.yann.morin.1998@free.fr> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: References: In-Reply-To: References: Cc: "Yann E. MORIN" Subject: [Buildroot] [PATCH 4/4] toolchain: instrument external toolchain wrapper 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 From: "Yann E. MORIN" If BR_DEBUG_WRAPPER is set in the envirnment, dump the actual command being exec()uted, to ease debugging issues with the wrapper. Signed-off-by: "Yann E. MORIN" --- toolchain/toolchain-external/ext-toolchain-wrapper.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/toolchain/toolchain-external/ext-toolchain-wrapper.c b/toolchain/toolchain-external/ext-toolchain-wrapper.c index 460f255..8e56414 100644 --- a/toolchain/toolchain-external/ext-toolchain-wrapper.c +++ b/toolchain/toolchain-external/ext-toolchain-wrapper.c @@ -136,6 +136,14 @@ int main(int argc, char **argv) /* finish with NULL termination */ *cur = NULL; + if( getenv("BR_DEBUG_WRAPPER") ) { + fprintf( stderr, "path='%s'\n", path ); + int i; + for( i=0; args[i]; i++ ) { + fprintf(stderr, "argv[%d]='%s'\n", i, args[i] ); + } + } + if (execv(path, args)) perror(path);