Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
stage1=(stage3+emerge -e system+emerge -e world)? [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
batistuta
Veteran
Veteran


Joined: 29 Jul 2005
Posts: 1384
Location: Aachen

PostPosted: Wed Feb 22, 2006 9:12 am    Post subject: stage1=(stage3+emerge -e system+emerge -e world)? [SOLVED] Reply with quote

Let's say after doing a stage 3 installation I would like to recompile *everything* in my system with my own flags and stuff. That is, rebuild the whole toolchain and everything, like in a stage1 install. Is
Code:
emerge -e system && emerge -e world

enough to do this, or are there still things that need to be recompiled manually?


Last edited by batistuta on Thu Feb 23, 2006 8:54 am; edited 1 time in total
Back to top
View user's profile Send private message
Ferdinando
Veteran
Veteran


Joined: 25 Nov 2003
Posts: 1027
Location: Gaeta (LT) - Italy

PostPosted: Wed Feb 22, 2006 10:50 am    Post subject: Re: is stage1 == (stage3+emerge -e system+emerge -e world)? Reply with quote

Nope.
An emerge -e is perfectly equivalent to a stage1 installation, AFAIK.

Bye
_________________
La risposta, non la devi cercare fuori, la devi cercare dentro di te: e però è SBAGLIATA!
-- Corrado Guzzanti, "Pippo Chennedy Show", 1997
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1884

PostPosted: Wed Feb 22, 2006 11:02 am    Post subject: Reply with quote

besides that AFAIK in a stage 1 you have a toolchain installed that is used for bootstrapping and does not get overwritten or deleted completely.
_________________
Video Encoding scripts collection | Project page
Back to top
View user's profile Send private message
TheDebugger
Apprentice
Apprentice


Joined: 30 Aug 2005
Posts: 159
Location: Germany

PostPosted: Wed Feb 22, 2006 1:29 pm    Post subject: Re: is stage1 == (stage3+emerge -e system+emerge -e world)? Reply with quote

batistuta wrote:
Let's say after doing a stage 3 installation I would like to recompile *everything* in my system with my own flags and stuff. That is, rebuild the whole toolchain and everything, like in a stage1 install. Is
Code:
emerge -e system && emerge -e world

enough to do this, or are there still things that need to be recompiled manually?

I found that
Code:
emerge -e system && emerge -e world

is redundant and a
Code:
emerge -e world

should do. Rebuilding world rebuilds system as well. I wasted a couple of hours running
Code:
emerge -e system

prior to a world rebuild when upgrading gcc-3.3.6 to gcc-3.4.4 ...

If there is a valid reason why one should rebuild system prior to world I'd really like to know about it :)
Back to top
View user's profile Send private message
erikm
l33t
l33t


Joined: 08 Feb 2005
Posts: 631

PostPosted: Wed Feb 22, 2006 1:52 pm    Post subject: Re: is stage1 == (stage3+emerge -e system+emerge -e world)? Reply with quote

TheDebugger wrote:

If there is a valid reason why one should rebuild system prior to world I'd really like to know about it :)

Circular dependencies. The sanity of your packages depends on the sanity of your toolchain, which depends on the sanity of it's dependencies. That is, in order to be absolutely sure you have a well working toolchain, you should first build system with your reconfigured USE and CFLAGS set. Assuming all goes well, you now have a working system built on dependencies using the old configuration. Then you rebuild system, creating dependencies with the new configuration, using a compiler etc. made with the new configuration.

Rob Moss, a Gentoo dev, suggests going further still: By the same reasoning, your world packages are built with the old config, on dependencies with the old config. To get the world packages properly rebuilt, you should also do this twice (and yes, I know world contains the system packages; there is a certain redundancy here, but IMO ensuring the sanity of your system packages is a necessary first step). That is, if you significantly change configuration (new C{XX}FLAGS, new gcc or similar), the rebuild process is
Code:
~# emerge -e system && emerge -e system && emerge -e world && emerge -e world
:wink:
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1884

PostPosted: Wed Feb 22, 2006 1:53 pm    Post subject: Reply with quote

If you emerge -e system first, then when you do emerge -e world, every part of the toolchain is built with a toolchain that was built with the recent settings.

I did not compare the binaries, but at least when upgrading gcc-version I think there could be a difference somewhere :roll:

Edit:
and too late again :cry:

And when youre done with recompiling you can add a
Code:

emerge --sync && emerge -uD world
:twisted:
_________________
Video Encoding scripts collection | Project page
Back to top
View user's profile Send private message
TheDebugger
Apprentice
Apprentice


Joined: 30 Aug 2005
Posts: 159
Location: Germany

PostPosted: Wed Feb 22, 2006 2:07 pm    Post subject: Re: is stage1 == (stage3+emerge -e system+emerge -e world)? Reply with quote

ErikM wrote:
That is, if you significantly change configuration (new C{XX}FLAGS, new gcc or similar), the rebuild process is
Code:
~# emerge -e system && emerge -e system && emerge -e world && emerge -e world
:wink:

Oh bugger! Thanks for clarification :D
Back to top
View user's profile Send private message
JeliJami
Veteran
Veteran


Joined: 17 Jan 2006
Posts: 1086
Location: Belgium

PostPosted: Wed Feb 22, 2006 2:13 pm    Post subject: Reply with quote

to further clarify, read the Stage 1/3 Installation Guide for Gentoo 2005.1 & GCC 3.4.5.

Bob P wrote:
7.2 Re-Building the Toolkit: GCC 3.4.4

After emerging a new version of GCC, we need to pause for a moment and think about what we've done. We've just used GCC 3.3.5 and a toolchain built with GCC 3.3.5 to compile GCC 3.4.4. Before we spend any more time building our Gentoo system we should rebuild the entire toolchain, re-compiling it so that we have GCC 3.4.4 that was built with GCC 3.4.4.

Before we do this we need to examine /etc/make.conf and make changes to the CFLAGS statements in order to take advantage of the new performance-enhancing features of GCC 3.4.4. After making necessary updates to /etc/make.conf we need to rebuild the toolkit using the new GCC 3.4.4 compiler. The result will be a 3.4.4 tooklit, compiled by a 3.4.4 toolkit that was built with a 3.3.5 toolkit. Clear as mud? :roll:

_________________
Unanswered Post Initiative | Search | FAQ
Former username: davjel
Back to top
View user's profile Send private message
jonnevers
Veteran
Veteran


Joined: 02 Jan 2003
Posts: 1592
Location: Gentoo64 land

PostPosted: Wed Feb 22, 2006 4:07 pm    Post subject: Reply with quote

davjel wrote:
to further clarify, read the Stage 1/3 Installation Guide for Gentoo 2005.1 & GCC 3.4.5.


There is also this, An emerge wrapper for more correctly building the toolchain, that goes into detail about building (or rebuilding) your toolchain correctly. Its pretty exhaustive and worth a read I suppose.
Back to top
View user's profile Send private message
batistuta
Veteran
Veteran


Joined: 29 Jul 2005
Posts: 1384
Location: Aachen

PostPosted: Thu Feb 23, 2006 8:53 am    Post subject: Reply with quote

Thank you guys! That link made it for me. I'll close the thread, since all your feedback answered the question. 8)
Back to top
View user's profile Send private message
vinboy
n00b
n00b


Joined: 18 Jun 2006
Posts: 69

PostPosted: Sun Mar 04, 2007 5:50 am    Post subject: Re: is stage1 == (stage3+emerge -e system+emerge -e world)? Reply with quote

erikm wrote:
TheDebugger wrote:

If there is a valid reason why one should rebuild system prior to world I'd really like to know about it :)

Circular dependencies. The sanity of your packages depends on the sanity of your toolchain, which depends on the sanity of it's dependencies. That is, in order to be absolutely sure you have a well working toolchain, you should first build system with your reconfigured USE and CFLAGS set. Assuming all goes well, you now have a working system built on dependencies using the old configuration. Then you rebuild system, creating dependencies with the new configuration, using a compiler etc. made with the new configuration.

Rob Moss, a Gentoo dev, suggests going further still: By the same reasoning, your world packages are built with the old config, on dependencies with the old config. To get the world packages properly rebuilt, you should also do this twice (and yes, I know world contains the system packages; there is a certain redundancy here, but IMO ensuring the sanity of your system packages is a necessary first step). That is, if you significantly change configuration (new C{XX}FLAGS, new gcc or similar), the rebuild process is
Code:
~# emerge -e system && emerge -e system && emerge -e world && emerge -e world
:wink:


wouldn't it be easier to just do a clean install? having to emerge -e system X2 then emerge -e world X2 takes longer than clean install. isn't it?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum