While building gnome it depends upon gdb. gdb fails during the compilation of its first source file with an error cc1: invalid option '-O2-pipe' *** The command 'gcc -o conftest -O2-pipe -march=athlon conftest.c' failed. *** You must set the environment variable CC to a working compiler. ... This keeps gnome and probably kde from building.
This is for the gdb-5.2.1.ebuild.
Further research finds that this is caused because of two factors. My CFLAGS are set to "-O -pipe -march=athlon". Nothing wrong there. What is wrong is in the ebuild, there is a replace-flags directive. replace-flags -O? -O2 This seems to strip out a space from the CFLAGS environment. Why does this need to be there?
its odd that it would strip the space ... the replace-flags is there because the package breaks with -O3 and greater
the flag-o-matic eclass should have the requisite fix. please try again.
try something like: --------snip--------------- replace-flags -O[!' '] -O2 ---------------------------