summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-10-07 20:01:04 +0000
committerMike Frysinger <vapier@gentoo.org>2011-10-07 20:01:04 +0000
commit7025a569241df19f375748199b3c8406e63d1f7c (patch)
tree9a35ab4e6d221bb870afe7d758fc549f20e89922 /app-shells
parentremove old (diff)
downloadhistorical-7025a569241df19f375748199b3c8406e63d1f7c.tar.gz
historical-7025a569241df19f375748199b3c8406e63d1f7c.tar.bz2
historical-7025a569241df19f375748199b3c8406e63d1f7c.zip
Fix parallel build issues with parse.y and version.h/syntax.c.
Package-Manager: portage-2.2.0_alpha59/cvs/Linux x86_64
Diffstat (limited to 'app-shells')
-rw-r--r--app-shells/bash/ChangeLog6
-rw-r--r--app-shells/bash/Manifest13
-rw-r--r--app-shells/bash/bash-4.2_p10.ebuild3
-rw-r--r--app-shells/bash/files/bash-4.2-parallel-build.patch68
4 files changed, 82 insertions, 8 deletions
diff --git a/app-shells/bash/ChangeLog b/app-shells/bash/ChangeLog
index 341e66d3b211..5ba11d4b51c4 100644
--- a/app-shells/bash/ChangeLog
+++ b/app-shells/bash/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for app-shells/bash
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.291 2011/09/16 17:25:35 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/ChangeLog,v 1.292 2011/10/07 20:01:04 vapier Exp $
+
+ 07 Oct 2011; Mike Frysinger <vapier@gentoo.org> bash-4.2_p10.ebuild,
+ +files/bash-4.2-parallel-build.patch:
+ Fix parallel build issues with parse.y and version.h/syntax.c.
16 Sep 2011; Mike Frysinger <vapier@gentoo.org> bash-4.2_p10.ebuild,
+files/bash-4.2-execute-job-control.patch:
diff --git a/app-shells/bash/Manifest b/app-shells/bash/Manifest
index b432cd71388f..478f7947cc9e 100644
--- a/app-shells/bash/Manifest
+++ b/app-shells/bash/Manifest
@@ -26,6 +26,7 @@ AUX bash-4.0-parallel-build.patch 2237 RMD160 82aa28d48f12978cbaea7ebed987d13f53
AUX bash-4.1-fbsd-eaccess.patch 843 RMD160 50e06a8ec83fa756a9749ab5011696e737731afe SHA1 9468675bdb345c01f6a285d76526e851de63a895 SHA256 42a4ee58b0d2fd529e25fcc3ca10d17bbac2c91fd8bcb191d70c788f0b55fb95
AUX bash-4.1-parallel-build.patch 829 RMD160 371bd2d62a0b70c4305697975780165e02f2b38d SHA1 9978a6ed4668509660491799bbbc5b7d6ad2cbd9 SHA256 0da60b91e4fb2326137a4dde6d8937592b6efea45de51194ca1770127637e652
AUX bash-4.2-execute-job-control.patch 865 RMD160 8666b45a33ce11212a61c68a0e01a21ad1603c0e SHA1 4a154d9ac4c6ea1ff8e653fb13df462519a6a63f SHA256 0b6fc0d467662dd85daa02ba8d50ea612cf4c5274d685d52eb1533b5f164b056
+AUX bash-4.2-parallel-build.patch 2791 RMD160 fa41b6808c337a980cb5768efd7fb7c18a7a9af6 SHA1 ef5c7d413c0f650038ee55418ac52574466cd6df SHA256 d7daa6776c4d93603ae1343f16ca6d35578ff893b47326223a0540924e0ecf91
AUX bash-4.2-print-heredoc.patch 854 RMD160 5d3fc358a9f9500baf3a83378ca8c935ee0b34df SHA1 70ffe49e867222cc5877edcacaee9842080d6375 SHA256 a686e71f9ab788015fa80eb448252eeedc2d8f8e97b0fc0c66c0d3f3088e87b4
AUX bash-4.x-deferred-heredocs.patch 1255 RMD160 69e3554d225e5a85be3f874b0bb0139c0e24c9b9 SHA1 b8d492af021ae59c9799dfbb169842c23ed9f826 SHA256 845ffcd7035eef5dc029747f211a737e0260b53b16086a37fb3c8ab3609a7d36
AUX bash_logout 205 RMD160 fa6064b67bd02cf66dc490759442a0127770d420 SHA1 a6983665cc842bde96fbc8811be89cf8fda71a45 SHA256 15aaded954389c05d7de5d36c4887db61975ad52c87ad78baf1062ec8997289d
@@ -173,14 +174,14 @@ EBUILD bash-4.1_p10.ebuild 5660 RMD160 9c0a3d574b1dbf873e26ea223c73c70abc042473
EBUILD bash-4.1_p11.ebuild 5660 RMD160 307a3558a0b42808eacdd776841833cc40606d3d SHA1 ee713343156ba0e3789dd45a29903667febd4c22 SHA256 954e2b6d897a4e54fb2bde0c62da5af886c076aea6890fbfe6b8a9053f532ccc
EBUILD bash-4.1_p7.ebuild 5647 RMD160 d304c9b6eeb384f9baa4a84e262f4725a2fad7b0 SHA1 7bbd8c7145bd494ff86fde53b9ba63a9aa1dd3de SHA256 f5d0f3136170e346cd97f30cc735f1e007183c5ae73bedb12b596c5b26323feb
EBUILD bash-4.1_p9.ebuild 5647 RMD160 a4735eb85dacda84c5e616c40b18d3bd6090c2b8 SHA1 fb124d72adcab6e86240cfc991c18eb0681333a1 SHA256 9dfe8f46a4e24aa1a994e886fae5a80228449b0471e0856368e521ad2fd36588
-EBUILD bash-4.2_p10.ebuild 5551 RMD160 c0d8ff1d9ccd53cd5eceaca621b3941f52ace62c SHA1 013312857f85d4d3dd4de454b7452e398c0bdb98 SHA256 a12d896d1d3dc427862e052d81af0ef248875e6350831e3464fcc82a1f315698
+EBUILD bash-4.2_p10.ebuild 5604 RMD160 82d81068ca21f03dfa36e3f8e4b1506e91ef4a4d SHA1 65ae606556415c0cd82d1a8373aeb8574447650a SHA256 f0359ff78cd7c8b62e6e613779d83da25c158d430f2c54dee9c3d5fc2e1baf40
EBUILD bash-4.2_p8-r1.ebuild 5546 RMD160 d60f2c28b28dcb55b063f16b8ee5400b88e0f6d6 SHA1 096e27b3ead5a1ec0756f88471db3084bee98f01 SHA256 466fd15f97af04edd495bf0452c8bebb0725288c2503362ff3d0088e849ca105
-MISC ChangeLog 45247 RMD160 2086fb901cb6a6a8e827a93eb022c8c2aff85ea8 SHA1 3ca2d5110213eda2027af3019210d8d769407091 SHA256 1e1eabc639085fda5838934ee0fe6ae88efbeaf56eb8f861975c416b1d0add23
+MISC ChangeLog 45424 RMD160 1447747418da545a19a8313df3a4410febb87b65 SHA1 1d022347256406e22fa96cc86de759277bef42b5 SHA256 e4a3b4509872cd4f4a0e85d6042e503f5e0d2395e1b55e7fd87ccaa7b2c67600
MISC metadata.xml 568 RMD160 c778ff1669af3c368238bcf481b344b741f0d6e1 SHA1 8d74d1c518351ad8085c9c26a5f2554d8c768b20 SHA256 48d380acb97dda0a7f4bd918b208d11367a8367d289b0a2d78ef08ef9a4e2562
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.17 (GNU/Linux)
+Version: GnuPG v2.0.18 (GNU/Linux)
-iF4EAREIAAYFAk5zhpUACgkQaC/OocHi7JbUQwEAkqr4BtgQICR0bYWMtZwNsyyG
-ThynhtTukevFN8fQ8ZwA/j8y0yyw0VMXIjd11GzQybXev9PvW8bk/8NB85vmpCUz
-=Vqdx
+iF4EAREIAAYFAk6PWo8ACgkQaC/OocHi7JaPSAD/WDTu8shnUh5OZQkM/yIRhk2/
+mguqsIJSLuKUQq4B6L0A/itc+j6XZ+L0TppJgzcFb4Xr9/Wc+0nz4eVFJvbvxJIj
+=CbI1
-----END PGP SIGNATURE-----
diff --git a/app-shells/bash/bash-4.2_p10.ebuild b/app-shells/bash/bash-4.2_p10.ebuild
index a1921e4b9134..006b9c14dfd8 100644
--- a/app-shells/bash/bash-4.2_p10.ebuild
+++ b/app-shells/bash/bash-4.2_p10.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/bash-4.2_p10.ebuild,v 1.4 2011/09/16 17:25:35 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-shells/bash/bash-4.2_p10.ebuild,v 1.5 2011/10/07 20:01:04 vapier Exp $
EAPI="1"
@@ -73,6 +73,7 @@ src_unpack() {
cd ../..
epatch "${FILESDIR}"/${PN}-4.2-execute-job-control.patch #383237
+ epatch "${FILESDIR}"/${PN}-4.2-parallel-build.patch
}
src_compile() {
diff --git a/app-shells/bash/files/bash-4.2-parallel-build.patch b/app-shells/bash/files/bash-4.2-parallel-build.patch
new file mode 100644
index 000000000000..9a7f36fafbd8
--- /dev/null
+++ b/app-shells/bash/files/bash-4.2-parallel-build.patch
@@ -0,0 +1,68 @@
+the current yacc rules allow multiple runs to generate the same files. usually
+this doesn't come up as the generated files are shipped in the tarball, but
+when you modify parse.y (applying a patch or developing or whatever), you can
+hit this problem.
+
+simple way of showing this:
+ make -j y.tab.{c,h}
+a correct system would not show the yacc parser running twice :)
+
+simple patch is to have the .h file depend on the .c file, and have the .h file
+itself issue a dummy rule (to avoid make thinking things changed).
+
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -579,16 +579,17 @@
+
+ # old rules
+ GRAM_H = parser-built
+-y.tab.o: y.tab.c ${GRAM_H} command.h ${BASHINCDIR}/stdc.h input.h
++y.tab.o: y.tab.h y.tab.c ${GRAM_H} command.h ${BASHINCDIR}/stdc.h input.h
+ ${GRAM_H}: y.tab.h
+ @-if test -f y.tab.h ; then \
+ cmp -s $@ y.tab.h 2>/dev/null || cp -p y.tab.h $@; \
+ fi
+-y.tab.c y.tab.h: parse.y
++y.tab.c: parse.y
+ # -if test -f y.tab.h; then mv -f y.tab.h old-y.tab.h; fi
+ $(YACC) -d $(srcdir)/parse.y
+ touch parser-built
+ # -if cmp -s old-y.tab.h y.tab.h; then mv old-y.tab.h y.tab.h; else cp -p y.tab.h ${GRAM_H}; fi
++y.tab.h: y.tab.c ; @true
+
+ # experimental new rules - work with GNU make but not BSD (or OSF) make
+ #y.tab.o: y.tab.c y.tab.h
+
+the current code generates a bunch of local libraries in subdirs and then
+links bash against that. those subdirs sometimes need version.h. so they
+have a rule to change back up to the parent dir and build version.h (which is
+fine). the trouble is that the top level objects and the subdirs are allowed
+to build in parallel, so it's possible for multiple children to see that
+version.h is not available and that it needs to be created, so they all do.
+
+there is even more trouble is that version.h depends on all the top level
+sources, some of which are compiled (like syntax.c). so these parallel
+children all kick off a job to generate syntax.c which in turn requires the
+mksyntax helper executable. obviously multiple processes rm-ing, compiling,
+and linking the same files quickly falls apart.
+
+so tweak the subdirs to all depend on the .build target which in turn depends
+on all of these top level files being generated. now the subdirs won't try and
+recursively enter the top level.
+
+(noticed by David James)
+
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -597,6 +598,11 @@
+ # $(YACC) -d $(srcdir)/parse.y
+ # -if cmp -s old-y.tab.h y.tab.h; then mv old-y.tab.h y.tab.h; fi
+
++# Subdirs will often times want version.h, so they'll change back up to
++# the top level and try to create it. This causes parallel build issues
++# so just force top level sanity before we descend.
++$(LIBDEP): .build
++
+ $(READLINE_LIBRARY): config.h $(READLINE_SOURCE)
+ @echo making $@ in ${RL_LIBDIR}
+ @( { test "${RL_LIBDIR}" = "${libdir}" && exit 0; } || \