Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Portage & Programming
  • Search

GCC 4.1.1 and glibc 2.4 stable on x86 and amd64

Problems with emerge or ebuilds? Have a basic programming question about C, PHP, Perl, BASH or something else?
Post Reply
Advanced search
389 posts
  • Page 1 of 16
    • Jump to page:
  • 1
  • 2
  • 3
  • 4
  • 5
  • …
  • 16
  • Next
Author
Message
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

GCC 4.1.1 and glibc 2.4 stable on x86 and amd64

  • Quote

Post by amne » Wed Aug 30, 2006 5:34 pm

As previously announced sys-devel/gcc-4.1.1 and sys-libs/glibc-2.4-r3 are stable on x86 and amd64 now.

To upgrade gcc please follow the Gcc upgrading guide.

As it turned out in the discussion before, some questions are unclear for some users, so i'll try to make it clear here:

I want to upgrade from gcc 3.4 to gcc 4.1 - which instructions do i use?
Please follow the general instructions.

Do i really have to recompile everything?
You really really should do that, as it is the only way to guarantee your system is in a sane state.
Please also read this explanation by wolf31o2.

emerge -e world/system failed, do i have to recompile from the beginning?
I would like to stop emerge -e for a while, can i do that?

If emerge terminates due to an error or because you (accidentially or intentionally) stop it, you can run

Code: Select all

emerge --resume
it will continue the last emerge you started. However if you're half through with compiling openoffice it will still start from the beginning.
If emerge stops due to a failure, try

Code: Select all

emerge --resume --skipfirst
which resumes and skips the first package (read: the one that failed).

I want to do it using revdep-rebuild like when i upgraded from 3.3 to 3.4
Using revdep-rebuild is not as safe as really rebuilding all packages, and only worked for the 3.3->3.4 transition. It is not intended for the update to 4.1.
If you upgrade from gcc 3.3 to 4.1 it may also fail terribly using revdep-rebuild, do a full emerge -e system and world.
Again, please also read this explanation by wolf31o2.

I heard that i should do

Code: Select all

emerge -e system
emerge -e system
emerge -e world
emerge -e world
[/b]
This is not necessary, just do it once as mentioned in the upgrade guide.

I don't want to switch to gcc 4.1
This is possible and explained in the GWN
However, please be aware that older compilers are mostly unsupported as far bug reports are concerned.

So what about glibc?
Your new glibc will be installed during emerge -e system. ;)
As with all glibc updates, once you've upgraded you should not downgrade glibc to a lower version after the upgrade.
edit: Actually glibc will refuse to downgrade anyway as this is checked in the ebuild.

If you already upgraded your gcc to 4.1 before it hit stable and only want to upgrade glibc, you don't need to recompile your system, just install the new version.

If you have further questions about the update, please post them here.
Last edited by amne on Fri Sep 01, 2006 12:05 pm, edited 4 times in total.
Dinosaur week! (Ok, this thread is so last week)
Top
mystified
l33t
l33t
User avatar
Posts: 771
Joined: Sat Feb 14, 2004 1:33 am

gcc 4.1.1

  • Quote

Post by mystified » Wed Aug 30, 2006 9:08 pm

I'm emerging the new gcc 4.1.1. Anything special besides gcc-config, emerge system and emerge world?

Thanks!
Top
Paapaa
l33t
l33t
User avatar
Posts: 955
Joined: Sun Aug 14, 2005 8:45 am
Location: Finland

  • Quote

Post by Paapaa » Wed Aug 30, 2006 9:14 pm

Just keep on watching the official guide:

http://www.gentoo.org/doc/en/gcc-upgrading.xml

(There might be an update shortly...)
Last edited by Paapaa on Wed Aug 30, 2006 10:25 pm, edited 1 time in total.
Top
mystified
l33t
l33t
User avatar
Posts: 771
Joined: Sat Feb 14, 2004 1:33 am

  • Quote

Post by mystified » Wed Aug 30, 2006 9:24 pm

Ok, thanks. I got it bookmarked and I'll keep checking.
Top
tld
Veteran
Veteran
Posts: 1889
Joined: Tue Dec 09, 2003 9:35 pm

  • Quote

Post by tld » Wed Aug 30, 2006 9:55 pm

Does anyone know if it's is safe to update world (and thus install glibc-2.4) before activating gcc 4.1.1 and recompiling the system?

The sticky on the Gentoo Chat forum on gcc 4.1.1 says "Users who do not wish to upgrade to GCC 4.1.1 will require a few more steps to ensure their systems are not upgraded". It doesn't say much more about it, and that confused me as upgrading gcc doesn't automatically activate it.

Tom
Top
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

  • Quote

Post by amne » Wed Aug 30, 2006 10:23 pm

Merged a couple of posts to the sticky i had prepared earlier and hidden in a sekrit place. ;)
tld wrote:Does anyone know if it's is safe to update world (and thus install glibc-2.4) before activating gcc 4.1.1 and recompiling the system?
You can, but you're going to emerge -e it anyway, which will merge glibc-2.4.
tld wrote:The sticky on the Gentoo Chat forum on gcc 4.1.1 says "Users who do not wish to upgrade to GCC 4.1.1 will require a few more steps to ensure their systems are not upgraded". It doesn't say much more about it, and that confused me as upgrading gcc doesn't automatically activate it.
See my first post for a link to the GWN article from last week.
Dinosaur week! (Ok, this thread is so last week)
Top
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

Re: gcc 4.1.1

  • Quote

Post by amne » Wed Aug 30, 2006 10:25 pm

mystified wrote:I'm emerging the new gcc 4.1.1. Anything special besides gcc-config, emerge system and emerge world?
Run fix_libtool_files.sh 3.4.6 (or whatever your old version was) after emerge gcc - this doesn't happen automatically for the gcc 3->4 change. It will also be mentioned in the updated version of the guide that also contains some other small fixes, which will be online soon.
Dinosaur week! (Ok, this thread is so last week)
Top
tld
Veteran
Veteran
Posts: 1889
Joined: Tue Dec 09, 2003 9:35 pm

  • Quote

Post by tld » Wed Aug 30, 2006 10:29 pm

amne wrote:
tld wrote:Does anyone know if it's is safe to update world (and thus install glibc-2.4) before activating gcc 4.1.1 and recompiling the system?
You can, but you're going to emerge -e it anyway, which will merge glibc-2.4.
I was going to wait on glicbc, but it appears that glibc-2.4 is a dependency of gcc-4.1.1(??).

Tom
Top
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

  • Quote

Post by amne » Wed Aug 30, 2006 10:49 pm

tld wrote:I was going to wait on glicbc, but it appears that glibc-2.4 is a dependency of gcc-4.1.1(??).
I assume you've tried emerge -uav gcc, which also updates dependencies such as glibc, try emerge -av gcc, which shouldn't update glibc.
Dinosaur week! (Ok, this thread is so last week)
Top
bigbob73
Guru
Guru
User avatar
Posts: 332
Joined: Fri Dec 31, 2004 6:51 pm
Location: Under the Lone Star

  • Quote

Post by bigbob73 » Wed Aug 30, 2006 11:28 pm

I'm already using gcc4.1.1 and glibc2.4. should i just change profiles and remove the appropriate entries in package.* (using straight x86 otherwise.)
A computers attention span is only as long as it's electrical cord (Murphy)
Top
RazielFMX
l33t
l33t
User avatar
Posts: 835
Joined: Sat Apr 23, 2005 6:35 pm
Location: NY, USA

  • Quote

Post by RazielFMX » Thu Aug 31, 2006 4:58 am

A friendly warning to the Gentoo user world:

Add nptl and nptlonly to your USE flags before starting the upgrade guide, otherwise glibc will not compile, it will just yell at you to do the aforementioned.

If you forget, remember to restart your emerge command with a --resume!
I am not anti-systemd; I am pro-choice. If being the latter makes you feel that I am the former, then so be it.
Top
R!tman
Veteran
Veteran
User avatar
Posts: 1303
Joined: Thu Dec 18, 2003 11:10 am
Location: Zurich, Switzerland

  • Quote

Post by R!tman » Thu Aug 31, 2006 7:36 am

I followed the howto, nevertheless...

Code: Select all

 emerge -1 libtool
Calculating dependencies... done!
>>> Emerging (1 of 1) sys-devel/libtool-1.5.22 to /
>>> checking ebuild checksums ;-)
>>> checking auxfile checksums ;-)
>>> checking miscfile checksums ;-)
>>> checking libtool-1.5.22.tar.gz ;-)
>>> Unpacking source...
>>> Unpacking libtool-1.5.22.tar.gz to /var/tmp/portage/libtool-1.5.22/work
 * Applying libtool-1.4.2-archive-shared.patch ...                                                  [ ok ]
 * Applying libtool-1.5.6-ltmain-SED.patch ...                                                      [ ok ]
 * Applying libtool-1.4.2-expsym-linux.patch ...                                                    [ ok ]
 * Applying libtool-1.5.20-use-linux-version-in-fbsd.patch ...                                      [ ok ]
 * Applying libtool-1.5.10-portage.patch ...                                                        [ ok ]
 * Applying libtool-1.5.20-version-checking.patch ...                                               [ ok ]
 * Applying libtool-1.5.20-ltmain_sh-max_cmd_len.patch ...                                          [ ok ]
 * Applying libtool-1.5-filter-host-tags.patch ...                                                  [ ok ]
 * Applying libtool-1.5.10-locking.patch ...                                                        [ ok ]
 * Applying libtool-1.5.14-egrep.patch ...                                                          [ ok ]
 * Applying libtool-1.5.20-override-LD_LIBRARY_PATH.patch ...                                       [ ok ]
 * Generating ltmain.sh ...                                                                         [ ok ]
 * Running autotools in '.' ...
/usr/share/aclocal/gtk.m4:7: warning: underquoted definition of AM_PATH_GTK
  run info '(automake)Extending aclocal'
  or see http://sources.redhat.com/automake/automake.html#Extending-aclocal
/usr/share/aclocal/glib.m4:8: warning: underquoted definition of AM_PATH_GLIB
/usr/share/aclocal/ao.m4:9: warning: underquoted definition of XIPH_PATH_AO                         [ ok ]
 * Running autotools in 'libltdl' ...
/usr/share/aclocal/gtk.m4:7: warning: underquoted definition of AM_PATH_GTK
  run info '(automake)Extending aclocal'
  or see http://sources.redhat.com/automake/automake.html#Extending-aclocal
/usr/share/aclocal/glib.m4:8: warning: underquoted definition of AM_PATH_GLIB
/usr/share/aclocal/ao.m4:9: warning: underquoted definition of XIPH_PATH_AO                         [ ok ]
 * Removing useless C++ checks ...                                                                  [ ok ]
>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/libtool-1.5.22/work/libtool-1.5.22 ...
 * econf: updating libtool-1.5.22/libltdl/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating libtool-1.5.22/libltdl/config.sub with /usr/share/gnuconfig/config.sub
 * econf: updating libtool-1.5.22/config.guess with /usr/share/gnuconfig/config.guess
 * econf: updating libtool-1.5.22/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --libdir=/usr/lib64 --build=x86_64-pc-linux-gnu
checking for a BSD-compatible install... /bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for x86_64-pc-linux-gnu-gcc... x86_64-pc-linux-gnu-gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.

!!! Please attach the following file when filing a report to bugs.gentoo.org:
!!! /var/tmp/portage/libtool-1.5.22/work/libtool-1.5.22/config.log

!!! ERROR: sys-devel/libtool-1.5.22 failed.
Call stack:
  ebuild.sh, line 1539:   Called dyn_compile
  ebuild.sh, line 939:   Called src_compile
  libtool-1.5.22.ebuild, line 128:   Called econf
  ebuild.sh, line 541:   Called die

!!! econf failed
!!! If you need support, post the topmost build error, and the call stack if relevant.
Here is config.log.
Top
syouth
Apprentice
Apprentice
User avatar
Posts: 275
Joined: Sat Sep 18, 2004 1:55 pm

  • Quote

Post by syouth » Thu Aug 31, 2006 8:18 am

Oh joy, oh joy. I started my upgrade. I will edit this post for a feedback..
Top
RazielFMX
l33t
l33t
User avatar
Posts: 835
Joined: Sat Apr 23, 2005 6:35 pm
Location: NY, USA

  • Quote

Post by RazielFMX » Thu Aug 31, 2006 9:05 am

R!tman, try again. I had things randomly fail on me first time through. I'm now up to the emerge -eav world step...

Also, make sure you do the gcc-config then source /etc/profile. I missed that first time through and things were WAY wrong... And probably the cause of my compile failures, since the system run and libtool were smooth after that...
I am not anti-systemd; I am pro-choice. If being the latter makes you feel that I am the former, then so be it.
Top
Polynomial-C
Retired Dev
Retired Dev
User avatar
Posts: 1432
Joined: Sun Jun 01, 2003 4:19 pm
Location: Germany

  • Quote

Post by Polynomial-C » Thu Aug 31, 2006 9:35 am

Hi,

is fix_libtool_files.sh really necessary after upgrading gcc when running emerge -e system && emerge -e world in any case after gcc-upgrade?
I don't like fix_libtool_files.sh as it was the cause for orphaned files after running it for many times on my system.

Cheers
Poly-C
The manual said "Requires Windows10 or better" so I installed GNU/Linux...

my portage overlay

Need a stage1 tarball? (Unofficial builds)
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Aug 31, 2006 10:00 am

won't nptlonly break binary packages that don't support it? what are the ups and downs in enabling/not enabling it?
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

  • Quote

Post by amne » Thu Aug 31, 2006 10:00 am

Polynomial-C wrote:is fix_libtool_files.sh really necessary after upgrading gcc when running emerge -e system && emerge -e world in any case after gcc-upgrade?
I don't like fix_libtool_files.sh as it was the cause for orphaned files after running it for many times on my system.
I assume you may run into some problems compiling if you don't, but i really can't give you an estimate how much trouble it'll be. ;)
As far i know this is the last time you'll have to do it as gcc 4.1 does those things differently.
Dinosaur week! (Ok, this thread is so last week)
Top
Barnoid
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 103
Joined: Fri Jul 30, 2004 2:44 am
Contact:
Contact Barnoid
Website

  • Quote

Post by Barnoid » Thu Aug 31, 2006 10:04 am

Code: Select all

# emerge -e system
# emerge -e world
will compile many packages twice which is a complete waste of time.

For those of you who don't want to compile packages more than once run:

Code: Select all

# emerge -pe system | grep "^\[ebuild .*" | colrm 1 16 | sed "s/\[.*//" | sed "s/USE.*//" | sed "s/LINGUAS.*//" | sed "s/.*/=\0/" > system.list
# emerge -pe world | grep "^\[ebuild .*" | colrm 1 16 | sed "s/\[.*//" | sed "s/USE.*//" | sed "s/LINGUAS.*//" | sed "s/.*/=\0/" | grep -vFf system.list > world.list
# emerge --oneshot --nodeps `cat system.list world.list`
Note: if your system.list or world.list file contains entries like

Code: Select all

=] dev-lang/php-4.4.3-r1
you need to cut away more columns (i.e. replace 'colrm 1 16' with 'colrm 1 18', for example) such that the entries all read

Code: Select all

=dev-lang/php-4.4.3-r1
On my desktop, this saves me double compilation of over 100 packages.

Cheers,
Barnoid
Last edited by Barnoid on Thu Aug 31, 2006 2:51 pm, edited 4 times in total.
Top
Polynomial-C
Retired Dev
Retired Dev
User avatar
Posts: 1432
Joined: Sun Jun 01, 2003 4:19 pm
Location: Germany

  • Quote

Post by Polynomial-C » Thu Aug 31, 2006 10:05 am

Hi,
amne wrote:I assume you may run into some problems compiling if you don't
I really can't imagine how, if I compile everything nearly from scratch. On the other hand, you're more experienced with this stuff than I am. I think I will just jump into cold water and try it without fix_libtool_files.sh :)

Cheers
Poly-C
The manual said "Requires Windows10 or better" so I installed GNU/Linux...

my portage overlay

Need a stage1 tarball? (Unofficial builds)
Top
Vrenn
Guru
Guru
Posts: 327
Joined: Wed Dec 15, 2004 7:45 pm

  • Quote

Post by Vrenn » Thu Aug 31, 2006 10:22 am

Hi everybody

My problem is that I cant compile 2 GB over night, impossible. Can I upgrade system and world, stop world and resume it every following day? Can I leave gcc 3 paralell until emerge --resume is done? And should kernel-recomb be right after system?
Thanks for your help.
With nice greetings
Vrenn
Top
Barnoid
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 103
Joined: Fri Jul 30, 2004 2:44 am
Contact:
Contact Barnoid
Website

  • Quote

Post by Barnoid » Thu Aug 31, 2006 10:28 am

As I have suggested above, avoid compiling packages twice. If you generate the two files (system.list and world.list) as described in my earlier post, you can split these two files manually into smaller files containing only a few packages (say, system.list.1, system.list.2, ..., world.list.1, world.list.2, ...) and then run

Code: Select all

# emerge --oneshot --nodeps `cat system.list.1`
# emerge --oneshot --nodeps `cat system.list.2`
...
# emerge  --oneshot --nodeps `cat world.list.1`
# emerge  --oneshot --nodeps `cat world.list.2`
...
Cheers,
Barnoid
Top
Aszrael
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 101
Joined: Tue Feb 15, 2005 10:56 am
Location: Hannover/Germany

  • Quote

Post by Aszrael » Thu Aug 31, 2006 10:35 am

Vrenn wrote:...And should kernel-recomb be right after system?
I would really recommend that
Top
R!tman
Veteran
Veteran
User avatar
Posts: 1303
Joined: Thu Dec 18, 2003 11:10 am
Location: Zurich, Switzerland

  • Quote

Post by R!tman » Thu Aug 31, 2006 10:50 am

RazielFMX wrote:R!tman, try again. I had things randomly fail on me first time through. I'm now up to the emerge -eav world step...

Also, make sure you do the gcc-config then source /etc/profile. I missed that first time through and things were WAY wrong... And probably the cause of my compile failures, since the system run and libtool were smooth after that...
I actually did

Code: Select all

source /etc/profile
I found out libtool does compile with 3.4.6, only 4.1.1 gives me headaches.

BTW, I only have that problem on amd64, libtool compiled fine with 4.1.1 on my x86.

Any suggestions?

EDIT: libtool doesn't seem to like the combination gcc-4.1.1 and LDFLAGS="-W1, -O1". With disabling LDFLAGS I could finally compile libtool!
Top
Sachankara
l33t
l33t
User avatar
Posts: 696
Joined: Fri Jun 11, 2004 5:04 pm
Location: Stockholm, Sweden

  • Quote

Post by Sachankara » Thu Aug 31, 2006 11:15 am

CRV§ADER//KY wrote:won't nptlonly break binary packages that don't support it? what are the ups and downs in enabling/not enabling it?
NPTL is fully backwards compatible with LinuxThreads. At least I've never had a problem with binary only stuff.
Gentoo Hardened Linux 2.6.21 + svorak (Swedish dvorak)
Top
amne
Bodhisattva
Bodhisattva
User avatar
Posts: 6378
Joined: Sun Nov 17, 2002 6:00 pm
Location: Graz / EU

  • Quote

Post by amne » Thu Aug 31, 2006 11:48 am

Barnoid wrote:

Code: Select all

# emerge -e system
# emerge -e world
will compile many packages twice which is a complete waste of time.
As said before, only this way you can be sure everything works fine, even if this consumes a bit more time.
Polynomial-C wrote:I really can't imagine how, if I compile everything nearly from scratch. On the other hand, you're more experienced with this stuff than I am. I think I will just jump into cold water and try it without fix_libtool_files.sh :)
Tbh, i just can't tell you if it may work or not. To make things work fine, you should do it. If you don't but are aware what's possibly going to happen, give it a try. ;)
Vrenn wrote:My problem is that I cant compile 2 GB over night, impossible. Can I upgrade system and world, stop world and resume it every following day? Can I leave gcc 3 paralell until emerge --resume is done? And should kernel-recomb be right after system?
Yes, stopping and resuming should work fine. As for the kernel, the only problem i am currently aware of is that modules and kernel need to be compiled with the same version, e.g. if the kernel is compiled with gcc 3.4 and ndiswrapper with 4.1 it won't load. So it's probably easiest to recompile your kernel quite soon and then also recompile all external modules such as ndiswrapper, kqemu etc.
Dinosaur week! (Ok, this thread is so last week)
Top
Post Reply

389 posts
  • Page 1 of 16
    • Jump to page:
  • 1
  • 2
  • 3
  • 4
  • 5
  • …
  • 16
  • Next

Return to “Portage & Programming”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic