[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commits] r1483 - in /branches/eglibc-2_5/libc: ./ include/ stdio-common/ sunrpc/ sysdeps/unix/sysv/linux/



Author: jimb
Date: Fri Feb 16 14:38:13 2007
New Revision: 1483

Log:
	* Makefile: Amend make install-headers to install everything
	necessary for building a cross-compiler.  Install gnu/stubs.h as
	part of 'install-headers', not 'install-others'.
	If install-bootstrap-headers is 'yes', install a dummy copy of
	gnu/stubs.h, instead of computing the real thing.
	* include/stubs-bootstrap.h: New file.
	* sysdeps/unix/sysv/linux/Makefile: Install bits/syscall.h as part
	of 'install-headers' not 'install-others'.
	* stdio-common/Makefile: Similarly for bits/stdio_lim.h.
	* sunrpc/Makefile: Don't install generated headers if
	install-bootstrap-headers is 'yes'.

Added:
    branches/eglibc-2_5/libc/include/stubs-bootstrap.h
Modified:
    branches/eglibc-2_5/libc/ChangeLog.eglibc
    branches/eglibc-2_5/libc/Makefile
    branches/eglibc-2_5/libc/stdio-common/Makefile
    branches/eglibc-2_5/libc/sunrpc/Makefile
    branches/eglibc-2_5/libc/sysdeps/unix/sysv/linux/Makefile

Modified: branches/eglibc-2_5/libc/ChangeLog.eglibc
==============================================================================
--- branches/eglibc-2_5/libc/ChangeLog.eglibc (original)
+++ branches/eglibc-2_5/libc/ChangeLog.eglibc Fri Feb 16 14:38:13 2007
@@ -1,3 +1,17 @@
+2007-02-16  Jim Blandy  <jimb@xxxxxxxxxxxxxxxx>
+
+	* Makefile: Amend make install-headers to install everything
+	necessary for building a cross-compiler.  Install gnu/stubs.h as
+	part of 'install-headers', not 'install-others'.
+	If install-bootstrap-headers is 'yes', install a dummy copy of
+	gnu/stubs.h, instead of computing the real thing.
+	* include/stubs-bootstrap.h: New file.
+	* sysdeps/unix/sysv/linux/Makefile: Install bits/syscall.h as part
+	of 'install-headers' not 'install-others'.
+	* stdio-common/Makefile: Similarly for bits/stdio_lim.h.
+	* sunrpc/Makefile: Don't install generated headers if
+	install-bootstrap-headers is 'yes'.
+
 2007-02-15  Khem Raj  <kraj@xxxxxxxxxx>
 
 	* sysdeps/unix/sysv/linux/i386/sysdep.h: Re-define __i686.

Modified: branches/eglibc-2_5/libc/Makefile
==============================================================================
--- branches/eglibc-2_5/libc/Makefile (original)
+++ branches/eglibc-2_5/libc/Makefile Fri Feb 16 14:38:13 2007
@@ -78,7 +78,7 @@
 vpath %.h $(subdir-dirs)
 
 # What to install.
-install-others = $(inst_includedir)/gnu/stubs.h
+install-headers: $(inst_includedir)/gnu/stubs.h
 install-bin-script =
 
 ifeq (yes,$(build-shared))
@@ -158,6 +158,16 @@
 
 subdir-stubs := $(foreach dir,$(subdirs),$(common-objpfx)$(dir)/stubs)
 
+# gnu/stubs.h depends (via the subdir 'stubs' targets) on all the .o
+# files in EGLIBC.  For bootstrapping a GCC/EGLIBC pair, an empty
+# gnu/stubs.h is good enough.
+ifeq ($(install-bootstrap-headers),yes)
+$(inst_includedir)/gnu/stubs.h: include/stubs-bootstrap.h $(+force)
+	$(make-target-directory)
+	$(INSTALL_DATA) $< $@
+
+installed-stubs = 
+else 
 ifeq ($(biarch),no)
 installed-stubs = $(inst_includedir)/gnu/stubs.h
 else
@@ -168,6 +178,7 @@
 	$(INSTALL_DATA) $< $@
 
 install-others-nosubdir: $(installed-stubs)
+endif
 endif
 
 

Added: branches/eglibc-2_5/libc/include/stubs-bootstrap.h
==============================================================================
--- branches/eglibc-2_5/libc/include/stubs-bootstrap.h (added)
+++ branches/eglibc-2_5/libc/include/stubs-bootstrap.h Fri Feb 16 14:38:13 2007
@@ -1,0 +1,12 @@
+/* Placeholder stubs.h file for bootstrapping.
+
+   When bootstrapping a GCC/EGLIBC pair, GCC requires that the EGLIBC
+   headers be installed, but we can't fully build EGLIBC without that
+   GCC.  So we run the command:
+
+      make install-headers install-bootstrap-headers=yes
+
+   to install the headers GCC needs, but avoid building certain
+   difficult headers.  The <gnu/stubs.h> header depends, via the
+   EGLIBC subdir 'stubs' make targets, on every .o file in EGLIBC, but
+   an empty stubs.h like this will do fine for GCC.  */

Modified: branches/eglibc-2_5/libc/stdio-common/Makefile
==============================================================================
--- branches/eglibc-2_5/libc/stdio-common/Makefile (original)
+++ branches/eglibc-2_5/libc/stdio-common/Makefile Fri Feb 16 14:38:13 2007
@@ -36,9 +36,9 @@
 	remove rename renameat						      \
 	flockfile ftrylockfile funlockfile
 
-install-others = $(inst_includedir)/bits/stdio_lim.h
+include ../Makeconfig
 
-include ../Makeconfig
+install-headers-nosubdir: $(inst_includedir)/bits/stdio_lim.h
 
 aux	:= errlist siglist printf-parsemb printf-parsewc fxprintf
 distribute := _itoa.h _itowa.h _i18n_number.h \

Modified: branches/eglibc-2_5/libc/sunrpc/Makefile
==============================================================================
--- branches/eglibc-2_5/libc/sunrpc/Makefile (original)
+++ branches/eglibc-2_5/libc/sunrpc/Makefile Fri Feb 16 14:38:13 2007
@@ -99,6 +99,7 @@
 endif
 
 ifeq (no,$(cross-compiling))
+ifneq (yes,$(install-bootstrap-headers))
 # We can only build this library if we can run the rpcgen we build.
 headers += $(rpcsvc:%.x=rpcsvc/%.h)
 extra-libs := librpcsvc
@@ -106,6 +107,7 @@
 librpcsvc-routines = $(rpcsvc:%.x=x%)
 librpcsvc-inhibit-o = .os # Build no shared rpcsvc library.
 omit-deps = $(librpcsvc-routines)
+endif
 endif
 
 CFLAGS-xbootparam_prot.c = -Wno-unused $(PIC-ccflag)

Modified: branches/eglibc-2_5/libc/sysdeps/unix/sysv/linux/Makefile
==============================================================================
--- branches/eglibc-2_5/libc/sysdeps/unix/sysv/linux/Makefile (original)
+++ branches/eglibc-2_5/libc/sysdeps/unix/sysv/linux/Makefile Fri Feb 16 14:38:13 2007
@@ -26,7 +26,7 @@
 		  sys/ultrasound.h sys/raw.h sys/personality.h sys/epoll.h \
 		  bits/a.out.h sys/inotify.h
 
-install-others += $(inst_includedir)/bits/syscall.h
+install-headers-nosubdir: $(inst_includedir)/bits/syscall.h
 
 tests += tst-clone