This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

initial patch to install libiberty headers



Here's the result of the dozen-odd public and private emails generated
in response to <URL:http://gcc.gnu.org/ml/gcc/2001-01/msg00087.html>.
Cc'ing DJ as the libiberty maintainer.

This will install the headers used by libiberty in prefix/include/libiberty.
Comments?



Index: Makefile.in
===================================================================
RCS file: /cvs/gcc/gcc/libiberty/Makefile.in,v
retrieving revision 1.57
diff -u -3 -r1.57 Makefile.in
--- Makefile.in	2000/12/08 23:16:27	1.57
+++ Makefile.in	2001/01/05 23:53:44
@@ -48,6 +48,7 @@
 INSTALL = @INSTALL@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
 INSTALL_DATA = @INSTALL_DATA@
+mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs
 
 AR = @AR@
 AR_FLAGS = rc
@@ -62,6 +63,7 @@
 MAKEOVERRIDES =
 
 TARGETLIB = libiberty.a
+target_header_dir = $(prefix)/include/libiberty 
 
 LIBOBJS = @LIBOBJS@
 ALLOCA = @ALLOCA@
@@ -121,6 +123,15 @@
 # Include files that are in this directory.
 HFILES = alloca-conf.h
 
+# Include files not necessarily in this directory which must be installed.
+TARGET_HFILES = config.h $(INCDIR)/demangle.h                                 \
+	$(INCDIR)/dyn-string.h $(INCDIR)/floatformat.h $(INCDIR)/fnmatch.h    \
+	$(INCDIR)/getopt.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h          \
+	$(INCDIR)/md5.h $(INCDIR)/objalloc.h $(INCDIR)/obstack.h              \
+	$(INCDIR)/partition.h $(INCDIR)/safe-ctype.h $(INCDIR)/sort.h         \
+	$(INCDIR)/splay-tree.h $(INCDIR)/symcat.h                             \
+	$(srcdir)/alloca-conf.h
+
 # NOTE: If you add new files to the library, add them to this list
 # (alphabetical), and add them to REQUIRED_OFILES or funcs in
 # configure.in.
@@ -151,6 +162,9 @@
 	  $(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS) $(ALLOCA)
 	$(RANLIB) $(TARGETLIB)
 
+installdirs:
+	$(mkinstalldirs) $(target_header_dir)
+
 INSTALL_DEST = @INSTALL_DEST@
 install: install_to_$(INSTALL_DEST) install-subdir
 
@@ -158,6 +172,10 @@
 	$(INSTALL_DATA) $(TARGETLIB) $(libdir)$(MULTISUBDIR)/$(TARGETLIB)n
 	( cd $(libdir)$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
 	mv -f $(libdir)$(MULTISUBDIR)/$(TARGETLIB)n $(libdir)$(MULTISUBDIR)/$(TARGETLIB)
+	$(mkinstalldirs) $(target_header_dir)
+	for h in $(TARGET_HFILES); do \
+	  $(INSTALL_DATA) $$h $(target_header_dir) ; \
+	done
 	@$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
 
 install_to_tooldir: all


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]