blob: 2ee81d74cf457d56309def6dde816a72a597c2f1 [file] [log] [blame]
Jiri Olsa9352aab2014-12-29 17:42:46 +01001libperf-y += abspath.o
2libperf-y += alias.o
3libperf-y += annotate.o
4libperf-y += build-id.o
5libperf-y += config.o
6libperf-y += ctype.o
7libperf-y += db-export.o
8libperf-y += environment.o
9libperf-y += event.o
10libperf-y += evlist.o
11libperf-y += evsel.o
12libperf-y += exec_cmd.o
13libperf-y += find_next_bit.o
14libperf-y += help.o
15libperf-y += kallsyms.o
16libperf-y += levenshtein.o
Wang Nanaa61fd02015-07-21 11:13:34 +000017libperf-y += llvm-utils.o
Jiri Olsa9352aab2014-12-29 17:42:46 +010018libperf-y += parse-options.o
19libperf-y += parse-events.o
20libperf-y += path.o
21libperf-y += rbtree.o
22libperf-y += bitmap.o
23libperf-y += hweight.o
24libperf-y += run-command.o
25libperf-y += quote.o
26libperf-y += strbuf.o
27libperf-y += string.o
28libperf-y += strlist.o
29libperf-y += strfilter.o
30libperf-y += top.o
31libperf-y += usage.o
32libperf-y += wrapper.o
33libperf-y += sigchain.o
34libperf-y += dso.o
35libperf-y += symbol.o
36libperf-y += color.o
37libperf-y += pager.o
38libperf-y += header.o
39libperf-y += callchain.o
40libperf-y += values.o
41libperf-y += debug.o
42libperf-y += machine.o
43libperf-y += map.o
44libperf-y += pstack.o
45libperf-y += session.o
46libperf-y += ordered-events.o
47libperf-y += comm.o
48libperf-y += thread.o
49libperf-y += thread_map.o
50libperf-y += trace-event-parse.o
51libperf-y += parse-events-flex.o
52libperf-y += parse-events-bison.o
53libperf-y += pmu.o
54libperf-y += pmu-flex.o
55libperf-y += pmu-bison.o
56libperf-y += trace-event-read.o
57libperf-y += trace-event-info.o
58libperf-y += trace-event-scripting.o
59libperf-y += trace-event.o
60libperf-y += svghelper.o
61libperf-y += sort.o
62libperf-y += hist.o
63libperf-y += util.o
64libperf-y += xyarray.o
65libperf-y += cpumap.o
66libperf-y += cgroup.o
67libperf-y += target.o
68libperf-y += rblist.o
69libperf-y += intlist.o
70libperf-y += vdso.o
71libperf-y += stat.o
Jiri Olsaf87027b2015-06-03 16:25:59 +020072libperf-y += stat-shadow.o
Jiri Olsa9352aab2014-12-29 17:42:46 +010073libperf-y += record.o
74libperf-y += srcline.o
75libperf-y += data.o
David Ahernecefde62015-02-19 13:22:33 -050076libperf-$(CONFIG_X86) += tsc.o
Jiri Olsa9352aab2014-12-29 17:42:46 +010077libperf-y += cloexec.o
78libperf-y += thread-stack.o
Adrian Huntere31f0d02015-04-30 17:37:27 +030079libperf-$(CONFIG_AUXTRACE) += auxtrace.o
Andi Kleenf00898f2015-05-27 10:51:51 -070080libperf-y += parse-branch-options.o
Jiri Olsa9352aab2014-12-29 17:42:46 +010081
Jiri Olsa709e6792014-12-29 23:52:25 +010082libperf-$(CONFIG_LIBELF) += symbol-elf.o
Masami Hiramatsu92f6c722015-07-15 18:14:07 +090083libperf-$(CONFIG_LIBELF) += probe-file.o
Jiri Olsa709e6792014-12-29 23:52:25 +010084libperf-$(CONFIG_LIBELF) += probe-event.o
85
86ifndef CONFIG_LIBELF
87libperf-y += symbol-minimal.o
88endif
89
Jiri Olsa8379fce2014-12-30 00:06:25 +010090libperf-$(CONFIG_DWARF) += probe-finder.o
91libperf-$(CONFIG_DWARF) += dwarf-aux.o
92
Jiri Olsab2e45c32014-12-30 00:11:11 +010093libperf-$(CONFIG_LIBDW_DWARF_UNWIND) += unwind-libdw.o
94libperf-$(CONFIG_LIBUNWIND) += unwind-libunwind.o
95
Jiri Olsaedbe9812015-02-20 23:17:00 +010096libperf-$(CONFIG_LIBBABELTRACE) += data-convert-bt.o
97
Jiri Olsac7355f82014-12-30 13:11:32 +010098libperf-y += scripting-engines/
99
Jiri Olsa3bc33742014-12-30 13:30:04 +0100100libperf-$(CONFIG_PERF_REGS) += perf_regs.o
Jiri Olsa1571b692014-12-30 13:31:12 +0100101libperf-$(CONFIG_ZLIB) += zlib.o
Jiri Olsa80a32e5b2015-01-29 13:29:39 +0100102libperf-$(CONFIG_LZMA) += lzma.o
Jiri Olsa3bc33742014-12-30 13:30:04 +0100103
Jiri Olsa9352aab2014-12-29 17:42:46 +0100104CFLAGS_config.o += -DETC_PERFCONFIG="BUILD_STR($(ETC_PERFCONFIG_SQ))"
105CFLAGS_exec_cmd.o += -DPERF_EXEC_PATH="BUILD_STR($(perfexecdir_SQ))" -DPREFIX="BUILD_STR($(prefix_SQ))"
106
107$(OUTPUT)util/parse-events-flex.c: util/parse-events.l $(OUTPUT)util/parse-events-bison.c
Jiri Olsa19993072014-12-30 18:44:38 +0100108 $(call rule_mkdir)
Jiri Olsa70923bd2015-05-14 12:31:48 -0300109 $(Q)$(call echo-cmd,flex)$(FLEX) -o $@ --header-file=$(OUTPUT)util/parse-events-flex.h $(PARSER_DEBUG_FLEX) util/parse-events.l
Jiri Olsa9352aab2014-12-29 17:42:46 +0100110
111$(OUTPUT)util/parse-events-bison.c: util/parse-events.y
Jiri Olsa19993072014-12-30 18:44:38 +0100112 $(call rule_mkdir)
Jiri Olsa70923bd2015-05-14 12:31:48 -0300113 $(Q)$(call echo-cmd,bison)$(BISON) -v util/parse-events.y -d $(PARSER_DEBUG_BISON) -o $@ -p parse_events_
Jiri Olsa9352aab2014-12-29 17:42:46 +0100114
115$(OUTPUT)util/pmu-flex.c: util/pmu.l $(OUTPUT)util/pmu-bison.c
Jiri Olsa19993072014-12-30 18:44:38 +0100116 $(call rule_mkdir)
Jiri Olsa70923bd2015-05-14 12:31:48 -0300117 $(Q)$(call echo-cmd,flex)$(FLEX) -o $@ --header-file=$(OUTPUT)util/pmu-flex.h util/pmu.l
Jiri Olsa9352aab2014-12-29 17:42:46 +0100118
119$(OUTPUT)util/pmu-bison.c: util/pmu.y
Jiri Olsa19993072014-12-30 18:44:38 +0100120 $(call rule_mkdir)
Jiri Olsa70923bd2015-05-14 12:31:48 -0300121 $(Q)$(call echo-cmd,bison)$(BISON) -v util/pmu.y -d -o $@ -p perf_pmu_
Jiri Olsa9352aab2014-12-29 17:42:46 +0100122
123CFLAGS_parse-events-flex.o += -w
124CFLAGS_pmu-flex.o += -w
Namhyung Kim539f3aa2015-04-29 12:55:00 -0300125CFLAGS_parse-events-bison.o += -DYYENABLE_NLS=0 -w
Jiri Olsa9352aab2014-12-29 17:42:46 +0100126CFLAGS_pmu-bison.o += -DYYENABLE_NLS=0 -DYYLTYPE_IS_TRIVIAL=0 -w
127
128$(OUTPUT)util/parse-events.o: $(OUTPUT)util/parse-events-flex.c $(OUTPUT)util/parse-events-bison.c
129$(OUTPUT)util/pmu.o: $(OUTPUT)util/pmu-flex.c $(OUTPUT)util/pmu-bison.c
130
131CFLAGS_find_next_bit.o += -Wno-unused-parameter -DETC_PERFCONFIG="BUILD_STR($(ETC_PERFCONFIG_SQ))"
132CFLAGS_rbtree.o += -Wno-unused-parameter -DETC_PERFCONFIG="BUILD_STR($(ETC_PERFCONFIG_SQ))"
133CFLAGS_hweight.o += -Wno-unused-parameter -DETC_PERFCONFIG="BUILD_STR($(ETC_PERFCONFIG_SQ))"
134CFLAGS_parse-events.o += -Wno-redundant-decls
135
136$(OUTPUT)util/kallsyms.o: ../lib/symbol/kallsyms.c FORCE
Jiri Olsa19993072014-12-30 18:44:38 +0100137 $(call rule_mkdir)
Jiri Olsa9352aab2014-12-29 17:42:46 +0100138 $(call if_changed_dep,cc_o_c)
139
140$(OUTPUT)util/find_next_bit.o: ../lib/util/find_next_bit.c FORCE
Jiri Olsa19993072014-12-30 18:44:38 +0100141 $(call rule_mkdir)
Jiri Olsa9352aab2014-12-29 17:42:46 +0100142 $(call if_changed_dep,cc_o_c)
143
Arnaldo Carvalho de Melo3f735372015-07-05 22:48:21 -0300144$(OUTPUT)util/rbtree.o: ../lib/rbtree.c FORCE
Jiri Olsa19993072014-12-30 18:44:38 +0100145 $(call rule_mkdir)
Jiri Olsa9352aab2014-12-29 17:42:46 +0100146 $(call if_changed_dep,cc_o_c)
147
Arnaldo Carvalho de Melo0aefc352015-07-09 16:27:25 -0300148$(OUTPUT)util/hweight.o: ../lib/hweight.c FORCE
Jiri Olsa19993072014-12-30 18:44:38 +0100149 $(call rule_mkdir)
Jiri Olsa9352aab2014-12-29 17:42:46 +0100150 $(call if_changed_dep,cc_o_c)