Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 30920 - cflag mangling in sys-devel/gcc-3.3.1-r4 ebuild
Summary: cflag mangling in sys-devel/gcc-3.3.1-r4 ebuild
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Please assign to toolchain
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-10-11 12:05 UTC by James
Modified: 2004-04-18 22:36 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description James 2003-10-11 12:05:18 UTC
With CFLAGS="-O -mcpu=i686" in make.conf the ebuild tries to set the CFLAGS to "-O2-mcpu=i686" which breaks the build immediatly.
Resolved by setting -O2 in make.conf
Comment 1 Marc Doughty 2003-10-15 07:38:43 UTC
can you try setting "-O  -mcpu=i686" (two spaces instead of one)?

The ebuild script seems to replace "-O<anything>" with "-O2", which would
mean the space is getting replaced by the '2'.

I guess the fix would be to fix the ebuild by adding an extra space to the
replacement.
Comment 2 Joshua Kinard gentoo-dev 2003-10-23 00:18:42 UTC
Try a later version of gcc, like 3.3.1-r5 or even the newer 3.3.2, and report
back how that works.  I myself haven't had any problems.
Comment 3 Alexander Gabert (RETIRED) gentoo-dev 2004-03-04 07:03:20 UTC
is this is a problem with the flag-o-matic eclass or the gcc ebuild manipulating CFLAGS?

if problem with flag-o-matic, this may be researched by the portage crew.

if gcc does something nasty with the given CFLAGS, the ebuild should be fixed, which is kind of non-severe because we now have so much new versions ;-)

The original ebuild has been removed from cvs long time ago i can see...

You could do me a favour and try this:

CFLAGS="-O -mcpu=i686" and add a replace-flags to an ebuild of your choice and do the smoke test if this will provoke the odd behaviour.

if replace-flags is failing or doing something wrong and also resetting the CFLAGS to contain no space between the replaces arguments, we have to investigate the problem a bit further.

if it was just an oddity of the ebuild in question, i would rather like to close this bug report

thanks for your help in resolving this,

Alex
Comment 4 SpanKY gentoo-dev 2004-04-18 22:36:28 UTC
i've tweaked flag-o-matic to prevent flag mangling of this type

plus, gcc-3.3.1-r4 is outdated