]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Change to use automake:
authorIan Lance Taylor <ian@airs.com>
Tue, 15 Apr 1997 18:35:39 +0000 (18:35 +0000)
committerIan Lance Taylor <ian@airs.com>
Tue, 15 Apr 1997 18:35:39 +0000 (18:35 +0000)
* Makefile.am: New file.
* configure.in: Run AM_INIT_AUTOMAKE, AM_MAINTAINER_MODE, and
AM_CYGWIN32.
* aclocal.m4: New file, created by aclocal.
* Makefile.in: Replace with file created by automake --cygnus.
* configure: Rebuild.

gprof/.Sanitize
gprof/ChangeLog
gprof/Makefile.am [new file with mode: 0644]
gprof/Makefile.in
gprof/aclocal.m4 [new file with mode: 0644]
gprof/configure
gprof/configure.in

index 07dd1cefdca3efe43ac370edb08bdad29c09541e..1a3fe617bf261f018c999cbaffd8a6f87fb717d4 100644 (file)
@@ -27,10 +27,12 @@ Things-to-keep:
 .gdbinit
 bb_exit_func.c
 ChangeLog
+Makefile.am
 Makefile.in
 NOTES
 TEST
 TODO
+aclocal.m4
 alpha.c
 alpha.h
 basic_blocks.c
index 92bd3a2f464723f34b66f7331205a216acadd9af..a345471ce2c50ad1074c80436535a2c85fcca01b 100644 (file)
@@ -1,3 +1,13 @@
+Tue Apr 15 14:19:30 1997  Ian Lance Taylor  <ian@cygnus.com>
+
+       Change to use automake:
+       * Makefile.am: New file.
+       * configure.in: Run AM_INIT_AUTOMAKE, AM_MAINTAINER_MODE, and
+       AM_CYGWIN32.
+       * aclocal.m4: New file, created by aclocal.
+       * Makefile.in: Replace with file created by automake --cygnus.
+       * configure: Rebuild.
+
 Thu Apr  3 13:21:25 1997  Ian Lance Taylor  <ian@cygnus.com>
 
        * gprof.c (VERSION): Define as "2.8.1".
diff --git a/gprof/Makefile.am b/gprof/Makefile.am
new file mode 100644 (file)
index 0000000..c4d8e7e
--- /dev/null
@@ -0,0 +1,68 @@
+## Process this file with automake to generate Makefile.in
+
+## We should have cygnus in AUTOMAKE_OPTIONS, but it doesn't work yet.
+AUTOMAKE_OPTIONS = foreign
+
+SUFFIXES = .m
+
+INCLUDES = -D_GNU_SOURCE -DTARGET_$(MY_TARGET) -DMACHINE_H=\"$(MY_TARGET).h\" -I../bfd -I$(srcdir)/../include -I$(srcdir)/../bfd
+
+LINK = $(HLDENV) $(CC) $(LDFLAGS) -o $@
+
+MY_TARGET = @MY_TARGET@
+
+bin_PROGRAMS = gprof
+
+gprof_SOURCES = basic_blocks.c call_graph.c cg_arcs.c cg_dfn.c \
+       cg_print.c core.c gmon_io.c gprof.c hertz.c hist.c source.c \
+       search_list.c symtab.c sym_ids.c utils.c \
+       flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
+gprof_LDFLAGS = $(HLDFLAGS)
+gprof_DEPENDENCIES = $(MY_TARGET).o ../bfd/libbfd.a ../libiberty/libiberty.a
+gprof_LDADD = $(MY_TARGET).o @BFDLIB@ ../libiberty/libiberty.a
+
+noinst_HEADERS = \
+       alpha.h i386.h ns532.h sparc.h tahoe.h vax.h dummy.h \
+       basic_blocks.h call_graph.h cg_arcs.h cg_dfn.h cg_print.h \
+       core.h gmon.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
+       search_list.h source.h sparc.h sym_ids.h symtab.h utils.h
+
+EXTRA_DIST = \
+       alpha.c i386.c ns532.c sparc.c tahoe.c vax.c dummy.c \
+       flat_bl.c bsd_callg_bl.c fsf_callg_bl.c \
+
+BUILT_SOURCES = flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
+
+.m.c:
+       awk -f $(srcdir)/gen-c-prog.awk > ./$*.c \
+           FUNCTION=`(echo $*|sed -e 's,.*/,,g' -e 's/_bl//')`_blurb \
+           FILE=$*.m $(srcdir)/$*.m
+
+info_TEXINFOS = gprof.texi
+man_MANS = gprof.1
+
+# Dependencies.
+$(OBJECTS): ../bfd/bfd.h call_graph.h cg_arcs.h cg_print.h \
+       core.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
+       search_list.h source.h sym_ids.h symtab.h utils.h \
+       $(srcdir)/../include/libiberty.h $(srcdir)/../bfd/sysdep.h \
+       $(MY_TARGET).h
+$(MY_TARGET).o: $(MY_TARGET).c
+basic_blocks.o: basic_blocks.c
+bsd_call_bl.o: bsd_call_bl.c
+call_graph.o: call_graph.c
+cg_arcs.o: cg_arcs.c
+cg_dfn.o: cg_dfn.c
+cg_print.o: cg_print.c
+core.o: core.c
+flat_bl.o: flat_bl.c
+fsf_callg_bl.o: fsf_callg_bl.c
+gmon_io.o: gmon_io.c
+gprof.o: gprof.c
+hertz.o: hertz.c
+hist.o: hist.c
+search_list.o: search_list.c
+source.o: source.c
+symtab.o: symtab.c
+sym_ids.o: sym_ids.c
+utils.o: utils.c
index 69d5ea7b63f4eae78d627f3f2c3a38c7eb956d0d..59156d5187aa4532bf1f9e5d2cc1099231440e29 100644 (file)
-#      @(#)Makefile    5.17 (Berkeley) 5/11/90
+# Makefile.in generated automatically by automake 1.1n from Makefile.am
 
-.SUFFIXES : .m
+# Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy, distribute and modify it.
+
+
+SHELL = /bin/sh
 
-VPATH = @srcdir@
 srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@
 prefix = @prefix@
+exec_prefix = @exec_prefix@
 
-exec_prefix    = @exec_prefix@
-program_transform_name = @program_transform_name@
+bindir = @bindir@
+sbindir = @sbindir@
+libexecdir = @libexecdir@
+datadir = @datadir@
+sysconfdir = @sysconfdir@
+sharedstatedir = @sharedstatedir@
+localstatedir = @localstatedir@
+libdir = @libdir@
+infodir = @infodir@
+mandir = @mandir@
+includedir = @includedir@
+oldincludedir = /usr/include
+
+pkgdatadir = $(datadir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+
+top_builddir = .
+
+ACLOCAL = @ACLOCAL@
+AUTOCONF = @AUTOCONF@
+AUTOMAKE = @AUTOMAKE@
+AUTOHEADER = @AUTOHEADER@
+
+INSTALL = @INSTALL@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+transform = @program_transform_name@
+
+NORMAL_INSTALL = true
+PRE_INSTALL = true
+POST_INSTALL = true
+NORMAL_UNINSTALL = true
+PRE_UNINSTALL = true
+POST_UNINSTALL = true
+build_alias = @build_alias@
+build_triplet = @build@
+host_alias = @host_alias@
+host_triplet = @host@
+target_alias = @target_alias@
+target_triplet = @target@
+BFDLIB = @BFDLIB@
+CC = @CC@
+EXEEXT = @EXEEXT@
+HLDENV = @HLDENV@
+HLDFLAGS = @HLDFLAGS@
+MAINT = @MAINT@
+PACKAGE = @PACKAGE@
+VERSION = @VERSION@
 
-bindir         = @bindir@
-libdir         = @libdir@
-tooldir = $(libdir)
-mandir         = @mandir@
-man1dir = $(mandir)/man1
+AUTOMAKE_OPTIONS = foreign
 
-infodir        = @infodir@
-datadir = @datadir@
+SUFFIXES = .m
 
-SHELL = /bin/sh
+INCLUDES = -D_GNU_SOURCE -DTARGET_$(MY_TARGET) -DMACHINE_H=\"$(MY_TARGET).h\" -I../bfd -I$(srcdir)/../include -I$(srcdir)/../bfd
 
-INSTALL = `cd $(srcdir); pwd`/../install.sh -c
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_XFORM = $(INSTALL) -t='$(program_transform_name)'
-INSTALL_XFORM1 = $(INSTALL_XFORM) -b=.1
-MAKEINFO       = makeinfo
-TEX            = tex
-TEXINDEX       = texindex
+LINK = $(HLDENV) $(CC) $(LDFLAGS) -o $@
 
-# this is the directory we look in to find Texinfo
-texidir                = $(srcdir)/../texinfo
+MY_TARGET = @MY_TARGET@
 
-MY_TARGET=     @MY_TARGET@
+bin_PROGRAMS = gprof
 
-PROG=  gprof
-SRCS=  $(MY_TARGET).c basic_blocks.c call_graph.c \
-       cg_arcs.c cg_dfn.c cg_print.c core.c \
-       gmon_io.c gprof.c hertz.c hist.c source.c search_list.c symtab.c \
-       sym_ids.c utils.c
+gprof_SOURCES = basic_blocks.c call_graph.c cg_arcs.c cg_dfn.c \
+       cg_print.c core.c gmon_io.c gprof.c hertz.c hist.c source.c \
+       search_list.c symtab.c sym_ids.c utils.c \
+       flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
+gprof_LDFLAGS = $(HLDFLAGS)
+gprof_DEPENDENCIES = $(MY_TARGET).o ../bfd/libbfd.a ../libiberty/libiberty.a
+gprof_LDADD = $(MY_TARGET).o @BFDLIB@ ../libiberty/libiberty.a
 
-LIBDEPS = ../bfd/libbfd.a ../libiberty/libiberty.a
-LIBS = @BFDLIB@ ../libiberty/libiberty.a
+noinst_HEADERS = \
+       alpha.h i386.h ns532.h sparc.h tahoe.h vax.h dummy.h \
+       basic_blocks.h call_graph.h cg_arcs.h cg_dfn.h cg_print.h \
+       core.h gmon.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
+       search_list.h source.h sparc.h sym_ids.h symtab.h utils.h
 
-OBJS=  $(MY_TARGET).o basic_blocks.o bsd_callg_bl.o call_graph.o \
-       cg_arcs.o cg_dfn.o cg_print.o core.o flat_bl.o fsf_callg_bl.o \
-       gmon_io.o gprof.o hertz.o hist.o source.o search_list.o symtab.o \
-       sym_ids.o utils.o
+EXTRA_DIST = \
+       alpha.c i386.c ns532.c sparc.c tahoe.c vax.c dummy.c \
+       flat_bl.c bsd_callg_bl.c fsf_callg_bl.c \
+BUILT_SOURCES = flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
 
-# Files that can be generated, but should be included in distribution.
-GEN_FILES = flat_bl.c bsd_callg_bl.c fsf_callg_bl.c
+info_TEXINFOS = gprof.texi
+man_MANS = gprof.1
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
+CONFIG_CLEAN_FILES = 
+PROGRAMS =  $(bin_PROGRAMS)
+
+
+DEFS = @DEFS@ -I. -I$(srcdir) 
+CPPFLAGS = @CPPFLAGS@
+LDFLAGS = @LDFLAGS@
+LIBS = @LIBS@
+gprof_OBJECTS =  basic_blocks.o call_graph.o cg_arcs.o cg_dfn.o \
+cg_print.o core.o gmon_io.o gprof.o hertz.o hist.o source.o \
+search_list.o symtab.o sym_ids.o utils.o flat_bl.o bsd_callg_bl.o \
+fsf_callg_bl.o
+CFLAGS = @CFLAGS@
+COMPILE = $(CC) $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)
+MAKEINFO = `if test -f $(top_builddir)/../texinfo/makeinfo/makeinfo; then echo $(top_builddir)/../texinfo/makeinfo/makeinfo; else echo makeinfo; fi`
+TEXI2DVI = `if test -f $(top_srcdir)/../texinfo/util/texi2dvi; then echo $(top_srcdir)/../texinfo/util/texi2dvi; else echo texi2dvi; fi`
+TEXINFO_TEX = $(top_srcdir)/../texinfo/texinfo.tex
+INFO_DEPS = gprof.info
+DVIS = gprof.dvi
+TEXINFOS = gprof.texi
+MANS = gprof.1
+
+NROFF = nroff
+HEADERS =  $(noinst_HEADERS)
+
+DIST_COMMON =  ChangeLog Makefile.am Makefile.in TODO aclocal.m4 \
+configure configure.in
+
+
+DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
+
+TAR = tar
+GZIP = --best
+SOURCES = $(gprof_SOURCES)
+OBJECTS = $(gprof_OBJECTS)
+
+default: all
+
+.SUFFIXES:
+.SUFFIXES: .c .o .texi .texinfo .info .dvi .ps .m
+$(srcdir)/Makefile.in: @MAINT@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) 
+       cd $(top_srcdir) && $(AUTOMAKE) --cygnus Makefile
+
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
+       cd $(top_builddir) \
+         && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
+
+$(srcdir)/aclocal.m4: @MAINT@ configure.in 
+       cd $(srcdir) && $(ACLOCAL)
+
+config.status: configure
+       $(SHELL) ./config.status --recheck
+$(srcdir)/configure: @MAINT@configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES)
+       cd $(srcdir) && $(AUTOCONF)
+
+mostlyclean-binPROGRAMS:
+
+clean-binPROGRAMS:
+       @list='$(bin_PROGRAMS)'; for p in $$list; do \
+         rm -f $$p $$p$(EXEEXT); \
+       done
+
+distclean-binPROGRAMS:
+
+maintainer-clean-binPROGRAMS:
+
+install-binPROGRAMS: $(bin_PROGRAMS)
+       @$(NORMAL_INSTALL)
+       $(mkinstalldirs) $(bindir)
+       @list='$(bin_PROGRAMS)'; for p in $$list; do \
+         if test -f $$p; then \
+           echo "  $(INSTALL_PROGRAM) $$p$(EXEEXT) $(bindir)/`echo $$p|sed '$(transform)'`$(EXEEXT)"; \
+            $(INSTALL_PROGRAM) $$p$(EXEEXT) $(bindir)/`echo $$p|sed '$(transform)'`$(EXEEXT); \
+         else :; fi; \
+       done
+
+uninstall-binPROGRAMS:
+       $(NORMAL_UNINSTALL)
+       list='$(bin_PROGRAMS)'; for p in $$list; do \
+         rm -f $(bindir)/`echo $$p|sed '$(transform)'`$(EXEEXT); \
+       done
 
-CFLAGS=-g -DDEBUG
-LDFLAGS=
-HLDFLAGS = @HLDFLAGS@
-HLDENV = @HLDENV@
 .c.o:
-       $(CC) -c -D_GNU_SOURCE -I. -I$(srcdir) -I../bfd -I$(srcdir)/../include -I$(srcdir)/../bfd @DEFS@ -DTARGET_$(MY_TARGET) -DMACHINE_H=\"$(MY_TARGET).h\" $(TCFLAGS) $(HCFLAGS) $(CFLAGS) $<
+       $(COMPILE) -c $<
 
-all:   $(GEN_FILES) $(PROG)
+mostlyclean-compile:
+       rm -f *.o core
 
-.PHONY: check installcheck info install-info
-.SUFFIXES: .m
+clean-compile:
 
-.m.c:
-       awk -f $(srcdir)/gen-c-prog.awk > ./$*.c \
-           FUNCTION=`(echo $*|sed -e 's,.*/,,g' -e 's/_bl//')`_blurb \
-           FILE=$*.m $(srcdir)/$*.m
+distclean-compile:
+       rm -f *.tab.c
 
-diststuff: $(GEN_FILES) info
+maintainer-clean-compile:
 
-gprof.info: gprof.texi
-       $(MAKEINFO) -o gprof.info $(srcdir)/gprof.texi
+gprof: $(gprof_OBJECTS) $(gprof_DEPENDENCIES)
+       @rm -f gprof$(EXEEXT)
+       $(LINK) $(gprof_LDFLAGS) $(gprof_OBJECTS) $(gprof_LDADD) $(LIBS)
+       @test -z "$(EXEEXT)" || echo timestamp > gprof
 
+gprof.info: gprof.texi
 gprof.dvi: gprof.texi
-       TEXINPUTS=${TEXIDIR}:$(srcdir):$$TEXINPUTS $(TEX) $(srcdir)/gprof.texi
-       $(TEXINDEX) gprof.??
-       TEXINPUTS=${TEXIDIR}:$(srcdir):$$TEXINPUTS $(TEX) $(srcdir)/gprof.texi
 
-info: gprof.info
 
-dvi: gprof.dvi
+DVIPS = dvips
 
-check:
-installcheck:
+.texi.info:
+       $(MAKEINFO) -I $(srcdir) $<
+
+.texi.dvi:
+       TEXINPUTS=$(top_srcdir)/../texinfo:$$TEXINPUTS \
+         MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
+
+.texi:
+       $(MAKEINFO) -I $(srcdir) $<
+
+.texinfo.info:
+       $(MAKEINFO) $<
+
+.texinfo:
+       $(MAKEINFO) $<
+
+.texinfo.dvi:
+       TEXINPUTS=$(top_srcdir)/../texinfo:$$TEXINPUTS \
+         MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
+.dvi.ps:
+       $(DVIPS) $< -o $@
+
+install-info-am: $(INFO_DEPS)
+       @$(NORMAL_INSTALL)
+       $(mkinstalldirs) $(infodir)
+       @for file in $(INFO_DEPS); do \
+         if test -f $$file; then d=.; else d=$(srcdir); fi; \
+         for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \
+           if test -f $$d/$$ifile; then \
+             echo " $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile"; \
+             $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile; \
+           else : ; fi; \
+         done; \
+       done
+       @$(POST_INSTALL)
+       @if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
+         for file in $(INFO_DEPS); do \
+           echo " install-info --info-dir=$(infodir) $(infodir)/$$file";\
+           install-info --info-dir=$(infodir) $(infodir)/$$file; :;\
+         done; \
+       else : ; fi
+
+uninstall-info:
+       $(PRE_UNINSTALL)
+       if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
+         ii=yes; \
+       else ii=; fi; \
+       for file in $(INFO_DEPS); do \
+         test -z $ii || install-info --info-dir=$(infodir) --remove $$file; \
+       done
+       $(NORMAL_UNINSTALL)
+       for file in $(INFO_DEPS); do \
+         (cd $(infodir) && rm -f $$file $$file-[0-9] $$file-[0-9][0-9]); \
+       done
+
+dist-info: $(INFO_DEPS)
+       for base in $(INFO_DEPS); do \
+         if test -f $$base; then d=.; else d=$(srcdir); fi; \
+         for file in `cd $$d && eval echo $$base*`; do \
+           test -f $(distdir)/$$file \
+           || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
+           || cp -p $$d/$$file $(distdir)/$$file; \
+         done; \
+       done
 
-TAGS:
-       etags $(srcdir)/*.[ch]
-tags:  TAGS
-
-install-info: gprof.info
-       if [ -r gprof.info ]; then \
-         dir=. ; \
-       else \
-         dir=$(srcdir) ; \
-       fi ; \
-       for i in `cd $$dir; echo gprof.info*` ; do \
-               $(INSTALL_DATA) $$dir/$$i $(infodir)/$$i ; \
+mostlyclean-info:
+       rm -f gprof.aux gprof.cp gprof.cps gprof.dvi gprof.fn gprof.fns \
+         gprof.ky gprof.log gprof.pg gprof.toc gprof.tp gprof.tps \
+         gprof.vr gprof.vrs gprof.op gprof.tr gprof.cv
+
+clean-info:
+
+distclean-info:
+
+maintainer-clean-info:
+       for i in $(INFO_DEPS); do rm -f `eval echo $$i*`; done
+install-man: $(MANS)
+       $(NORMAL_INSTALL)
+       $(mkinstalldirs) $(mandir)/man1
+       @sect=1;                                \
+       inst=`echo "gprof" | sed '$(transform)'`.1; \
+       if test -f $(srcdir)/gprof.1; then file=$(srcdir)/gprof.1; \
+       else file=gprof.1; fi; \
+       echo " $(INSTALL_DATA) $$file $(mandir)/man$$sect/$$inst"; \
+       $(INSTALL_DATA) $$file $(mandir)/man$$sect/$$inst
+
+uninstall-man:
+       $(NORMAL_UNINSTALL)
+       inst=`echo "gprof" | sed '$(transform)'`.1; \
+       rm -f $(mandir)/man1/$$inst
+
+
+tags: TAGS
+
+ID: $(HEADERS) $(SOURCES)
+       here=`pwd` && cd $(srcdir) && mkid -f$$here/ID $(SOURCES) $(HEADERS)
+
+TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES)
+       tags=; \
+       here=`pwd`; \
+       list='$(SUBDIRS)'; for subdir in $$list; do \
+         test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
+       done; \
+       test -z "$(ETAGS_ARGS)$(SOURCES)$(HEADERS)$$tags" \
+         || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags  $(SOURCES) $(HEADERS) -o $$here/TAGS)
+
+mostlyclean-tags:
+
+clean-tags:
+
+distclean-tags:
+       rm -f TAGS ID
+
+maintainer-clean-tags:
+
+distdir = $(PACKAGE)-$(VERSION)
+# This target untars the dist file and tries a VPATH configuration.  Then
+# it guarantees that the distribution is self-contained by making another
+# tarfile.
+distcheck: dist
+       rm -rf $(distdir)
+       GZIP=$(GZIP) $(TAR) zxf $(distdir).tar.gz
+       mkdir $(distdir)/=build
+       mkdir $(distdir)/=inst
+       dc_install_base=`cd $(distdir)/=inst && pwd`; \
+       cd $(distdir)/=build \
+         && ../configure --srcdir=.. --prefix=$$dc_install_base \
+         && $(MAKE) \
+         && $(MAKE) dvi \
+         && $(MAKE) check \
+         && $(MAKE) install \
+         && $(MAKE) installcheck \
+         && $(MAKE) dist
+       rm -rf $(distdir)
+       @echo "========================"; \
+       echo "$(distdir).tar.gz is ready for distribution"; \
+       echo "========================"
+dist: distdir
+       -chmod -R a+r $(distdir)
+       GZIP=$(GZIP) $(TAR) chozf $(distdir).tar.gz $(distdir)
+       rm -rf $(distdir)
+dist-all: distdir
+       -chmod -R a+r $(distdir)
+       GZIP=$(GZIP) $(TAR) chozf $(distdir).tar.gz $(distdir)
+       rm -rf $(distdir)
+distdir: $(DISTFILES)
+       rm -rf $(distdir)
+       mkdir $(distdir)
+       -chmod 755 $(distdir)
+       @for file in $(DISTFILES); do \
+         if test -f $$file; then d=.; else d=$(srcdir); fi; \
+         test -f $(distdir)/$$file \
+         || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
+         || cp -p $$d/$$file $(distdir)/$$file; \
        done
+       $(MAKE) distdir="$(distdir)" dist-info
+info: $(INFO_DEPS)
+dvi: $(DVIS)
+check: all
+       $(MAKE)
+installcheck:
+install-info: install-info-am
+install-exec: install-binPROGRAMS
+       @$(NORMAL_INSTALL)
 
-install: all
-       $(INSTALL_XFORM) gprof $(bindir)/gprof
-       $(INSTALL_XFORM1) $(srcdir)/gprof.1 $(man1dir)/gprof.1
+install-data: install-man
+       @$(NORMAL_INSTALL)
 
-gprof: $(OBJS) $(LIBDEPS)
-       $(HLDENV) $(CC) -o $(PROG) $(HLDFLAGS) $(LDFLAGS) $(CFLAGS) $(OBJS) $(LIBS)
+install: install-exec install-data all
+       @:
 
-mostlyclean:
-       -rm -f *.o core gprof nohup.out \
-       gprof.cps  gprof.fns  gprof.log  gprof.ps   gprof.tps\
-       gprof.aux  gprof.dvi  gprof.ky   gprof.pg   gprof.toc  gprof.vr\
-       gprof.cp   gprof.fn   gprof.kys  gprof.pgs  gprof.tp   gprof.vrs
-clean: mostlyclean
-       -rm -f gprof
-distclean: clean
-       -rm -f config.cache config.log config.status Makefile
-maintainer-clean realclean: distclean
-       -rm -f $(GEN_FILES) *.info*
+uninstall: uninstall-binPROGRAMS uninstall-man
 
-Makefile: Makefile.in config.status
-       $(SHELL) config.status
+all: $(PROGRAMS) $(MANS) $(HEADERS) Makefile
 
-config.status: configure
-       $(SHELL) config.status --recheck
+install-strip:
+       $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install
+installdirs:
+       $(mkinstalldirs)  $(bindir) $(mandir)/man1
+
+
+mostlyclean-generic:
+       test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+
+clean-generic:
+       test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
+
+distclean-generic:
+       rm -f Makefile $(DISTCLEANFILES)
+       rm -f config.cache config.log stamp-h
+       test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+
+maintainer-clean-generic:
+       test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+       test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
+mostlyclean:  mostlyclean-binPROGRAMS mostlyclean-compile \
+               mostlyclean-info mostlyclean-tags mostlyclean-generic
+
+clean:  clean-binPROGRAMS clean-compile clean-info clean-tags \
+               clean-generic mostlyclean
 
-$(OBJS): ../bfd/bfd.h call_graph.h cg_arcs.h cg_print.h core.h gmon_io.h \
-        gmon_out.h gprof.h hertz.h hist.h search_list.h source.h sym_ids.h \
-        symtab.h utils.h $(srcdir)/../include/libiberty.h \
-        $(srcdir)/../bfd/sysdep.h $(MY_TARGET).h
+distclean:  distclean-binPROGRAMS distclean-compile distclean-info \
+               distclean-tags distclean-generic clean
+       rm -f config.status
 
-# These get around a bug in Sun Make in SunOS 4.1.1 and Solaris 2
+maintainer-clean:  maintainer-clean-binPROGRAMS maintainer-clean-compile \
+               maintainer-clean-info maintainer-clean-tags \
+               maintainer-clean-generic distclean
+       @echo "This command is intended for maintainers to use;"
+       @echo "it deletes files that may require special tools to rebuild."
+       rm -f config.status
+
+.PHONY: default mostlyclean-binPROGRAMS distclean-binPROGRAMS \
+clean-binPROGRAMS maintainer-clean-binPROGRAMS uninstall-binPROGRAMS \
+install-binPROGRAMS mostlyclean-compile distclean-compile clean-compile \
+maintainer-clean-compile install-info-am uninstall-info \
+mostlyclean-info distclean-info clean-info maintainer-clean-info \
+install-man uninstall-man tags mostlyclean-tags distclean-tags \
+clean-tags maintainer-clean-tags distdir info dvi installcheck \
+install-info install-exec install-data install uninstall all \
+installdirs mostlyclean-generic distclean-generic clean-generic \
+maintainer-clean-generic clean mostlyclean distclean maintainer-clean
+
+
+.m.c:
+       awk -f $(srcdir)/gen-c-prog.awk > ./$*.c \
+           FUNCTION=`(echo $*|sed -e 's,.*/,,g' -e 's/_bl//')`_blurb \
+           FILE=$*.m $(srcdir)/$*.m
+
+# Dependencies.
+$(OBJECTS): ../bfd/bfd.h call_graph.h cg_arcs.h cg_print.h \
+       core.h gmon_io.h gmon_out.h gprof.h hertz.h hist.h \
+       search_list.h source.h sym_ids.h symtab.h utils.h \
+       $(srcdir)/../include/libiberty.h $(srcdir)/../bfd/sysdep.h \
+       $(MY_TARGET).h
 $(MY_TARGET).o: $(MY_TARGET).c
 basic_blocks.o: basic_blocks.c
 bsd_call_bl.o: bsd_call_bl.c
@@ -149,3 +459,7 @@ source.o: source.c
 symtab.o: symtab.c
 sym_ids.o: sym_ids.c
 utils.o: utils.c
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/gprof/aclocal.m4 b/gprof/aclocal.m4
new file mode 100644 (file)
index 0000000..619693b
--- /dev/null
@@ -0,0 +1,125 @@
+dnl aclocal.m4 generated automatically by aclocal 1.1n
+
+# Do all the work for Automake.  This macro actually does too much --
+# some checks are only needed if your package does certain things.
+# But this isn't really a big deal.
+
+# serial 1
+
+dnl Usage:
+dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+
+AC_DEFUN(AM_INIT_AUTOMAKE,
+[AC_REQUIRE([AM_PROG_INSTALL])
+PACKAGE=[$1]
+AC_SUBST(PACKAGE)
+VERSION=[$2]
+AC_SUBST(VERSION)
+ifelse([$3],,
+AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
+AC_DEFINE_UNQUOTED(VERSION, "$VERSION"))
+AM_SANITY_CHECK
+AC_ARG_PROGRAM
+dnl FIXME This is truly gross.
+missing_dir=`cd $ac_aux_dir && pwd`
+AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
+AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
+AC_PROG_MAKE_SET])
+
+
+# serial 1
+
+AC_DEFUN(AM_PROG_INSTALL,
+[AC_REQUIRE([AC_PROG_INSTALL])
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
+AC_SUBST(INSTALL_SCRIPT)dnl
+])
+
+#
+# Check to make sure that the build environment is sane.
+#
+
+AC_DEFUN(AM_SANITY_CHECK,
+[AC_MSG_CHECKING([whether build environment is sane])
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments.  Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+   if test "$@" = "X"; then
+      # -L didn't work.
+      set X `ls -t $srcdir/configure conftestfile`
+   fi
+   test "[$]2" = conftestfile
+   )
+then
+   # Ok.
+   :
+else
+   AC_MSG_ERROR([newly created file is older than distributed files!
+Check your system clock])
+fi
+rm -f conftest*
+AC_MSG_RESULT(yes)])
+
+dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
+dnl The program must properly implement --version.
+AC_DEFUN(AM_MISSING_PROG,
+[AC_MSG_CHECKING(for working $2)
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if ($2 --version) > /dev/null 2>&1; then
+   $1=$2
+   AC_MSG_RESULT(found)
+else
+   $1="$3/missing $2"
+   AC_MSG_RESULT(missing)
+fi
+AC_SUBST($1)])
+
+# Add --enable-maintainer-mode option to configure.
+# From Jim Meyering
+
+# serial 1
+
+AC_DEFUN(AM_MAINTAINER_MODE,
+[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
+  dnl maintainer-mode is disabled by default
+  AC_ARG_ENABLE(maintainer-mode,
+[  --enable-maintainer-mode enable make rules and dependencies not useful
+                          (and sometimes confusing) to the casual installer],
+      USE_MAINTAINER_MODE=$enableval,
+      USE_MAINTAINER_MODE=no)
+  AC_MSG_RESULT($USE_MAINTAINER_MODE)
+  if test $USE_MAINTAINER_MODE = yes; then
+    MAINT=
+  else
+    MAINT='#M#'
+  fi
+  AC_SUBST(MAINT)dnl
+]
+)
+
+# Check to see if we're running under Cygwin32, without using
+# AC_CANONICAL_*.  If so, set output variable EXEEXT to ".exe".
+# Otherwise set it to "".
+
+dnl AM_CYGWIN32()
+AC_DEFUN(AM_CYGWIN32,
+[AC_MSG_CHECKING(for Cygwin32 environment)
+AC_EGREP_CPP(lose, [
+#ifdef __CYGWIN32__
+lose
+#endif], [EXEEXT=.exe
+AC_MSG_RESULT(yes)], [EXEEXT=
+AC_MSG_RESULT(no)])
+AC_SUBST(EXEEXT)])
+
index cf951d9d9f84a9edd6e344844d66a5ba56d4b2ae..a1c4487675ccbeaca798aafcfe5720f3a02de183 100755 (executable)
@@ -13,6 +13,9 @@ ac_default_prefix=/usr/local
 # Any additions from configure.in:
 ac_help="$ac_help
   --enable-shared         build shared BFD library"
+ac_help="$ac_help
+  --enable-maintainer-mode enable make rules and dependencies not useful
+                          (and sometimes confusing) to the casual installer"
 
 # Initialize some variables set by options.
 # The variables have the same names as the options, with
@@ -521,6 +524,326 @@ fi
 
 
 
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+  if test -f $ac_dir/install-sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install-sh -c"
+    break
+  elif test -f $ac_dir/install.sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install.sh -c"
+    break
+  fi
+done
+if test -z "$ac_aux_dir"; then
+  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
+# Do some error checking and defaulting for the host and target type.
+# The inputs are:
+#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
+#
+# The rules are:
+# 1. You are not allowed to specify --host, --target, and nonopt at the
+#    same time.
+# 2. Host defaults to nonopt.
+# 3. If nonopt is not specified, then host defaults to the current host,
+#    as determined by config.guess.
+# 4. Target and build default to nonopt.
+# 5. If nonopt is not specified, then target and build default to host.
+
+# The aliases save the names the user supplied, while $host etc.
+# will get canonicalized.
+case $host---$target---$nonopt in
+NONE---*---* | *---NONE---* | *---*---NONE) ;;
+*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
+esac
+
+
+# Make sure we can run config.sub.
+if $ac_config_sub sun4 >/dev/null 2>&1; then :
+else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking host system type""... $ac_c" 1>&6
+echo "configure:575: checking host system type" >&5
+
+host_alias=$host
+case "$host_alias" in
+NONE)
+  case $nonopt in
+  NONE)
+    if host_alias=`$ac_config_guess`; then :
+    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
+    fi ;;
+  *) host_alias=$nonopt ;;
+  esac ;;
+esac
+
+host=`$ac_config_sub $host_alias`
+host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$host" 1>&6
+
+echo $ac_n "checking target system type""... $ac_c" 1>&6
+echo "configure:596: checking target system type" >&5
+
+target_alias=$target
+case "$target_alias" in
+NONE)
+  case $nonopt in
+  NONE) target_alias=$host_alias ;;
+  *) target_alias=$nonopt ;;
+  esac ;;
+esac
+
+target=`$ac_config_sub $target_alias`
+target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$target" 1>&6
+
+echo $ac_n "checking build system type""... $ac_c" 1>&6
+echo "configure:614: checking build system type" >&5
+
+build_alias=$build
+case "$build_alias" in
+NONE)
+  case $nonopt in
+  NONE) build_alias=$host_alias ;;
+  *) build_alias=$nonopt ;;
+  esac ;;
+esac
+
+build=`$ac_config_sub $build_alias`
+build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$build" 1>&6
+
+test "$host_alias" != "$target_alias" &&
+  test "$program_prefix$program_suffix$program_transform_name" = \
+    NONENONEs,x,x, &&
+  program_prefix=${target_alias}-
+
+
+# Find a good install program.  We prefer a C program (faster),
+# so one script is as good as another.  But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# ./install, which can be erroneously created by make from ./install.sh.
+echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
+echo "configure:648: checking for a BSD compatible install" >&5
+if test -z "$INSTALL"; then
+if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
+  for ac_dir in $PATH; do
+    # Account for people who put trailing slashes in PATH elements.
+    case "$ac_dir/" in
+    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
+    *)
+      # OSF1 and SCO ODT 3.0 have their own names for install.
+      for ac_prog in ginstall installbsd scoinst install; do
+        if test -f $ac_dir/$ac_prog; then
+         if test $ac_prog = install &&
+            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
+           # AIX install.  It has an incompatible calling convention.
+           # OSF/1 installbsd also uses dspmsg, but is usable.
+           :
+         else
+           ac_cv_path_install="$ac_dir/$ac_prog -c"
+           break 2
+         fi
+       fi
+      done
+      ;;
+    esac
+  done
+  IFS="$ac_save_IFS"
+
+fi
+  if test "${ac_cv_path_install+set}" = set; then
+    INSTALL="$ac_cv_path_install"
+  else
+    # As a last resort, use the slow shell script.  We don't cache a
+    # path for INSTALL within a source directory, because that will
+    # break other packages using the cache if that directory is
+    # removed, or if the path is relative.
+    INSTALL="$ac_install_sh"
+  fi
+fi
+echo "$ac_t""$INSTALL" 1>&6
+
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
+
+
+PACKAGE=gprof
+
+VERSION=2.8.1
+
+cat >> confdefs.h <<EOF
+#define PACKAGE "$PACKAGE"
+EOF
+
+cat >> confdefs.h <<EOF
+#define VERSION "$VERSION"
+EOF
+
+echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
+echo "configure:714: checking whether build environment is sane" >&5
+# Just in case
+sleep 1
+echo timestamp > conftestfile
+# Do `set' in a subshell so we don't clobber the current shell's
+# arguments.  Must try -L first in case configure is actually a
+# symlink; some systems play weird games with the mod time of symlinks
+# (eg FreeBSD returns the mod time of the symlink's containing
+# directory).
+if (
+   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
+   if test "" = "X"; then
+      # -L didn't work.
+      set X `ls -t $srcdir/configure conftestfile`
+   fi
+   test "$2" = conftestfile
+   )
+then
+   # Ok.
+   :
+else
+   { echo "configure: error: newly created file is older than distributed files!
+Check your system clock" 1>&2; exit 1; }
+fi
+rm -f conftest*
+echo "$ac_t""yes" 1>&6
+if test "$program_transform_name" = s,x,x,; then
+  program_transform_name=
+else
+  # Double any \ or $.  echo might interpret backslashes.
+  cat <<\EOF_SED > conftestsed
+s,\\,\\\\,g; s,\$,$$,g
+EOF_SED
+  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
+  rm -f conftestsed
+fi
+test "$program_prefix" != NONE &&
+  program_transform_name="s,^,${program_prefix},; $program_transform_name"
+# Use a double $ so make ignores it.
+test "$program_suffix" != NONE &&
+  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
+
+# sed with no file args requires a program.
+test "$program_transform_name" = "" && program_transform_name="s,x,x,"
+
+missing_dir=`cd $ac_aux_dir && pwd`
+echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
+echo "configure:761: checking for working aclocal" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if (aclocal --version) > /dev/null 2>&1; then
+   ACLOCAL=aclocal
+   echo "$ac_t""found" 1>&6
+else
+   ACLOCAL="$missing_dir/missing aclocal"
+   echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
+echo "configure:773: checking for working autoconf" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if (autoconf --version) > /dev/null 2>&1; then
+   AUTOCONF=autoconf
+   echo "$ac_t""found" 1>&6
+else
+   AUTOCONF="$missing_dir/missing autoconf"
+   echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working automake""... $ac_c" 1>&6
+echo "configure:785: checking for working automake" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if (automake --version) > /dev/null 2>&1; then
+   AUTOMAKE=automake
+   echo "$ac_t""found" 1>&6
+else
+   AUTOMAKE="$missing_dir/missing automake"
+   echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
+echo "configure:797: checking for working autoheader" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if (autoheader --version) > /dev/null 2>&1; then
+   AUTOHEADER=autoheader
+   echo "$ac_t""found" 1>&6
+else
+   AUTOHEADER="$missing_dir/missing autoheader"
+   echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
+echo "configure:809: checking for working makeinfo" >&5
+# Run test in a subshell; some versions of sh will print an error if
+# an executable is not found, even if stderr is redirected.
+if (makeinfo --version) > /dev/null 2>&1; then
+   MAKEINFO=makeinfo
+   echo "$ac_t""found" 1>&6
+else
+   MAKEINFO="$missing_dir/missing makeinfo"
+   echo "$ac_t""missing" 1>&6
+fi
+
+echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
+echo "configure:821: checking whether ${MAKE-make} sets \${MAKE}" >&5
+set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftestmake <<\EOF
+all:
+       @echo 'ac_maketemp="${MAKE}"'
+EOF
+# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
+if test -n "$ac_maketemp"; then
+  eval ac_cv_prog_make_${ac_make}_set=yes
+else
+  eval ac_cv_prog_make_${ac_make}_set=no
+fi
+rm -f conftestmake
+fi
+if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  SET_MAKE=
+else
+  echo "$ac_t""no" 1>&6
+  SET_MAKE="MAKE=${MAKE-make}"
+fi
+
+
 # Check whether --enable-shared or --disable-shared was given.
 if test "${enable_shared+set}" = set; then
   enableval="$enable_shared"
@@ -535,7 +858,7 @@ fi
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:539: checking for $ac_word" >&5
+echo "configure:862: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -564,7 +887,7 @@ if test -z "$CC"; then
   # Extract the first word of "cc", so it can be a program name with args.
 set dummy cc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:568: checking for $ac_word" >&5
+echo "configure:891: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -612,7 +935,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:616: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:939: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -622,11 +945,11 @@ ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS
 cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext <<EOF
-#line 626 "configure"
+#line 949 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:953: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -646,12 +969,12 @@ if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:650: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:973: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:655: checking whether we are using GNU C" >&5
+echo "configure:978: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -660,7 +983,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:664: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:987: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -675,7 +998,7 @@ if test $ac_cv_prog_gcc = yes; then
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:679: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1002: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -702,25 +1025,6 @@ else
   test "${CFLAGS+set}" = set || CFLAGS="-g"
 fi
 
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
 # Find a good install program.  We prefer a C program (faster),
 # so one script is as good as another.  But avoid the broken or
 # incompatible versions:
@@ -732,7 +1036,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:736: checking for a BSD compatible install" >&5
+echo "configure:1040: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -783,7 +1087,7 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
 
 
 echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:787: checking for POSIXized ISC" >&5
+echo "configure:1091: checking for POSIXized ISC" >&5
 if test -d /etc/conf/kconfig.d &&
   grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
 then
@@ -804,115 +1108,6 @@ else
 fi
 
 
-
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
-#
-# The rules are:
-# 1. You are not allowed to specify --host, --target, and nonopt at the
-#    same time.
-# 2. Host defaults to nonopt.
-# 3. If nonopt is not specified, then host defaults to the current host,
-#    as determined by config.guess.
-# 4. Target and build default to nonopt.
-# 5. If nonopt is not specified, then target and build default to host.
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-case $host---$target---$nonopt in
-NONE---*---* | *---NONE---* | *---*---NONE) ;;
-*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
-esac
-
-
-# Make sure we can run config.sub.
-if $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:836: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`$ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
-
-host=`$ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:857: checking target system type" >&5
-
-target_alias=$target
-case "$target_alias" in
-NONE)
-  case $nonopt in
-  NONE) target_alias=$host_alias ;;
-  *) target_alias=$nonopt ;;
-  esac ;;
-esac
-
-target=`$ac_config_sub $target_alias`
-target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$target" 1>&6
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:875: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
-  case $nonopt in
-  NONE) build_alias=$host_alias ;;
-  *) build_alias=$nonopt ;;
-  esac ;;
-esac
-
-build=`$ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-
-test "$host_alias" != "$target_alias" &&
-  test "$program_prefix$program_suffix$program_transform_name" = \
-    NONENONEs,x,x, &&
-  program_prefix=${target_alias}-
-
-if test "$program_transform_name" = s,x,x,; then
-  program_transform_name=
-else
-  # Double any \ or $.  echo might interpret backslashes.
-  cat <<\EOF_SED > conftestsed
-s,\\,\\\\,g; s,\$,$$,g
-EOF_SED
-  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
-  rm -f conftestsed
-fi
-test "$program_prefix" != NONE &&
-  program_transform_name="s,^,${program_prefix},; $program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
-  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
-
-# sed with no file args requires a program.
-test "$program_transform_name" = "" && program_transform_name="s,x,x,"
-
-
 case "${target}" in
 alpha-*-*)     MY_TARGET=alpha ;;
 i[3456]86-*-*) MY_TARGET=i386 ;;
@@ -1009,6 +1204,110 @@ esac
 
 
 
+# automake --cygnus requires these for some reason.
+echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
+echo "configure:1210: checking whether to enable maintainer-specific portions of Makefiles" >&5
+    # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
+if test "${enable_maintainer_mode+set}" = set; then
+  enableval="$enable_maintainer_mode"
+  USE_MAINTAINER_MODE=$enableval
+else
+  USE_MAINTAINER_MODE=no
+fi
+
+  echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
+  if test $USE_MAINTAINER_MODE = yes; then
+    MAINT=
+  else
+    MAINT='#M#'
+  fi
+  
+
+echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
+echo "configure:1228: checking how to run the C preprocessor" >&5
+# On Suns, sometimes $CPP names a directory.
+if test -n "$CPP" && test -d "$CPP"; then
+  CPP=
+fi
+if test -z "$CPP"; then
+if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+    # This must be in double quotes, not single quotes, because CPP may get
+  # substituted into the Makefile and "${CC-cc}" will confuse make.
+  CPP="${CC-cc} -E"
+  # On the NeXT, cc -E runs the code through the compiler's parser,
+  # not just through cpp.
+  cat > conftest.$ac_ext <<EOF
+#line 1243 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1249: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -E -traditional-cpp"
+  cat > conftest.$ac_ext <<EOF
+#line 1260 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1266: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP=/lib/cpp
+fi
+rm -f conftest*
+fi
+rm -f conftest*
+  ac_cv_prog_CPP="$CPP"
+fi
+  CPP="$ac_cv_prog_CPP"
+else
+  ac_cv_prog_CPP="$CPP"
+fi
+echo "$ac_t""$CPP" 1>&6
+
+echo $ac_n "checking for Cygwin32 environment""... $ac_c" 1>&6
+echo "configure:1289: checking for Cygwin32 environment" >&5
+cat > conftest.$ac_ext <<EOF
+#line 1291 "configure"
+#include "confdefs.h"
+
+#ifdef __CYGWIN32__
+lose
+#endif
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "lose" >/dev/null 2>&1; then
+  rm -rf conftest*
+  EXEEXT=.exe
+echo "$ac_t""yes" 1>&6
+else
+  rm -rf conftest*
+  EXEEXT=
+echo "$ac_t""no" 1>&6
+fi
+rm -f conftest*
+
+
+
 trap '' 1 2 15
 cat > confcache <<\EOF
 # This file is a shell script that caches the results of configure
@@ -1152,9 +1451,6 @@ s%@includedir@%$includedir%g
 s%@oldincludedir@%$oldincludedir%g
 s%@infodir@%$infodir%g
 s%@mandir@%$mandir%g
-s%@CC@%$CC%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
 s%@host@%$host%g
 s%@host_alias@%$host_alias%g
 s%@host_cpu@%$host_cpu%g
@@ -1170,10 +1466,25 @@ s%@build_alias@%$build_alias%g
 s%@build_cpu@%$build_cpu%g
 s%@build_vendor@%$build_vendor%g
 s%@build_os@%$build_os%g
+s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
+s%@INSTALL_DATA@%$INSTALL_DATA%g
+s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
+s%@PACKAGE@%$PACKAGE%g
+s%@VERSION@%$VERSION%g
+s%@ACLOCAL@%$ACLOCAL%g
+s%@AUTOCONF@%$AUTOCONF%g
+s%@AUTOMAKE@%$AUTOMAKE%g
+s%@AUTOHEADER@%$AUTOHEADER%g
+s%@MAKEINFO@%$MAKEINFO%g
+s%@SET_MAKE@%$SET_MAKE%g
+s%@CC@%$CC%g
 s%@MY_TARGET@%$MY_TARGET%g
 s%@BFDLIB@%$BFDLIB%g
 s%@HLDFLAGS@%$HLDFLAGS%g
 s%@HLDENV@%$HLDENV%g
+s%@MAINT@%$MAINT%g
+s%@CPP@%$CPP%g
+s%@EXEEXT@%$EXEEXT%g
 
 CEOF
 EOF
index 30bb9b237e8fbbbb8c5947a177c5f3ae870414bb..de86c6885ef7e842d5b5f5c0bfd29a5410975600 100644 (file)
@@ -2,6 +2,10 @@ dnl Process this file with autoconf to produce a configure script.
 AC_PREREQ(2.5)dnl
 AC_INIT(gprof.c)
 
+AC_CANONICAL_SYSTEM
+
+AM_INIT_AUTOMAKE(gprof, 2.8.1)
+
 AC_ARG_ENABLE(shared,
 [  --enable-shared         build shared BFD library],
 [case "${enableval}" in
@@ -16,9 +20,6 @@ AC_PROG_INSTALL
 
 AC_ISC_POSIX
 
-AC_CANONICAL_SYSTEM
-AC_ARG_PROGRAM
-
 case "${target}" in
 alpha-*-*)     MY_TARGET=alpha ;;
 changequote(,)dnl
@@ -117,4 +118,8 @@ esac
 AC_SUBST(HLDFLAGS)
 AC_SUBST(HLDENV)
 
+# automake --cygnus requires these for some reason.
+AM_MAINTAINER_MODE
+AM_CYGWIN32
+
 AC_OUTPUT(Makefile)