r189218 - Simplify now that -O4 just maps to -O3 and -O is an alias of -O2.

Sylvestre Ledru sylvestre at debian.org
Thu Sep 5 08:49:35 PDT 2013


Le 03/09/2013 19:07, Rafael Espíndola a écrit :
>> Ok, makes sense.  Those uses can use an explicit -O1 though :-)
> Sure.
>
>>> I haven't seen -O being used in wild, so I OK with keeping it mapping to -O2.
>> I'd be curious to know how many files in a linux distro are built with -O.  I wouldn't be surprised if it is  5-10%.
> Sylvestre might know how to answer that :-)
Well, in Debian and Ubuntu, we are providing some default CFLAGS & CXXFLAGS.
For example:
$ dpkg-buildflags --get CFLAGS
-g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat
-Werror=format-security

However, it has to be managed both by the package itself and the
upstream build system.

I will try to make some statistics on the build log of Debian but I
don't remember seeing -O (but I saw some -O6 or even -O20).

Sylvestre




More information about the cfe-commits mailing list