begin quote On Sun, 2 Jun 2002 19:57:49 +0530 (IST) Prashanth Aditya Susarla wrote: > Hello, > I tried to bootstrap with the default-1.0-gcc3 profile at the > outset. The exact details are as follows:- > 1.) I used the gentoo-1.1a-ix86.iso image to create my bootable CD > 2.) Instead of using the stage-1 tbz2 file on this CD, I separately > downloaded the stage-1 build image from the 1.2 release and used that > instead > 3.) As soon as I did the emerge rsync, I switched profiles and edited > make.conf. The optimization flags which I used are very simple - > -march=i686 -O3 -fomit-frame-pointer This is too heavy. if for bootstrap use : -march=i686 -O2 -pipe do -not- use -fomit-frame-pointer during bootstrap! (can anyone who actually got this to -work- using omit-frame-pointer speak up??) This causes breakage in glibc. > I also edited the packages file to unmask versions of binutils >= 2.12 > 4.) Executing bootstrap.sh compiled baselayout, gettext, binutils, > gcc-3.1-r5 and glibc-2.2.5-r3 without any hitches. > 5.) As soon as glibc was merged and the bootstrap was going to remerge > everything again, gzip failed with a broken pipe and most binaries > started segfaulting (notably emerge and even ls!). this is due to a broken glibc (omit frame pointer and -O3. I think glibc strips out -O3 but not the -f flags. ) > From the discussions I see on gentoo-dev, I gather that it might be > possible to get a gcc-3.1 system up and running by either > 1.) ebuilding gcc before anything else Not recommended as it will build a lot of bad stuff. > 2.) going easy on the optimizations thats the good one. you used quite heavy optimiztions. > 3.) switching profiles after the first bootstrap and re-bootstrapping unnecessary really. > Secondly, am I doing something wrong in using the 1.2 build image? Nope, works for me (tm) > Thirdly, has anyone seen this kind of error before (atleast I don't > see it from what I gathered from the archives) and what insights could > I have into this? Yes, several times when I did optimization testing. Solution: Scrap the optimizations and it works :) > PS:- I'll try to reproduce the exact errors if I can but the basic > problem is that most binaries segfault soon after glibc is built. Try again with -O2 -pipe and you will get a working system :) My personal "recipie" to get gcc 3.1 bootstrap working: install a 1.2 tarball on a fresh fs. change profile. and unmask gcc 3.1 if necessary. make.conf flags to -O2 -pipe bootstrap. with flags still set as generic and with only -O2 optimizations: emerge --buildpkg gcc binutils glibc gettext (This takes time, but gives you backup when things break. if you test optimizations things break. honest.) store away my "Safe" binary packages of gcc glibc et.all. flags changed to -O3 -march=athlon-tbird -pipe and modified my USE flags to fit me unmask binutils emerge binutils emerge glibc this gives a glibc for athlon and with combreloc. test that things work.... (ls, gzip blah blah. if it breaks, boot from cd and unpack the "safe" binaries) a good trial is emerge gettext time to get a platform-specific compiler : emerge gcc now, you should have a working system for all issues... remember, theese are the sk. foolproof way of doing things, use sane default optimizations and its just to unmask bintutils and gcc and bootstrap. but users dont do that. :p (users aren't sane ;) now, with all flags tuned, if you feel insane enough, remove frame pointer and invalidate all your chances of support, then do : emerge system /(watch it break down and cry in xfree because you overoptimized) //Spider -- begin .signature This is a .signature virus! Please copy me into your .signature! See Microsoft KB Article Q265230 for more information. end