Vlastimil Babka wrote:
> Peter Gordon wrote:
>> On Tue, 2007-07-17 at 19:47 -0400, Mike Frysinger wrote:
>>> historically, gcc on x86 has always defaulted to i386.  some people noticed 
>>> recently that glibc-2.6 fails to build in this situation as they were only 
>>> setting -mtune via CFLAGS, not -march.  i'll be tweaking gcc so that it 
>>> will 
>>> default -march based on your CHOST.  so all the i686-* people will now have 
>>> a 
>>> default -march=i686 implied in their gcc systems, i586-* people will 
>>> have -march=i586, etc...  keep in mind this is merely the default.
>>> -mike
>> Does this mean that any user-set "-march" flag is overridden for these
>> cases? Just curious.
> 
> I think he meant CHOST sets just *default* so any user-set -march
> overrides that.
> But I wonder what happens to user-set -mtune then? Since AFAIK -march
> implies -mtune, will also the default -march override user-set -mtune?

Previously GCC defaulted to -march=i386, which implied -mtune=i386
(actually, -mcpu for some reason (?)), when neither were set.  People
are setting CFLAGS="-mtune=pentium4 -O2 -fblah..." which therefore is
defaulting to -march=i386 -mtune=pentium4.  glibc-2.6 requires >=
-march=i486.  Kaboom.

Now -march=$(echo $CHOST | awk -F- '{ print $1 }'), which implies
-mtune=echo $CHOST | awk -F- '{ print $1 }' when neither are set.  If
_either_ are set by the user, they are overridden.

ie. you can still set -march=i386 or -mtune=i386 or whatever you like.

-- 
dirtyepic                 salesman said this vacuum's guaranteed
 gentoo org          it could suck an ancient virus from the sea
  9B81 6C9F E791 83BB 3AB3  5B2D E625 A073 8379 37E8 (0x837937E8)

-- 
[EMAIL PROTECTED] mailing list

Reply via email to