good (working) CFLAGS for SPARC64 (Christian Baer)

Steven Hillis evultrole at gmail.com
Wed Feb 21 21:58:49 UTC 2007


Christian,

Apologies for the confusion, I gave you working tags from memory, not my
make.conf file (i've been jockeying back and forth between a FreeBSD and a
gentoo box, and use the same tags on them both, -mcpu on gentoo, -mtune on
freebsd).

FreeBSD sparc64 only supports ultrasparc and ultrasparcII cpus, so far as I
know, so -mcpu=ultrasparc is superfluous. I in fact have -mtune=ultrasparc,
since they likely use the v9 standard for FreeBSD since they seem to be
attempting Ultrasparc III support. Again, I'm sorry about my bad memory.

-mcpu=ultrasparc and -m64 should both be useless options under Sparc64, as
far as I can tell.

My actual make.conf file is as follows:
CFLAGS=-O2 -pipe -mtune=ultrasparc -mvis -mapp-regs -fomit-frame-pointer
-ffast-math -fweb -frename-registers
COPTFLAGS=-O2 -pipe -mtune=ultrasparc -mvis -mapp-regs -fomit-frame-pointer
-ffast-math -fweb -frename-registers
NO_MODULES=YES
NO_PROFILE=YES

.if (!empty(.CURDIR:M/usr/src*) || !empty(.CURDIR:M/usr/obj*)) &&
!defined(NOCCACHE)
CC=/usr/local/libexec/ccache/world-cc
CXX=/usr/local/libexec/ccache/world-c++
.endif

Those flags compile without a hitch. Again, Sparc64 is only for ultrasparc
CPUs, so that's not really needed.

The question is (this is aimed at Marius, et al), why does setting the -mcpu
flag unset the __sparc64__ definition in so many places? This is what your
errors came from, there are about 20 files that will do that.

~Steven


More information about the freebsd-sparc64 mailing list