Don't use anything higher than march=i486 with Glibc, and personally I would 
use march=i386. When distributions do it they also patch Glibc to work around 
the bugs caused by march=i686. Use -mtune=whatever. If you are compiling for 
size '-march=i386 -mtune=i386' will make smaller programs and libraries 
because there's less assembly and other code added.

When building GCC use --with-arch=i386 to configure the default march= for gcc 
after its installed, and use --with-cpu=pentium4 to configure the default 
mtune=. You can confirm this after gcc is installed by compiling main.c with 
'gcc -v'. Command line march= and mtune= will overide this.

Use --enable-omitfp in Glibc instead of -fomit-frame-pointer in CFLAGS. It 
will add -fomit-frame-pointer in appropriate places that won't give bad 
results from the testsuite, and it will also disable debugging and enable 
string inlining. It will also add -O99, but you can edit the makefile and 
change that to -Os if you want.

I'm pretty sure 'ld -z combreloc' is the default behavior of recent ld's, I 
don't think you need to specify it.

robert

On July 16, 2006 04:07 pm, Wojciech Giel wrote:
> >i know what was a problem - opimization:
> >I used these flags:
> >
> >export CHOST="i686-pc-linux-gnu"
> >export CFLAGS="-march=pentium4 -Os -fomit-frame-pointer -s -pipe
> >-DNDEBUG -DG_DISABLE_ASSERT"
> >export CXXFLAGS="-march=pentium4 -Os -s -pipe -DNDEBUG -DG_DISABLE_ASSERT"
> >export LDFLAGS="-s -z combreloc"
> >
> >now after compiling without these flags i get only:
> >make[2]: [/sources/glibc-build/posix/annexc.out] Error 1 (ignored)
> >
> >
> >thanks for help
> >but why using these flags i get errors??
>
> ___________________________________________________________
> To help you stay safe and secure online, we've developed the all new Yahoo!
> Security Centre. http://uk.security.yahoo.com

Attachment: pgpqRVvhYY8wf.pgp
Description: PGP signature

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to