From 48413367ef81450140b6a3a8fb2db6807100b862 Mon Sep 17 00:00:00 2001 From: Bryan Drewery Date: Wed, 29 Jun 2016 01:50:30 +0000 Subject: WITH_SYSTEM_COMPILER: Avoid using GCC4.8+ logic on native GCC4.2 platforms. As the XXX notes, these should really be checking MK_GNUCXX since there is already a version check in share/mk/src.opts.mk to disable it. Fixing that here is more complex though. This could also be using X_COMPILER_FEATURES but uses X_COMPILER_VERSION to keep in sync with the src.opts.mk logic. Tested by: andreast Sponsored by: EMC / Isilon Storage Division Approved by: re (gjb) --- Makefile.libcompat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Makefile.libcompat') diff --git a/Makefile.libcompat b/Makefile.libcompat index 4b923bb467b8..3182c8c33b01 100644 --- a/Makefile.libcompat +++ b/Makefile.libcompat @@ -81,8 +81,8 @@ LIBCOMPATCFLAGS+= -B${LIBCOMPATTMP}/usr/lib${libcompat} LIBCOMPATCFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include # Force using libc++ for external GCC. # XXX: This should be checking MK_GNUCXX == no -.if ${MK_CROSS_COMPILER} == "no" || \ - (${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no") +.if ${X_COMPILER_VERSION} >= 40800 && (${MK_CROSS_COMPILER} == "no" || \ + (${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no")) LIBCOMPATCXXFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \ -nostdinc++ -L${LIBCOMPAT_OBJTREE}${.CURDIR}/lib/libc++ .endif -- cgit v1.2.3