Makefile.am 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. ## Process this file with automake to generate Makefile.in
  2. #
  3. # Copyright (C) 2012-2022 Free Software Foundation, Inc.
  4. #
  5. # This file is free software; you can redistribute it and/or modify
  6. # it under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation; either version 3 of the License, or
  8. # (at your option) any later version.
  9. #
  10. # This program is distributed in the hope that it will be useful,
  11. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. # GNU General Public License for more details.
  14. #
  15. # You should have received a copy of the GNU General Public License
  16. # along with this program; see the file COPYING3. If not see
  17. # <http://www.gnu.org/licenses/>.
  18. #
  19. AUTOMAKE_OPTIONS = foreign no-dist no-texinfo.tex info-in-builddir
  20. ACLOCAL_AMFLAGS = -I .. -I ../config -I ../bfd
  21. TEXINFO_TEX = ../texinfo/texinfo.tex
  22. SUFFIXES = .c .m
  23. SUBDIRS = po
  24. BASEDIR = $(srcdir)/..
  25. BFDDIR = $(BASEDIR)/bfd
  26. INCDIR = $(BASEDIR)/include
  27. WARN_CFLAGS = @WARN_CFLAGS@
  28. NO_WERROR = @NO_WERROR@
  29. AM_CFLAGS = $(WARN_CFLAGS)
  30. AM_CPPFLAGS = -DDEBUG -I../bfd -I$(srcdir)/../include \
  31. -I$(srcdir)/../bfd @INCINTL@ @LARGEFILE_CPPFLAGS@ -I. \
  32. -DLOCALEDIR="\"$(datadir)/locale\""
  33. bin_PROGRAMS = gprof
  34. ## Convenience var listing pure sources.
  35. sources = basic_blocks.c call_graph.c cg_arcs.c cg_dfn.c \
  36. cg_print.c corefile.c gmon_io.c gprof.c hertz.c hist.c source.c \
  37. search_list.c symtab.c sym_ids.c utils.c \
  38. i386.c alpha.c vax.c sparc.c mips.c aarch64.c
  39. gprof_SOURCES = $(sources) flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
  40. gprof_DEPENDENCIES = ../bfd/libbfd.la ../libiberty/libiberty.a $(LIBINTL_DEP)
  41. gprof_LDADD = ../bfd/libbfd.la ../libiberty/libiberty.a $(LIBINTL)
  42. noinst_HEADERS = \
  43. basic_blocks.h call_graph.h cg_arcs.h cg_dfn.h cg_print.h \
  44. corefile.h gmon.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
  45. search_list.h source.h sym_ids.h symtab.h utils.h
  46. BUILT_SOURCES = flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
  47. EXTRA_DIST = $(BUILT_SOURCES) bbconv.pl $(man_MANS)
  48. diststuff: $(BUILT_SOURCES) info $(man_MANS)
  49. # development.sh is used to determine -Werror default.
  50. CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/development.sh
  51. # This empty rule is a hack against gmake patched by Apple.
  52. %.o:%.m
  53. .m.c:
  54. $(AM_V_GEN)awk -f $(srcdir)/gen-c-prog.awk > $@ \
  55. FUNCTION=`(echo $*|sed -e 's,.*/,,g' -e 's/_bl//')`_blurb \
  56. FILE=$*.m $<
  57. POTFILES = $(sources) $(noinst_HEADERS)
  58. po/POTFILES.in: @MAINT@ Makefile
  59. for f in $(POTFILES); do echo $$f; done | LC_ALL=C sort > tmp \
  60. && mv tmp $(srcdir)/po/POTFILES.in
  61. MANCONF = -Dman
  62. TEXI2POD = perl $(srcdir)/../etc/texi2pod.pl $(AM_MAKEINFOFLAGS)
  63. POD2MAN = pod2man --center="GNU" --release="binutils-$(VERSION)" --section=1
  64. info_TEXINFOS = gprof.texi
  65. gprof_TEXINFOS = config.texi
  66. man_MANS = gprof.1
  67. AM_MAKEINFOFLAGS = -I "$(srcdir)" -I "$(top_srcdir)/../bfd/doc" -I ../bfd/doc \
  68. --no-split
  69. TEXI2DVI = texi2dvi -I "$(srcdir)" -I "$(top_srcdir)/../bfd/doc" -I ../bfd/doc
  70. config.texi:
  71. $(AM_V_GEN)echo "@set top_srcdir $(top_srcdir)" >> ./config.texi
  72. # Build the man page from the texinfo file
  73. # The sed command removes the no-adjust Nroff command so that
  74. # the man output looks standard.
  75. gprof.1: $(srcdir)/gprof.texi config.texi
  76. $(AM_V_GEN)touch $@
  77. $(AM_V_at)-$(TEXI2POD) $(MANCONF) -Dgprof < $(srcdir)/gprof.texi > gprof.pod
  78. $(AM_V_at)-($(POD2MAN) gprof.pod | \
  79. sed -e '/^.if n .na/d' > $@.T$$$$ && \
  80. mv -f $@.T$$$$ $@) || \
  81. (rm -f $@.T$$$$ && exit 1)
  82. $(AM_V_at)rm -f gprof.pod
  83. html-local: doc/gprof/index.html
  84. doc/gprof/index.html: gprof.texi $(gprof_TEXINFOS)
  85. $(AM_V_at)$(MKDIR_P) doc
  86. $(AM_V_GEN)$(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) \
  87. --split=node -I$(srcdir) $(srcdir)/gprof.texi -o doc/gprof
  88. MAINTAINERCLEANFILES = gprof.info