/[pkg-glibc]/glibc-package/branches/glibc-2.19/debian/patches/any/local-bootstrap-headers.diff
ViewVC logotype

Contents of /glibc-package/branches/glibc-2.19/debian/patches/any/local-bootstrap-headers.diff

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6146 - (show annotations) (download)
Wed Jun 11 21:37:33 2014 UTC (2 months, 2 weeks ago) by aurel32
File size: 2621 byte(s)
patches/any/local-bootstrap-headers.diff: new patch from eglibc tree
to ease header installation when bootstrapping.
1 Taken from EGLIBC, r1484 + r1525
2
3 2007-02-20 Jim Blandy <jimb@codesourcery.com>
4
5 * Makefile (install-headers): Preserve old behavior: depend on
6 $(inst_includedir)/gnu/stubs.h only if install-bootstrap-headers
7 is set; otherwise, place gnu/stubs.h on the 'install-others' list.
8
9 2007-02-16 Jim Blandy <jimb@codesourcery.com>
10
11 * Makefile: Amend make install-headers to install everything
12 necessary for building a cross-compiler. Install gnu/stubs.h as
13 part of 'install-headers', not 'install-others'.
14 If install-bootstrap-headers is 'yes', install a dummy copy of
15 gnu/stubs.h, instead of computing the real thing.
16 * include/stubs-bootstrap.h: New file.
17
18
19 --- /dev/null
20 +++ b/include/stubs-bootstrap.h
21 @@ -0,0 +1,12 @@
22 +/* Placeholder stubs.h file for bootstrapping.
23 +
24 + When bootstrapping a GCC/GLIBC pair, GCC requires that the GLIBC
25 + headers be installed, but we can't fully build EGLIBC without that
26 + GCC. So we run the command:
27 +
28 + make install-headers install-bootstrap-headers=yes
29 +
30 + to install the headers GCC needs, but avoid building certain
31 + difficult headers. The <gnu/stubs.h> header depends, via the
32 + GLIBC subdir 'stubs' make targets, on every .o file in GLIBC, but
33 + an empty stubs.h like this will do fine for GCC. */
34 --- a/Makefile
35 +++ b/Makefile
36 @@ -68,9 +68,18 @@
37 vpath %.h $(subdir-dirs)
38
39 # What to install.
40 -install-others = $(inst_includedir)/gnu/stubs.h
41 install-bin-script =
42
43 +# If we're bootstrapping, install a dummy gnu/stubs.h along with the
44 +# other headers, so 'make install-headers' produces a useable include
45 +# tree. Otherwise, install gnu/stubs.h later, after the rest of the
46 +# build is done.
47 +ifeq ($(install-bootstrap-headers),yes)
48 +install-headers: $(inst_includedir)/gnu/stubs.h
49 +else
50 +install-others = $(inst_includedir)/gnu/stubs.h
51 +endif
52 +
53 ifeq (yes,$(build-shared))
54 headers += gnu/lib-names.h
55 endif
56 @@ -150,6 +159,16 @@
57
58 subdir-stubs := $(foreach dir,$(subdirs),$(common-objpfx)$(dir)/stubs)
59
60 +# gnu/stubs.h depends (via the subdir 'stubs' targets) on all the .o
61 +# files in EGLIBC. For bootstrapping a GCC/EGLIBC pair, an empty
62 +# gnu/stubs.h is good enough.
63 +ifeq ($(install-bootstrap-headers),yes)
64 +$(inst_includedir)/gnu/stubs.h: include/stubs-bootstrap.h $(+force)
65 + $(make-target-directory)
66 + $(INSTALL_DATA) $< $@
67 +
68 +installed-stubs =
69 +else
70 ifndef abi-variants
71 installed-stubs = $(inst_includedir)/gnu/stubs.h
72 else
73 @@ -176,6 +195,7 @@
74
75 install-others-nosubdir: $(installed-stubs)
76 endif
77 +endif
78
79
80 # Since stubs.h is never needed when building the library, we simplify the

  ViewVC Help
Powered by ViewVC 1.1.5