1 |
From: "W. Trevor King" <wking@×××××××.us> |
2 |
|
3 |
When using `update_seed` to get a 20121213 stage3 from |
4 |
libmpc.so.2 to libmpc.so.3, stage2 failed with: |
5 |
|
6 |
/usr/libexec/gcc/i686-pc-linux-gnu/4.6.3/cc1: |
7 |
error while loading shared libraries: libmpc.so.2: |
8 |
cannot open shared object file: No such file or directory |
9 |
|
10 |
This was due to an mpc version bump in the Portage tree that was not |
11 |
present in the stage3 I used to seed stage1. Stage1 wasn't |
12 |
recompiling GCC against the new mpc, so it ended up with GCC linking |
13 |
against the old mpc. Heading into stage2, the old mpc (from the seed |
14 |
stage3) was no longer present, so compilation crashed and burned. |
15 |
|
16 |
To fix this, we should be extra agressive about rebuilding packages |
17 |
when their dependencies change in stage1. The earlier update_seed |
18 |
command was not catching the bumped mpc, so add: |
19 |
|
20 |
--complete-graph --with-bdeps=y --rebuild-if-new-ver |
21 |
|
22 |
to toughen things up. |
23 |
|
24 |
This is a general dependency problem (not GCC specific), so I also |
25 |
replaced the gcc target with: |
26 |
|
27 |
@world @system |
28 |
|
29 |
This leads to a lot of rebuilding, but it should be a stable and |
30 |
general fix. With a general fix there should be no more need for |
31 |
user-specific overrides via update_seed_command, but Gentoo is about |
32 |
choice, so we keep the option. Use it at your own risk ;). |
33 |
|
34 |
Based-on-patch-by: Brian Dolbec <dolsen@g.o> |
35 |
--- |
36 |
Changes since v2: |
37 |
* Reinstated update_seed_command, as requested by Zero_Chaos. |
38 |
|
39 |
doc/catalyst-spec.5.txt | 2 +- |
40 |
targets/stage1/stage1-chroot.sh | 9 +++------ |
41 |
2 files changed, 4 insertions(+), 7 deletions(-) |
42 |
|
43 |
diff --git a/doc/catalyst-spec.5.txt b/doc/catalyst-spec.5.txt |
44 |
index 4a6e06c..0eb3c2f 100644 |
45 |
--- a/doc/catalyst-spec.5.txt |
46 |
+++ b/doc/catalyst-spec.5.txt |
47 |
@@ -138,7 +138,7 @@ it should update the seed stage or not (valid values: `yes no`). |
48 |
*update_seed_command*:: |
49 |
This is an optional command to pass to emerge for updating the seed |
50 |
stage (example: `--update dev-libs/mpfr dev-libs/mpc dev-libs/gmp`) |
51 |
-If not specified, catalyst will update gcc deps. |
52 |
+If not specified, catalyst will update `@system` and `@world`. |
53 |
This setting requires enabling update_seed. |
54 |
|
55 |
Compilation |
56 |
diff --git a/targets/stage1/stage1-chroot.sh b/targets/stage1/stage1-chroot.sh |
57 |
index 3f628c2..0e3859c 100644 |
58 |
--- a/targets/stage1/stage1-chroot.sh |
59 |
+++ b/targets/stage1/stage1-chroot.sh |
60 |
@@ -26,12 +26,9 @@ clst_root_path=/ setup_pkgmgr |
61 |
# Update stage3 |
62 |
if [ -n "${clst_update_seed}" ]; then |
63 |
if [ "${clst_update_seed}" == "yes" ]; then |
64 |
- echo "Updating seed stage..." |
65 |
- if [ -n "${clst_update_seed_command}" ]; then |
66 |
- clst_root_path=/ run_merge "--buildpkg=n ${clst_update_seed_command}" |
67 |
- else |
68 |
- clst_root_path=/ run_merge "--buildpkg=n --update --deep --newuse --onlydeps gcc" |
69 |
- fi |
70 |
+ update_cmd="${clst_update_seed_command:---update --deep --complete-graph --with-bdeps=y --rebuild-if-new-ver @world @system}" |
71 |
+ echo "--- Updating seed stage with: ${update_cmd}" |
72 |
+ clst_root_path=/ run_merge "${update_cmd}" |
73 |
elif [ "${clst_update_seed}" != "no" ]; then |
74 |
echo "Invalid setting for update_seed: ${clst_update_seed}" |
75 |
exit 1 |
76 |
-- |
77 |
1.8.2.rc0.16.g20a599e |