* gas/mips/elf-rel6.d, gas/mips/elf-rel6.s: Extend testcase.
[binutils.git] / gprof / Makefile.am
blob4e2c88c08cf8d6fdb763bad154a6febf3e5d5e9b
1 ## Process this file with automake to generate Makefile.in
3 AUTOMAKE_OPTIONS = cygnus
5 SUFFIXES = .m
7 SUBDIRS = po
9 BASEDIR = $(srcdir)/..
10 BFDDIR = $(BASEDIR)/bfd
11 INCDIR  = $(BASEDIR)/include
13 WARN_CFLAGS = @WARN_CFLAGS@
14 NO_WERROR = @NO_WERROR@
15 AM_CFLAGS = $(WARN_CFLAGS)
17 MKDEP = gcc -MM
19 INCLUDES = -D_GNU_SOURCE -DDEBUG -I../bfd -I$(srcdir)/../include -I$(srcdir)/../bfd @INCINTL@ -I. -DLOCALEDIR="\"$(datadir)/locale\""
21 bin_PROGRAMS = gprof
23 ## Convenience var listing pure sources.
24 sources = basic_blocks.c call_graph.c cg_arcs.c cg_dfn.c \
25         cg_print.c corefile.c gmon_io.c gprof.c hertz.c hist.c source.c \
26         search_list.c symtab.c sym_ids.c utils.c \
27         i386.c alpha.c vax.c tahoe.c sparc.c mips.c
28 gprof_SOURCES = $(sources) flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
29 gprof_DEPENDENCIES = ../bfd/libbfd.la ../libiberty/libiberty.a $(LIBINTL_DEP)
30 gprof_LDADD = ../bfd/libbfd.la ../libiberty/libiberty.a $(LIBINTL)
32 noinst_HEADERS = \
33         basic_blocks.h call_graph.h cg_arcs.h cg_dfn.h cg_print.h \
34         corefile.h gmon.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
35         search_list.h source.h sym_ids.h symtab.h utils.h
37 BUILT_SOURCES = flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
38 EXTRA_DIST    = $(BUILT_SOURCES) bbconv.pl $(man_MANS)
40 diststuff: $(BUILT_SOURCES) info $(man_MANS)
42 # This empty rule is a hack against gmake patched by Apple.
43 %.o:%.m
45 .m.c:
46         awk -f $(srcdir)/gen-c-prog.awk > ./$*.c \
47             FUNCTION=`(echo $*|sed -e 's,.*/,,g' -e 's/_bl//')`_blurb \
48             FILE=$*.m $(srcdir)/$*.m
50 POTFILES = $(sources) $(noinst_HEADERS)
51 po/POTFILES.in: @MAINT@ Makefile
52         for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
53           && mv tmp $(srcdir)/po/POTFILES.in
55 MANCONF  = -Dman
57 TEXI2POD = perl $(srcdir)/../etc/texi2pod.pl
59 POD2MAN = pod2man --center="GNU" --release="binutils-$(VERSION)" --section=1
61 info_TEXINFOS = gprof.texi
62 man_MANS = gprof.1
64 $(srcdir)/gprof.info: gprof.texi config.texi
66 config.texi:
67         echo "@set top_srcdir $(top_srcdir)" >> ./config.texi
69 # Build the man page from the texinfo file
70 # The sed command removes the no-adjust Nroff command so that
71 # the man output looks standard.
72 gprof.1: $(srcdir)/gprof.texi config.texi
73         touch $@
74         -$(TEXI2POD) $(MANCONF) -Dgprof < $(srcdir)/gprof.texi > gprof.pod
75         -($(POD2MAN) gprof.pod | \
76                sed -e '/^.if n .na/d' > $@.T$$$$ && \
77                mv -f $@.T$$$$ $@) || \
78                (rm -f $@.T$$$$ && exit 1)
79         rm -f gprof.pod
81 .PHONY: install-html install-html-am install-html-recursive
83 html__strip_dir = `echo $$p | sed -e 's|^.*/||'`;
85 install-html: install-html-recursive  install-html-am
87 install-html-am: $(HTMLS)
88         @$(NORMAL_INSTALL)
89         test -z "$(htmldir)" || $(mkdir_p) "$(DESTDIR)$(htmldir)"
90         @list='$(HTMLS)'; for p in $$list; do \
91           if test -f "$$p" || test -d "$$p"; then d=""; else d="$(srcdir)/"; fi; \
92           f=$(html__strip_dir) \
93           if test -d "$$d$$p"; then \
94             echo " $(mkdir_p) '$(DESTDIR)$(htmldir)/$$f'"; \
95             $(mkdir_p) "$(DESTDIR)$(htmldir)/$$f" || exit 1; \
96             echo " $(INSTALL_DATA) '$$d$$p'/* '$(DESTDIR)$(htmldir)/$$f'"; \
97             $(INSTALL_DATA) "$$d$$p"/* "$(DESTDIR)$(htmldir)/$$f"; \
98           else \
99             echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)/$$f'"; \
100             $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/$$f"; \
101           fi; \
102         done
104 install-html-recursive:
105         @failcom='exit 1'; \
106         for f in x $$MAKEFLAGS; do \
107           case $$f in \
108             *=* | --[!k]*);; \
109             *k*) failcom='fail=yes';; \
110           esac; \
111         done; \
112         dot_seen=no; \
113         target=`echo $@ | sed s/-recursive//`; \
114         list='$(SUBDIRS)'; for subdir in $$list; do \
115           echo "Making $$target in $$subdir"; \
116           if test "$$subdir" = "."; then \
117             dot_seen=yes; \
118             local_target="$$target-am"; \
119           else \
120             local_target="$$target"; \
121           fi; \
122           (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
123           || eval $$failcom; \
124         done; \
125         if test "$$dot_seen" = "no"; then \
126           $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
127         fi; test -z "$$fail"
129 # We want install to imply install-info as per GNU standards, despite the
130 # cygnus option.
131 install-data-local: install-info
133 # Targets to rebuild dependencies in this Makefile.
134 # Have to get rid of DEP1 here so that "$?" later includes all sources.
135 DEP: dep.sed $(gprof_SOURCES) $(noinst_HEADERS) gconfig.h
136         rm -f DEP1
137         $(MAKE) MKDEP="$(MKDEP)" DEP1
138         sed -f dep.sed < DEP1 > DEPA
139         echo '# IF YOU PUT ANYTHING HERE IT WILL GO AWAY' >> DEPA
140         if grep ' /' DEPA > /dev/null 2> /dev/null; then \
141           echo 'make DEP failed!'; exit 1; \
142         else \
143           mv -f DEPA $@; \
144         fi
146 DEP1: $(gprof_SOURCES)
147         echo '# DO NOT DELETE THIS LINE -- mkdep uses it.' > DEP2
148         echo '# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.' >> DEP2
149         $(MKDEP) $(INCLUDES) $(CFLAGS) $? >> DEP2
150         mv -f DEP2 $@
152 dep.sed: dep-in.sed config.status
153         objdir=`pwd`; \
154         sed <$(srcdir)/dep-in.sed >dep.sed      \
155                 -e 's!@INCDIR@!$(INCDIR)!'      \
156                 -e 's!@BFDDIR@!$(BFDDIR)!'      \
157                 -e 's!@SRCDIR@!$(srcdir)!'      \
158                 -e "s!@OBJDIR@!$${objdir}!"     \
159                 -e 's!@TOPDIR@!'`echo $(srcdir) | sed -e s,/gprof$$,,`'!'
161 dep: DEP
162         sed -e '/^..DO NOT DELETE THIS LINE/,$$d' < Makefile > tmp-Makefile
163         cat DEP >> tmp-Makefile
164         $(SHELL) $(srcdir)/../move-if-change tmp-Makefile Makefile
166 dep-in: DEP
167         sed -e '/^..DO NOT DELETE THIS LINE/,$$d' < $(srcdir)/Makefile.in > tmp-Makefile.in
168         cat DEP >> tmp-Makefile.in
169         $(SHELL) $(srcdir)/../move-if-change tmp-Makefile.in $(srcdir)/Makefile.in
171 dep-am: DEP
172         sed -e '/^..DO NOT DELETE THIS LINE/,$$d' < $(srcdir)/Makefile.am > tmp-Makefile.am
173         cat DEP >> tmp-Makefile.am
174         $(SHELL) $(srcdir)/../move-if-change tmp-Makefile.am $(srcdir)/Makefile.am
176 .PHONY: dep dep-in dep-am
178 CLEANFILES = dep.sed DEP DEPA DEP1 DEP2
180 # DO NOT DELETE THIS LINE -- mkdep uses it.
181 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
182 basic_blocks.o: basic_blocks.c $(INCDIR)/libiberty.h \
183   $(INCDIR)/ansidecl.h gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h \
184   $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h ../bfd/bfd.h \
185   $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h basic_blocks.h \
186   corefile.h gmon_io.h gmon_out.h search_list.h source.h \
187   symtab.h sym_ids.h
188 call_graph.o: call_graph.c gprof.h $(BFDDIR)/sysdep.h \
189   $(INCDIR)/ansidecl.h ../bfd/config.h $(INCDIR)/fopen-same.h \
190   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
191   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
192   symtab.h cg_arcs.h call_graph.h corefile.h gmon_io.h \
193   gmon_out.h sym_ids.h
194 cg_arcs.o: cg_arcs.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
195   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
196   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
197   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
198   symtab.h call_graph.h cg_arcs.h cg_dfn.h cg_print.h \
199   utils.h sym_ids.h
200 cg_dfn.o: cg_dfn.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
201   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
202   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
203   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
204   symtab.h cg_arcs.h cg_dfn.h utils.h
205 cg_print.o: cg_print.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
206   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
207   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
208   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
209   symtab.h cg_arcs.h cg_print.h hist.h utils.h corefile.h
210 corefile.o: corefile.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
211   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
212   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
213   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
214   symtab.h corefile.h
215 gmon_io.o: gmon_io.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
216   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
217   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
218   search_list.h source.h symtab.h cg_arcs.h basic_blocks.h \
219   corefile.h call_graph.h gmon_io.h gmon_out.h gmon.h \
220   hertz.h hist.h $(INCDIR)/libiberty.h
221 gprof.o: gprof.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
222   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
223   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
224   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
225   symtab.h basic_blocks.h call_graph.h cg_arcs.h cg_print.h \
226   corefile.h gmon_io.h hertz.h hist.h sym_ids.h $(INCDIR)/demangle.h
227 hertz.o: hertz.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
228   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
229   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
230   hertz.h
231 hist.o: hist.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
232   gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h $(INCDIR)/fopen-same.h \
233   $(INCDIR)/filenames.h ../bfd/bfd.h $(INCDIR)/symcat.h \
234   gconfig.h $(INCDIR)/bin-bugs.h search_list.h source.h \
235   symtab.h corefile.h gmon_io.h gmon_out.h hist.h sym_ids.h \
236   utils.h
237 source.o: source.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
238   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
239   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
240   $(INCDIR)/libiberty.h search_list.h source.h
241 search_list.o: search_list.c $(INCDIR)/libiberty.h \
242   $(INCDIR)/ansidecl.h gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h \
243   $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h ../bfd/bfd.h \
244   $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h search_list.h
245 symtab.o: symtab.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
246   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
247   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
248   search_list.h source.h symtab.h cg_arcs.h corefile.h
249 sym_ids.o: sym_ids.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
250   $(INCDIR)/safe-ctype.h gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h \
251   $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h ../bfd/bfd.h \
252   $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h search_list.h \
253   source.h symtab.h cg_arcs.h sym_ids.h
254 utils.o: utils.c $(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
255   $(INCDIR)/ansidecl.h gprof.h $(BFDDIR)/sysdep.h ../bfd/config.h \
256   $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h ../bfd/bfd.h \
257   $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h search_list.h \
258   source.h symtab.h cg_arcs.h utils.h
259 i386.o: i386.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
260   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
261   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
262   search_list.h source.h symtab.h cg_arcs.h corefile.h \
263   hist.h
264 alpha.o: alpha.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
265   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
266   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
267   search_list.h source.h symtab.h cg_arcs.h corefile.h \
268   hist.h
269 vax.o: vax.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
270   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
271   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
272   search_list.h source.h symtab.h cg_arcs.h corefile.h \
273   hist.h
274 tahoe.o: tahoe.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
275   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
276   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
277   search_list.h source.h symtab.h cg_arcs.h corefile.h \
278   hist.h
279 sparc.o: sparc.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
280   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
281   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
282   search_list.h source.h symtab.h cg_arcs.h corefile.h \
283   hist.h
284 mips.o: mips.c gprof.h $(BFDDIR)/sysdep.h $(INCDIR)/ansidecl.h \
285   ../bfd/config.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h \
286   ../bfd/bfd.h $(INCDIR)/symcat.h gconfig.h $(INCDIR)/bin-bugs.h \
287   search_list.h source.h symtab.h cg_arcs.h corefile.h \
288   hist.h
289 flat_bl.o: flat_bl.c $(INCDIR)/ansidecl.h
290 bsd_callg_bl.o: bsd_callg_bl.c $(INCDIR)/ansidecl.h
291 fsf_callg_bl.o: fsf_callg_bl.c $(INCDIR)/ansidecl.h
292 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY