bin/114082: [make.conf] default CFLAGS have a blank at the end
Alexander Best
arundel at freebsd.org
Tue Sep 7 14:20:08 UTC 2010
The following reply was made to PR bin/114082; it has been noted by GNATS.
From: Alexander Best <arundel at freebsd.org>
To: bug-followup at freebsd.org
Cc:
Subject: Re: bin/114082: [make.conf] default CFLAGS have a blank at the end
Date: Tue, 7 Sep 2010 14:15:39 +0000
--r5Pyd7+fXNt84Ff3
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
the following patch works for me. it ensures that ${_CPUCFLAGS} doesn't get
appended to CFLAGS, as well as to COPTFLAGS, if it hasn't been defined or is
empty.
cheers.
alex
--
a13x
--r5Pyd7+fXNt84Ff3
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="bsd.cpu.mk-and-kern.pre.mk.diff"
diff --git a/share/mk/bsd.cpu.mk b/share/mk/bsd.cpu.mk
index e3ad18b..fa7fb32 100644
--- a/share/mk/bsd.cpu.mk
+++ b/share/mk/bsd.cpu.mk
@@ -6,6 +6,7 @@
.if !defined(CPUTYPE) || empty(CPUTYPE)
_CPUCFLAGS =
+NO_CPU_CFLAGS =
. if ${MACHINE_ARCH} == "i386"
MACHINE_CPU = i486
. elif ${MACHINE_ARCH} == "amd64"
diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk
index d4bdc1f..9929176 100644
--- a/sys/conf/kern.pre.mk
+++ b/sys/conf/kern.pre.mk
@@ -23,6 +23,10 @@ NM?= nm
OBJCOPY?= objcopy
SIZE?= size
+.if !defined(CPUTYPE) || empty(CPUTYPE)
+_CPUCFLAGS =
+NO_CPU_COPTFLAGS =
+.endif
.if ${CC:T:Micc} == "icc"
COPTFLAGS?= -O
.else
--r5Pyd7+fXNt84Ff3--
More information about the freebsd-bugs
mailing list