FreeBSD 9 (amd64) buildworld stage 4.2 fails with clang: unknown target cpu i686

Scot Hetzel swhetzel at gmail.com
Sat Dec 29 19:03:06 UTC 2012


On Sat, Dec 29, 2012 at 8:34 AM, Mark van Dijk <lists at internecto.net> wrote:
> On 29-12-12 12:53, Mark van Dijk wrote:
>> I suspect that the error is caused by -march=native, my CPU is an Intel
>> Core i5.
>
> Looks like I was correct. CPUTYPE?=core2 will build world fine so
> perhaps 'native' does not know about my processor yet. Apparently it
> falls back to assuming it's a i686.
>

Tha problem that src/share/mk/bsd.cpu.mk doesn't know how to handle
CPUTYPE=native correctly.

CPUTYPE=core2
i386:
MACHINE_CPU = ssse3 sse3 sse2 sse i686 mmx i586 i486

amd64:
MACHINE_CPU = ssse3 sse3 amd64 sse2 sse mmx

CPUTYPE=native
i386:
MACHINE_CPU = i486

amd64:
MACHINE_CPU = amd64 sse2 sse mmx

See http://www.freebsd.org/cgi/query-pr.cgi?pr=conf/112997 for one possible fix.

-- 
DISCLAIMER:

No electrons were maimed while sending this message. Only slightly bruised.


More information about the freebsd-stable mailing list