From: http://wiki.mozilla.org/Linux/Compiler_Options#Proper_use_of_compiler_options Seems that firefox should be compiled with "--enable-optimize" plain option letting firefox parts be compiled with different flags chosen by mozilla for each component Also, ebuild is now calling "edit_makefiles" (from makeedit.eclass) and I am not sure if it could affect to this also Thanks Reproducible: Always
Collides with peoples wish that /their/ compiler flags are used, probably not bad to do so with, when the bindist use flag is set, though.
(In reply to comment #1) > Collides with peoples wish that /their/ compiler flags are used, probably not > bad to do so with, when the bindist use flag is set, though. > upstream suggests simply export CFLAGS and CXXFLAGS variables to desired values for this in conjuction with --enable-optimize usage :-)
(In reply to comment #2) > (In reply to comment #1) > > Collides with peoples wish that /their/ compiler flags are used, probably not > > bad to do so with, when the bindist use flag is set, though. > > > > upstream suggests simply export CFLAGS and CXXFLAGS variables to desired values > for this in conjuction with --enable-optimize usage :-) > And thats we do.
(In reply to comment #3) > And thats we do. > But seems (from their wiki page) that also "--enable-optimize" (without any other argument) should be used also
(In reply to comment #4) > (In reply to comment #3) > > And thats we do. > > > > But seems (from their wiki page) that also "--enable-optimize" (without any > other argument) should be used also > But that would override user's -O value.
(In reply to comment #5) > But that would override user's -O value. > Yes, but other CFLAGS like -march would still be applied. This could be maybe handled with a USE flag like "custom-cflags" or anything else...
Well , after re-reading the wiki: > If you still need to pass in other non-optimization flags to the compile, please > use CFLAGS and CXXFLAGS instead of passing them to --enable-optimize. Only CFLAGS without -O should be used in conjuction with "--enable-optimize" for compile firefox like mozilla wants :-/, maybe "filter-flags" from flag-o-matic.eclass could be used for filter -O* when merging without "custom-cflags" USE enabled...
I have also seen that "edit_makefiles" from makedit.eclass seems no longer needed with firefox3 because running: $ find . \( -iname makefile -o -name \*.mk -o -name GNUmakefile \) from sources dir doesn't output anything (not like in 2.0, that makes it output a lot of files)
I'm looking into this, but i'd say its a bit crazy to use those flags added by mozilla... We'll see...
(In reply to comment #9) > I'm looking into this, but i'd say its a bit crazy to use those flags added by > mozilla... I'd not say so. It's the question what the specific optimizations are and what hardware they used for profiling. Optimizations based on profiling may result in quite better performing code, but I doubt these optimizations are really optimal for almost all machines. What may mozilla.org use to build? -march=i686 -O2 and a number of -mtune= flags!?
(In reply to comment #10) > What may mozilla.org use to build? -march=i686 -O2 and a number of -mtune= > flags!? > mozilla will only change -O* values, it doesn't change or specifies -march or -mtune, you can see one example of this in: https://bugzilla.mozilla.org/show_bug.cgi?id=409803#c9 Then, firefox ebuild should only filter all -O* flags for letting mozilla choose its default, all other FLAGS (like -march=k8, for example) would be preserved as user chosen in his make.conf
Fixed