tools lib traceevent: Use global 'O' processing code
authorJiri Olsa <[email protected]>
Thu, 19 Dec 2013 13:42:07 +0000 (14:42 +0100)
committerArnaldo Carvalho de Melo <[email protected]>
Thu, 19 Dec 2013 19:18:12 +0000 (16:18 -0300)
Using global 'O' processing code because it's already setup due to the
scripts/Makefile.include include.

Using global variable OUTPUT instead of the local BUILD_OUTPUT.

Signed-off-by: Jiri Olsa <[email protected]>
Cc: Corey Ashford <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Steven Rostedt <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/lib/traceevent/Makefile

index 3496c9ce84d4c6661b038aa5bc2cd407c797fb08..ca4ab78425d13e36eb06b4382786e027a737c7fc 100644 (file)
@@ -83,18 +83,13 @@ ifeq ("$(origin O)", "command line")
 endif
 
 ifeq ($(BUILD_SRC),)
-ifneq ($(BUILD_OUTPUT),)
+ifneq ($(OUTPUT),)
 
 define build_output
-       $(if $(VERBOSE:1=),@)+$(MAKE) -C $(BUILD_OUTPUT)        \
-       BUILD_SRC=$(CURDIR) -f $(CURDIR)/Makefile $1
+       $(if $(VERBOSE:1=),@)+$(MAKE) -C $(OUTPUT) \
+       BUILD_SRC=$(CURDIR)/ -f $(CURDIR)/Makefile $1
 endef
 
-saved-output := $(BUILD_OUTPUT)
-BUILD_OUTPUT := $(shell cd $(BUILD_OUTPUT) && /bin/pwd)
-$(if $(BUILD_OUTPUT),, \
-     $(error output directory "$(saved-output)" does not exist))
-
 all: sub-make
 
 $(MAKECMDGOALS): sub-make
@@ -106,7 +101,7 @@ sub-make: force
 # Leave processing to above invocation of make
 skip-makefile := 1
 
-endif # BUILD_OUTPUT
+endif # OUTPUT
 endif # BUILD_SRC
 
 # We process the rest of the Makefile if this is the final invocation of make