aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/Makefile
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2009-07-01 11:28:37 -0400
committerIngo Molnar <mingo@elte.hu>2009-07-01 16:37:22 -0400
commit43cbcd8acb4c992cbd22d1ec8a08c0591be5d719 (patch)
tree38bd75deba4635ee6fe38bb0dcff1a76db872189 /tools/perf/Makefile
parent73c24cb86c51ff6445b292d9914d31236204393b (diff)
perf_counter tools: Share rbtree.with the kernel
The tools/perf/util/rbtree.c copy already drifted by three csets: 4b324126e0c6c3a5080ca3ec0981e8766ed6f1ee 4c60117811171d867d4f27f17ea07d7419d45dae 16c047add3ceaf0ab882e3e094d1ec904d02312d So remove the copy and use the lib/rbtree.c directly, sharing the source code while still generating a separate object file, since tools/perf uses a far more agressive -O6 switch. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> LKML-Reference: <20090701152837.GG15682@ghostprotocols.net> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/Makefile')
-rw-r--r--tools/perf/Makefile7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/perf/Makefile b/tools/perf/Makefile
index eddf076b19d7..c4f48825a6eb 100644
--- a/tools/perf/Makefile
+++ b/tools/perf/Makefile
@@ -223,7 +223,7 @@ SPARSE_FLAGS = -D__BIG_ENDIAN__ -D__powerpc__
223# Those must not be GNU-specific; they are shared with perl/ which may 223# Those must not be GNU-specific; they are shared with perl/ which may
224# be built by a different compiler. (Note that this is an artifact now 224# be built by a different compiler. (Note that this is an artifact now
225# but it still might be nice to keep that distinction.) 225# but it still might be nice to keep that distinction.)
226BASIC_CFLAGS = 226BASIC_CFLAGS = -Iutil/include
227BASIC_LDFLAGS = 227BASIC_LDFLAGS =
228 228
229# Guard against environment variables 229# Guard against environment variables
@@ -289,10 +289,10 @@ export PERL_PATH
289LIB_FILE=libperf.a 289LIB_FILE=libperf.a
290 290
291LIB_H += ../../include/linux/perf_counter.h 291LIB_H += ../../include/linux/perf_counter.h
292LIB_H += ../../include/linux/rbtree.h
292LIB_H += perf.h 293LIB_H += perf.h
293LIB_H += util/types.h 294LIB_H += util/types.h
294LIB_H += util/list.h 295LIB_H += util/list.h
295LIB_H += util/rbtree.h
296LIB_H += util/levenshtein.h 296LIB_H += util/levenshtein.h
297LIB_H += util/parse-options.h 297LIB_H += util/parse-options.h
298LIB_H += util/parse-events.h 298LIB_H += util/parse-events.h
@@ -691,6 +691,9 @@ builtin-init-db.o: builtin-init-db.c PERF-CFLAGS
691util/config.o: util/config.c PERF-CFLAGS 691util/config.o: util/config.c PERF-CFLAGS
692 $(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) -DETC_PERFCONFIG='"$(ETC_PERFCONFIG_SQ)"' $< 692 $(QUIET_CC)$(CC) -o $*.o -c $(ALL_CFLAGS) -DETC_PERFCONFIG='"$(ETC_PERFCONFIG_SQ)"' $<
693 693
694util/rbtree.o: ../../lib/rbtree.c PERF-CFLAGS
695 $(QUIET_CC)$(CC) -o util/rbtree.o -c $(ALL_CFLAGS) -DETC_PERFCONFIG='"$(ETC_PERFCONFIG_SQ)"' $<
696
694perf-%$X: %.o $(PERFLIBS) 697perf-%$X: %.o $(PERFLIBS)
695 $(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) $(LIBS) 698 $(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) $(LIBS)
696 699