Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 14729 - Mozilla ebuild fails to build with -march=pentium4
Summary: Mozilla ebuild fails to build with -march=pentium4
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All All
: High normal
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-01-29 09:38 UTC by Garen
Modified: 2003-02-03 18:16 UTC (History)
0 users

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 Garen 2003-01-29 09:38:50 UTC
Bombs out when compiling javascript.  See http://gcc.gnu.org/cgi-
bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8994 and 
http://bugzilla.mozilla.org/show_bug.cgi?id=172618.

To be more specific, the implied -msse2 flag kills it, so -mcpu=pentium4 works 
fine but not -march.
Comment 1 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-01 00:44:42 UTC
Yes, its a gcc3 issue.  That is why there is the 'strip-flags' and changing
-march=pentium4 to -march=pentium3 in the ebuild.  If you remove those, what
do you want me to do ?
Comment 2 Garen 2003-02-01 04:52:50 UTC
Hmm.  I tracked the problem down from someone in the forums who had -march=pentium4 in 
their CFLAGS and reproduced it myself, so I figured the ebuild could just replace the -march 
with -mcpu or something else. 
 
Are you saying it's already supposed to change the -march=pentium4 setting?   
Comment 3 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-02 13:28:17 UTC
Yes, in theory.  What version of gcc ?
Comment 4 Garen 2003-02-02 23:51:29 UTC
Just the other day, I could reproduce the crash with 3.2.1, 3.2.1-r6 and 3.2.1-r7.  Now I can't.  
So I suppose either 
1) I'm losing my marbles and did something different before, or 
2) The ebuild changed 
 
I looked at the ebuild and noticed: 
 
        if [ "$(gcc-major-version)" -eq "3" ] 
        then 
                # Currently gcc-3.2 or older do not work well if we specify "-march" 
                # and other optimizations for pentium4. 
                export CFLAGS="${CFLAGS/-march=pentium4/-march=pentium3}" 
                export CXXFLAGS="${CXXFLAGS/-march=pentium4/-march=pentium3}" 
 
That could be changed to -mcpu=pentium4 instead.  The only difference is the -msse2 flag 
thats silently enabled (not well documented by gcc that it does this either.) 
 
 
Comment 5 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-03 14:09:40 UTC
Well, it could enable other stuff that makes -march=pentium4 so unstable, and
besides, I *know* pentium3 works 99% of the time fine.
Comment 6 Garen 2003-02-03 18:16:13 UTC
Yeah, probably a safer bet as its already set that way anyhow. 
Sorry for the crummy bug report. I'll do better next time.