From patchwork Mon Sep 27 02:11:12 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: matt mooney X-Patchwork-Id: 210572 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o8R2Caqd026962 for ; Mon, 27 Sep 2010 02:12:36 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758706Ab0I0CMf (ORCPT ); Sun, 26 Sep 2010 22:12:35 -0400 Received: from qmta11.emeryville.ca.mail.comcast.net ([76.96.27.211]:37558 "EHLO qmta11.emeryville.ca.mail.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758702Ab0I0CMf (ORCPT ); Sun, 26 Sep 2010 22:12:35 -0400 Received: from omta13.emeryville.ca.mail.comcast.net ([76.96.30.52]) by qmta11.emeryville.ca.mail.comcast.net with comcast id BbXM1f00417UAYkABeCbSD; Mon, 27 Sep 2010 02:12:35 +0000 Received: from haskell.muteddisk.com ([98.239.78.58]) by omta13.emeryville.ca.mail.comcast.net with comcast id BeCa1f00F1FUwZe8ZeCalS; Mon, 27 Sep 2010 02:12:34 +0000 Received: by haskell.muteddisk.com (Postfix, from userid 1000) id BFE5C412AD; Sun, 26 Sep 2010 19:11:22 -0700 (PDT) From: matt mooney To: Michal Marek Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH] kbuild: remove duplicate -I flag in addtree Date: Sun, 26 Sep 2010 19:11:12 -0700 Message-Id: <1285553472-924-1-git-send-email-mfm@muteddisk.com> X-Mailer: git-send-email 1.6.4.2 Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 27 Sep 2010 02:12:36 +0000 (UTC) diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include index ed2773e..08c74ed 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include @@ -158,7 +158,7 @@ modbuiltin := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.modbuiltin obj # Prefix -I with $(srctree) if it is not an absolute path. # skip if -I has no parameter addtree = $(if $(patsubst -I%,%,$(1)), \ -$(if $(filter-out -I/%,$(1)),$(patsubst -I%,-I$(srctree)/%,$(1))) $(1)) +$(if $(filter-out -I/%,$(1)),$(patsubst -I%,-I$(srctree)/%,$(1)),$(1))) # Find all -I options and call addtree flags = $(foreach o,$($(1)),$(if $(filter -I%,$(o)),$(call addtree,$(o)),$(o)))