*** empty log message ***
[deliverable/binutils-gdb.git] / mmalloc / Makefile.in
index c7c1abaa3788bd5c1fda23ada78e766c9b7547b7..cde39897aaa01b06116c26789a64ad015796f750 100644 (file)
@@ -13,8 +13,8 @@
 
 # You should have received a copy of the GNU Library General Public
 # License along with the GNU C Library; see the file COPYING.LIB.  If
-# not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-# Cambridge, MA 02139, USA.
+# not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
 
 #
 # Makefile for mmalloc directory
 
 # Directory containing source files.  Don't clean up the spacing,
 # this exact string is matched for by the "configure" script.
-srcdir = .
 
-prefix =       /usr/local
+VPATH = @srcdir@
+srcdir = @srcdir@
 
-exec_prefix = $(prefix)
+prefix =       @prefix@
+exec_prefix =  @exec_prefix@
 
-bindir =       $(exec_prefix)/bin
-libdir =       $(exec_prefix)/lib
+bindir =       @bindir@
+libdir =       @libdir@
 
-datadir =      $(prefix)/lib
-mandir =       $(prefix)/man
+datadir =      @datadir@
+mandir =       @mandir@
 man1dir =      $(mandir)/man1
 man2dir =      $(mandir)/man2
 man3dir =      $(mandir)/man3
@@ -42,29 +43,35 @@ man6dir =   $(mandir)/man6
 man7dir =      $(mandir)/man7
 man8dir =      $(mandir)/man8
 man9dir =      $(mandir)/man9
-infodir =      $(prefix)/info
-includedir =   $(prefix)/include
-docdir =       $(datadir)/doc
+infodir =      @infodir@
+includedir =   @includedir@
 
-SHELL =                /bin/sh
+SHELL =                @SHELL@
 
-INSTALL =      install -c
-INSTALL_PROGRAM = $(INSTALL)
-INSTALL_DATA = $(INSTALL)
+INSTALL =      @INSTALL@
+INSTALL_PROGRAM=@INSTALL_PROGRAM@
+INSTALL_DATA = @INSTALL_DATA@
 
-AR =           ar
+AR =           @AR@
 AR_FLAGS =     qv
 CFLAGS =       -g
-BISON =                bison
 MAKEINFO =     makeinfo
-RANLIB =       ranlib
+RANLIB =       @RANLIB@
 RM =           rm
 
+# where to find makeinfo
+MAKEINFO=makeinfo
+
+SET_TEXINPUTS = TEXINPUTS=${TEXIDIR}:.:$(srcdir):$(READLINE_DIR):$$TEXINPUTS
+
+# The TeX formatter
+TEX = tex
+
 TARGETLIB =    libmmalloc.a
 
 CFILES =       mcalloc.c mfree.c mmalloc.c mmcheck.c mmemalign.c mmstats.c \
                mmtrace.c mrealloc.c mvalloc.c mmap-sup.c attach.c detach.c \
-               keys.c sbrk-sup.c
+               keys.c sbrk-sup.c mm.c
 
 HFILES =       mmalloc.h
 
@@ -72,11 +79,15 @@ OFILES =    mcalloc.o mfree.o mmalloc.o mmcheck.o mmemalign.o mmstats.o \
                mmtrace.o mrealloc.o mvalloc.o mmap-sup.o attach.o detach.o \
                keys.o sbrk-sup.o
 
-#### Host, target, and site specific Makefile fragments come in here.
-###
+DEFS =         @DEFS@
+
+# The current default is to build a single object module with all the mmalloc
+# functions.  To build a more traditional library, flip this macro definition.
+#TARGETOBJS =  $(OFILES)
+TARGETOBJS =   mm.o
 
 .c.o:
-       $(CC) -c $(CFLAGS) -I. -I$(srcdir)/../include $(HDEFINES) $<
+               $(CC) -c $(CFLAGS) $(DEFS) -I. -I$(srcdir)/../include $<
 
 # Do we want/need any config overrides?
 #       
@@ -85,24 +96,49 @@ STAGESTUFF =        $(TARGETLIB) *.o
 
 all:           $(TARGETLIB)
 
-info:
+info: mmalloc.info
+dvi: mmalloc.dvi
 clean-info:
-install-info:
-dvi:
 installcheck:
-check:
+
+mmalloc.info: mmalloc.texi
+       $(MAKEINFO) -I $(srcdir) -o ./mmalloc.info mmalloc.texi
+
+# This file doesn't need texindex currently.
+mmalloc.dvi: mmalloc.texi
+       $(SET_TEXINPUTS) $(TEX) mmalloc.texi
+       rm -f mmalloc.?? mmalloc.??s mmalloc.log mmalloc.aux mmalloc.toc
+
+install-info: info
+       $(SHELL) $(srcdir)/../mkinstalldirs $(infodir)
+       if test ! -f mmalloc.info ; then cd $(srcdir); fi; \
+       $(INSTALL_DATA) mmalloc.info $(infodir)/mmalloc.info
+       @if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
+         echo " install-info --info-dir=$(infodir) $(infodir)/mmalloc.info";\
+         install-info --info-dir=$(infodir) $(infodir)/mmalloc.info || :;\
+       else : ; fi
+
+check: test1.c
+#      $(CC) -g $(srcdir)/test1.c libmmalloc.a
+# This loses for Canadian cross (building mmalloc with a cross-compiler).
+# There is probably some dejagnu-ish solution (such as what we are doing
+# for gdb, perhaps).
+#      ./a.out
 
 install:       all
-               $(INSTALL_DATA) $(TARGETLIB) $(libdir)/$(TARGETLIB).n
-               $(RANLIB) $(libdir)/$(TARGETLIB).n
-               mv -f $(libdir)/$(TARGETLIB).n $(libdir)/$(TARGETLIB)
+               $(INSTALL_DATA) $(TARGETLIB) $(libdir)/$(TARGETLIB)n
+               $(RANLIB) $(libdir)/$(TARGETLIB)n
+               mv -f $(libdir)/$(TARGETLIB)n $(libdir)/$(TARGETLIB)
 
-$(TARGETLIB):  $(OFILES)
+$(TARGETLIB):  $(TARGETOBJS)
                $(RM) -rf $@
-               $(AR) $(AR_FLAGS) $@ $(OFILES)
+               $(AR) $(AR_FLAGS) $@ $(TARGETOBJS)
                $(RANLIB) $@
 
-$(OFILES) :    $(HFILES)
+$(OFILES) :    $(HFILES) Makefile
+
+mm.o:          $(HFILES) $(CFILES)
+               $(CC) -c $(CFLAGS) $(DEFS) -I. -I$(srcdir)/../include $(srcdir)/mm.c
 
 .always.:
 # Do nothing.
@@ -159,12 +195,19 @@ ls:
 mostlyclean clean:
                rm -f *.a *.o core errs *~ \#* TAGS *.E a.out errors 
 
-distclean realclean:   clean 
-               rm -f config.status
+distclean:     clean 
+               rm -f config.cache config.log config.status
                rm -f Makefile depend
 
+maintainer-clean realclean: distclean clean
+               @echo "This command is intended for maintainers to use;"
+               @echo "it deletes files that may require special tools to rebuild."
+               rm -f mmalloc.info
+
 force:
 
-Makefile:      $(srcdir)/Makefile.in $(host_makefile_frag) \
-               $(target_makefile_frag)
-               $(SHELL) ./config.status
+Makefile:      Makefile.in config.status
+               $(SHELL) config.status
+
+config.status: configure
+               $(SHELL) config.status --recheck
This page took 0.03561 seconds and 4 git commands to generate.