Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 9 Apr 2008 18:44:35 +0100
From:      RW <fbsd06@mlists.homeunix.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Setting CPUTYPE and CFLAGS in make.conf
Message-ID:  <20080409184435.3bb4b91c@gumby.homeunix.com.>
In-Reply-To: <2daa8b4e0804081314o25b9773bn844734b674856e8c@mail.gmail.com>
References:  <2daa8b4e0804081314o25b9773bn844734b674856e8c@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 8 Apr 2008 13:14:45 -0700
"David Allen" <the.real.david.allen@gmail.com> wrote:

> The advice I've read in several posts on the subject involve
> everything from setting one, setting both, to ignoring both,
> sometimes with the =? notation and sometimes without.  And then, I've
> read comments that suggest when compiling the kernel, for example,
> both are ignored, and default values (tucked away somewhere) are
> always applied.  IIRC, the handbook recommends at least setting
> CPUTYPE.

Avoid setting CFLAGS unless you have a good reason - Gentoo
documentation has a lot to answer for. CPUTYPE causes "-march" to be
applied, so it can affect compatibility. AFAIK both setting do affect
world and kernel because CFLAGS can cause a build to fail, and I've
seen matching march settings in kernel builds.


> Or are those settings relevant to the
> compilation process only?  Or to both the compilation process and the
> actual performance of the binary?

It can be either, -O2 is related to execution, -pipe speeds-up
compilation.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080409184435.3bb4b91c>