Gentoo Archives: gentoo-user

From: meino.cramer@×××.de
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Getting rid of gcc-4.7.3...how?
Date: Sat, 20 Dec 2014 19:04:38
Message-Id: 20141220190429.GB14187@solfire
In Reply to: Re: [gentoo-user] Getting rid of gcc-4.7.3...how? by Matti Nykyri
1 Matti Nykyri <matti.nykyri@×××.fi> [14-12-20 19:48]:
2 > > On Dec 20, 2014, at 17:56, meino.cramer@×××.de wrote:
3 > >
4 > > Dale <rdalek1967@×××××.com> [14-12-20 02:47]:
5 > >> meino.cramer@×××.de wrote:
6 > >>> Dale <rdalek1967@×××××.com> [14-12-19 17:08]:
7 > >>>> Mick wrote:
8 > >>>>> Meino, to avoid misunderstandings: 1. Emerge the new gcc package. 2.
9 > >>>>> Use gcc-config to change to the new gcc version. 3. Run 'env-update &&
10 > >>>>> source /etc/profile'. 4. Run fix_libtool_files.sh, although I would
11 > >>>>> think that this is redundant these days. 5. Unmerge the old gcc version.
12 > >>>> I don't recall ever running fix_libtool_files.sh after switching gcc
13 > >>>> versions. Usually when I see a gcc upgrade, I emerge it, switch to it
14 > >>>> and the usual profile thing, run emerge -e world JUST to be safe, then
15 > >>>> unmerge the old gcc. That's all I usually do here. I have skipped the
16 > >>>> emerge -e world a time or two.
17 > >>>>
18 > >>>> Am I just lucky, not likely as some may know, or does emerge -e world
19 > >>>> catch it or what? Now I'm curious.
20 > >>>>
21 > >>>> Dale
22 > >>>>
23 > >>>> :-) :-)
24 > >>> Hi Dale,
25 > >>>
26 > >>> I started compiling the new gcc this morning about ~7:00 AM...just a
27 > >>> few minutes ago stage3 finishes. Now ... before doing anything else...
28 > >>> I am makeing a backup of all that, so...if anything fails...I am able
29 > >>> to reinstall the status quo.
30 > >>>
31 > >>> I will keep you informed, what happens to my little embedded system...
32 > >>>
33 > >>> Best
34 > >>> Meino
35 > >>
36 > >> That's the thing about slow systems, you want to do it right the first
37 > >> time because it takes to much time to repeat something. Heck, I have a
38 > >> 4 core AMD CPU with 16GBs of ram here and I still would rather do it
39 > >> right the first time. If you have something slow that takes days to do
40 > >> something, you really want plan A to work.
41 > >>
42 > >> I'm also wondering if there have been changes to emerge that could make
43 > >> a difference. I run the latest unstable non *9999 version. I sorta
44 > >> like having all the new improvements. I'm just not sure if that affects
45 > >> the issue here is all.
46 > >>
47 > >> Dale
48 > >>
49 > >> :-) :-)
50 > >
51 > > Hi,
52 > >
53 > > after a few more non-booting-systems and backup-reinstalls I think
54 > > I know whats the reason is...but by I dont know how to get out of it:
55 > >
56 > > The system becomes inaccessible if I do an env-update and reboot.
57 > >
58 > > Reason for that are binaries, in which the path to the old gcc is
59 > > hardcoded. With the sdcard mounted I checked that with my PC:
60 > > I did a
61 > >
62 > > grep -r '\/usr\/lib\/gcc\/armv7a-hardfloat-linux-gnueabi\/4.7.3'
63 > >
64 > > on ALL files of the sdcard and found "thousands" of hardcoded links
65 > > to the old gcc inside binaries...
66 > >
67 > > The new gcc installed but not doing env-update implies that any
68 > > further compilation will link to the old gcc.
69 > >
70 > > Doing env-update implies a system which will not survive the next
71 > > reboot.
72 > >
73 > > What now?
74 >
75 > If i understand your situation correctly, do:
76 >
77 > gcc-config "to set the new version"
78 > env-update
79 > logout
80 > login
81 > emerge --deep --update world
82 > emerge --depclean
83 > revdep-rebuild
84 >
85 > This will take a long time but will get your system working again. If you don't wan't to do that you can of course tweak the libraries with binary tools. That is easy if you know what you are doing.
86 >
87 > To prevent this in the future always before world update, update gcc and glibc first if tere is a new version available. Gcc-config is crusial after you have installed a bew version of gcc.
88 >
89 > --
90 > -Matti
91
92
93 Hi Matti,
94
95 not exactly...
96 The sequence you show looks like this in my case:
97 gcc-config "to set the new version"
98 env-update
99 reboot
100 logina attempt: impossible...system does not respond anymore
101
102 The reason is, that env-update updates to the new compiler,
103 while some [CENSORED] system tools/application are hardcoded
104 to use the old compiler libraries...
105
106 If I do a
107
108 env-update --no-ldconfig
109
110 then I am able to reboot successfully...but compilation
111 will be done against the old compiler a fear...
112
113 I am installing the backup the fourth time today and I am
114 curious, when the first bad sectors of my sdcard will hit me...
115
116
117
118 Best regards,
119 Meino

Replies

Subject Author
Re: [gentoo-user] Getting rid of gcc-4.7.3...how? Matti Nykyri <matti.nykyri@×××.fi>
Re: [gentoo-user] Getting rid of gcc-4.7.3...how? Bill Kenworthy <billk@×××××××××.au>
Re: [gentoo-user] Getting rid of gcc-4.7.3...how? Jeremi Piotrowski <jeremi.piotrowski@×××××.com>