diff options
author | bdrewery <bdrewery@FreeBSD.org> | 2016-05-27 23:03:28 +0000 |
---|---|---|
committer | bdrewery <bdrewery@FreeBSD.org> | 2016-05-27 23:03:28 +0000 |
commit | b945f26dce90425126b84cb6da21090a3b54d785 (patch) | |
tree | 836b938ab11b26e91704f5b027e742ca166ff983 /Makefile.libcompat | |
parent | 318ccd21e74b546bdda8d6035f22456f816b0027 (diff) | |
download | FreeBSD-src-b945f26dce90425126b84cb6da21090a3b54d785.zip FreeBSD-src-b945f26dce90425126b84cb6da21090a3b54d785.tar.gz |
Libcompat: Only pass -isystem =/usr/include for external GCC.
This is the same as the main build logic. GCC with a cross-compiler
requires using -isystem to =/usr/include to get the search order
correct.
Reported by: dim, asomers
Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'Makefile.libcompat')
-rw-r--r-- | Makefile.libcompat | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Makefile.libcompat b/Makefile.libcompat index 2cbaf2e..c966234 100644 --- a/Makefile.libcompat +++ b/Makefile.libcompat @@ -72,10 +72,9 @@ LIBCOMPATCFLAGS+= ${LIBCOMPATCPUFLAGS} \ # -B is needed to find /usr/lib32/crti.o for GCC and /usr/libsoft/crti.o for # Clang/GCC. LIBCOMPATCFLAGS+= -B${LIBCOMPATTMP}/usr/lib${libcompat} +.if defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} == gcc # GCC requires -isystem when using a cross-compiler. LIBCOMPATCFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include - -.if defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} == gcc # Force using libc++ for external GCC. LIBCOMPATCXXFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \ -nostdinc++ -L${LIBCOMPAT_OBJTREE}${.CURDIR}/lib/libc++ |