public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] tools: unbreak 'make tools/*'
@ 2015-01-29  4:47 Brian Norris
  2015-02-02 23:43 ` Brian Norris
  2015-03-19 13:39 ` Arnaldo Carvalho de Melo
  0 siblings, 2 replies; 6+ messages in thread
From: Brian Norris @ 2015-01-29  4:47 UTC (permalink / raw)
  To: Michal Marek
  Cc: linux-kernel, linux-kbuild, Brian Norris, David Howells,
	Borislav Petkov, Arnaldo Carvalho de Melo, Sam Ravnborg

The following targets should be supported from the top-level source
directory, but were broken by commit 7e1c04779efd ("kbuild: Use relative
path for $(objtree)"):

 $ make tools/
 $ make tools/perf
 $ make O=$(BUILDDIR) tools/perf

The tools/ and tools/% targets are passing the top-level build directory
as an O= argument, so we need a full path, not a relative one, as the
$(O) variable will be reinterpreted by the sub-makefile.

Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Cc: Michal Marek <mmarek@suse.cz>
---
 Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 95a0e827ecd3..59033c8bf93a 100644
--- a/Makefile
+++ b/Makefile
@@ -1496,11 +1496,11 @@ image_name:
 # Clear a bunch of variables before executing the submake
 tools/: FORCE
 	$(Q)mkdir -p $(objtree)/tools
-	$(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/
+	$(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(CURDIR) subdir=tools -C $(src)/tools/
 
 tools/%: FORCE
 	$(Q)mkdir -p $(objtree)/tools
-	$(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(objtree) subdir=tools -C $(src)/tools/ $*
+	$(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(CURDIR) subdir=tools -C $(src)/tools/ $*
 
 # Single targets
 # ---------------------------------------------------------------------------
-- 
2.3.0.rc1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-03-19 16:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-29  4:47 [PATCH] tools: unbreak 'make tools/*' Brian Norris
2015-02-02 23:43 ` Brian Norris
2015-02-03  0:07   ` Arnaldo Carvalho de Melo
2015-03-19 13:39 ` Arnaldo Carvalho de Melo
2015-03-19 14:20   ` Jiri Olsa
2015-03-19 16:11     ` Brian Norris

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox