summaryrefslogtreecommitdiff
path: root/libiberty/Makefile.in
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>2000-02-22 16:14:35 +0000
committerIan Lance Taylor <ian@airs.com>2000-02-22 16:14:35 +0000
commit0c0a36a40386d288fe8d6d86efc2b178ef7eb465 (patch)
treeb3724fb2dc3695a219f27800279c7e3041e2131b /libiberty/Makefile.in
parentabd8680d6efd97e7ba848a6392ee3ad72be18cd0 (diff)
downloadbinutils-gdb-0c0a36a40386d288fe8d6d86efc2b178ef7eb465.tar.gz
merge with libiberty from egcs 2000-02-22
Diffstat (limited to 'libiberty/Makefile.in')
-rw-r--r--libiberty/Makefile.in95
1 files changed, 67 insertions, 28 deletions
diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in
index 3ea80d07499..cc25df5f3f9 100644
--- a/libiberty/Makefile.in
+++ b/libiberty/Makefile.in
@@ -1,6 +1,6 @@
#
# Makefile
-# Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 97, 1998
+# Copyright (C) 1990, 91 - 99, 2000
# Free Software Foundation
#
# This file is part of the libiberty library.
@@ -85,25 +85,37 @@ FLAGS_TO_PASS = \
"LDFLAGS=$(LDFLAGS)" \
"LOADLIBES=$(LOADLIBES)" \
"RANLIB=$(RANLIB)" \
- "SHELL=$(SHELL)"
+ "SHELL=$(SHELL)" \
+ "prefix=$(prefix)" \
+ "exec_prefix=$(exec_prefix)" \
+ "libdir=$(libdir)" \
+ "libsubdir=$(libsubdir)" \
+ "tooldir=$(tooldir)"
-all: stamp-picdir $(TARGETLIB) needed-list required-list
+# Subdirectories to recurse into. We need to override this during cleaning
+SUBDIRS = testsuite
+
+all: stamp-picdir $(TARGETLIB) needed-list required-list all-subdir
@$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=all
.PHONY: check installcheck
-check installcheck:
+check: check-subdir
+installcheck: installcheck-subdir
@host_makefile_frag@
INCDIR=$(srcdir)/$(MULTISRCTOP)../include
-COMPILE.c = $(CC) -c @DEFS@ $(LIBCFLAGS) -I. -I$(INCDIR) $(HDEFINES)
+COMPILE.c = $(CC) -c @DEFS@ $(LIBCFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiberty_warn_cflags@
.c.o:
test x"$(enable_shared)" != xyes || \
$(COMPILE.c) $(PICFLAG) $< -o pic/$@
$(COMPILE.c) $<
-info install-info clean-info dvi:
+info: info-subdir
+install-info: install-info-subdir
+clean-info: clean-info-subdir
+dvi: dvi-subdir
# Include files that are in this directory.
HFILES = alloca-conf.h
@@ -112,22 +124,22 @@ HFILES = alloca-conf.h
# (alphabetical), and add them to REQUIRED_OFILES or funcs in
# configure.in.
CFILES = asprintf.c alloca.c argv.c atexit.c basename.c bcmp.c bcopy.c \
- bzero.c choose-temp.c clock.c concat.c cplus-dem.c fdmatch.c \
- fnmatch.c getcwd.c getopt.c getopt1.c getpagesize.c \
- getruntime.c floatformat.c hex.c index.c insque.c memchr.c \
+ bzero.c calloc.c choose-temp.c clock.c concat.c cplus-dem.c fdmatch.c \
+ fnmatch.c getcwd.c getpwd.c getopt.c getopt1.c getpagesize.c \
+ getruntime.c floatformat.c hashtab.c hex.c index.c insque.c memchr.c \
memcmp.c memcpy.c memmove.c memset.c mkstemps.c objalloc.c obstack.c \
- pexecute.c random.c rename.c rindex.c sigsetmask.c spaces.c \
- splay-tree.c strcasecmp.c strncasecmp.c strchr.c strdup.c strerror.c \
- strrchr.c strsignal.c strstr.c strtod.c strtol.c strtoul.c \
+ pexecute.c putenv.c random.c rename.c rindex.c setenv.c sigsetmask.c \
+ spaces.c splay-tree.c strcasecmp.c strncasecmp.c strchr.c strdup.c \
+ strerror.c strrchr.c strsignal.c strstr.c strtod.c strtol.c strtoul.c \
tmpnam.c vasprintf.c vfork.c vfprintf.c vprintf.c vsprintf.c \
- waitpid.c xatexit.c xexit.c xmalloc.c xstrdup.c xstrerror.c
+ waitpid.c xatexit.c xexit.c xmalloc.c xmemdup.c xstrdup.c xstrerror.c
# These are always included in the library.
REQUIRED_OFILES = argv.o choose-temp.o concat.o cplus-dem.o \
- fdmatch.o fnmatch.o getopt.o getopt1.o getruntime.o hex.o \
- floatformat.o objalloc.o obstack.o pexecute.o spaces.o \
+ fdmatch.o fnmatch.o getopt.o getopt1.o getpwd.o getruntime.o hashtab.o \
+ hex.o floatformat.o objalloc.o obstack.o pexecute.o spaces.o \
splay-tree.o strerror.o strsignal.o xatexit.o xexit.o xmalloc.o \
- xstrdup.o xstrerror.o
+ xmemdup.o xstrdup.o xstrerror.o
$(TARGETLIB): $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) $(ALLOCA)
rm -f $(TARGETLIB)
@@ -136,7 +148,7 @@ $(TARGETLIB): $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) $(ALLOCA)
$(RANLIB) $(TARGETLIB)
INSTALL_DEST = @INSTALL_DEST@
-install: install_to_$(INSTALL_DEST)
+install: install_to_$(INSTALL_DEST) install-subdir
install_to_libdir: all
$(INSTALL_DATA) $(TARGETLIB) $(libdir)$(MULTISUBDIR)/$(TARGETLIB)n
@@ -150,13 +162,21 @@ install_to_tooldir: all
mv -f $(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n $(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)
@$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
-# needed-list is used by libstdc++.
+# needed-list is used by libstdc++. NEEDED is the list of functions
+# to include there. Do not add anything LGPL to this list; libstdc++
+# can't use anything encumbering.
+NEEDED = atexit calloc memchr memcmp memcpy memmove memset rename strchr \
+ strerror strrchr strstr strtol strtoul tmpnam vfprintf vprintf \
+ vfork waitpid bcmp bcopy bzero
needed-list: Makefile
- f="$(LIBOBJS) $(ALLOCA) $(EXTRA_OFILES)"; \
- case $$f in \
- *alloca.o*) f="$$f xmalloc.o xexit.o" ;; \
- esac; \
- echo $$f > needed-list
+ rm -f needed-list; touch needed-list; \
+ for f in $(NEEDED); do \
+ for g in $(LIBOBJS) $(EXTRA_OFILES); do \
+ case "$$g" in \
+ *$$f*) echo $$g >> needed-list ;; \
+ esac; \
+ done; \
+ done
# required-list was used when building a shared bfd/opcodes/libiberty
# library. I don't know if it used by anything currently.
@@ -171,7 +191,7 @@ stamp-picdir:
.PHONY: all etags tags ls clean stage1 stage2
-etags tags: TAGS
+etags tags: TAGS etags-subdir
TAGS: $(CFILES) $(HFILES)
etags `for i in $(HFILES) $(CFILES); do echo $(srcdir)/$$i ; done`
@@ -187,19 +207,24 @@ ls:
# Need to deal with profiled libraries, too.
-mostlyclean:
+# Cleaning has to be done carefully to ensure that we don't clean our SUBDIRS
+# multiple times, hence our explicit recursion with an empty SUBDIRS.
+mostlyclean: mostlyclean-subdir
rm -rf *.o pic core errs \#* *.E a.out
rm -f needed.awk needed2.awk errors dummy needed-list config.h stamp-*
rm -f $(CONFIG_H) $(NEEDED_LIST) stamp-picdir
@$(MULTICLEAN) multi-clean DO=mostlyclean
-clean: mostlyclean
+clean: clean-subdir
+ $(MAKE) SUBDIRS="" mostlyclean
rm -f *.a required-list tmpmulti.out
@$(MULTICLEAN) multi-clean DO=clean
-distclean: clean
+distclean: distclean-subdir
+ $(MAKE) SUBDIRS="" clean
@$(MULTICLEAN) multi-clean DO=distclean
rm -f *~ Makefile config.status xhost-mkfrag TAGS multilib.out
rm -f config.log
-maintainer-clean realclean: distclean
+maintainer-clean realclean: maintainer-clean-subdir
+ $(MAKE) SUBDIRS="" distclean
force:
@@ -213,6 +238,16 @@ stamp-h: config.in config.status
config.status: $(srcdir)/configure $(srcdir)/config.table
$(SHELL) ./config.status --recheck
+
+all-subdir check-subdir installcheck-subdir info-subdir \
+install-info-subdir clean-info-subdir dvi-subdir install-subdir \
+etags-subdir mostlyclean-subdir clean-subdir distclean-subdir \
+maintainer-clean-subdir:
+ @target=`echo $@ | sed -e 's/-subdir//'`; \
+ for dir in . $(SUBDIRS) ; do \
+ test $$dir = . || (cd $$dir && $(MAKE) $$target) || exit 1; \
+ done
+
$(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) $(ALLOCA): stamp-picdir
alloca.o: config.h
@@ -229,6 +264,7 @@ getcwd.o: config.h
getopt.o: config.h $(INCDIR)/getopt.h
getopt1.o: config.h $(INCDIR)/getopt.h
getpagesize.o: config.h
+getpwd.o: config.h $(INCDIR)/libiberty.h
getruntime.o: config.h $(INCDIR)/libiberty.h
hex.o: $(INCDIR)/libiberty.h
floatformat.o: $(INCDIR)/floatformat.h
@@ -236,6 +272,7 @@ mkstemps.o: config.h
objalloc.o: $(INCDIR)/objalloc.h
obstack.o: config.h $(INCDIR)/obstack.h
pexecute.o: config.h $(INCDIR)/libiberty.h
+setenv.o: config.h
spaces.o: $(INCDIR)/libiberty.h
splay-tree.o: config.h $(INCDIR)/libiberty.h $(INCDIR)/splay-tree.h $(INCDIR)/ansidecl.h
strerror.o: config.h $(INCDIR)/libiberty.h
@@ -243,5 +280,7 @@ strsignal.o: config.h $(INCDIR)/libiberty.h
xatexit.o: $(INCDIR)/libiberty.h
xexit.o: $(INCDIR)/libiberty.h
xmalloc.o: $(INCDIR)/libiberty.h
+xmemdup.o: config.h $(INCDIR)/libiberty.h
xstrdup.o: config.h $(INCDIR)/libiberty.h
xstrerror.o: config.h $(INCDIR)/libiberty.h
+hashtab.o: config.h $(INCDIR)/libiberty.h $(INCDIR)/hashtab.h $(INCDIR)/ansidecl.h