From 1a29bd50ff13cf8d9956fddc2cd256e71dab653b Mon Sep 17 00:00:00 2001 From: David Chisnall Date: Fri, 6 Sep 2013 20:42:14 +0000 Subject: [PATCH] Only set -Wno-c++11-extensions if we're building with clang, so bootstrapping clang with gcc doesn't fail. --- share/mk/bsd.own.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/share/mk/bsd.own.mk b/share/mk/bsd.own.mk index 48cce5cdd6c..39cf72e362c 100644 --- a/share/mk/bsd.own.mk +++ b/share/mk/bsd.own.mk @@ -431,7 +431,10 @@ __DEFAULT_NO_OPTIONS+=GCC GNUCXX # suppression when building the base system to catch bugs in our headers. # Eventually we'll want to start building the base system C++ code as C++11, # but not yet. +_COMPVERSION!= ${CC} --version +.if ${_COMPVERSION:Mclang} CXXFLAGS+= -Wno-c++11-extensions +.endif .else # If clang is not cc, then build gcc by default __DEFAULT_NO_OPTIONS+=CLANG_IS_CC