summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authorbdrewery <bdrewery@FreeBSD.org>2016-05-29 01:15:15 +0000
committerbdrewery <bdrewery@FreeBSD.org>2016-05-29 01:15:15 +0000
commit7a3ab2fa78cc54e513671d181b33cbce79c453cf (patch)
tree17dae25e223095e4c64130fff696c7b24d25c136 /usr.bin
parent996c4295dbb6ebc1b8025f370bf680d8242f9f8f (diff)
downloadFreeBSD-src-7a3ab2fa78cc54e513671d181b33cbce79c453cf.zip
FreeBSD-src-7a3ab2fa78cc54e513671d181b33cbce79c453cf.tar.gz
Fix with external GCC after r300886.
Somehow the /usr/include path got lost in this particular case. Just pass it along from --sysroot as was already done for DIRDEPS_BUILD. Sponsored by: EMC / Isilon Storage Division
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/xlint/llib/Makefile11
1 files changed, 10 insertions, 1 deletions
diff --git a/usr.bin/xlint/llib/Makefile b/usr.bin/xlint/llib/Makefile
index bcf93c4..df79a75 100644
--- a/usr.bin/xlint/llib/Makefile
+++ b/usr.bin/xlint/llib/Makefile
@@ -16,6 +16,15 @@ llib-lstdc.ln: llib-lstdc
.include <bsd.prog.mk>
-.if ${MK_DIRDEPS_BUILD} == "yes"
+.if !empty(STAGE_INCLUDEDIR)
LINTFLAGS+= -I${STAGE_INCLUDEDIR}
+.else
+.if ${CFLAGS:M--sysroot=*} != ""
+_sysroot?= ${CFLAGS:M--sysroot=*:[1]:C,^--sysroot=,,}
+.elif ${CC:M--sysroot=*} != ""
+_sysroot?= ${CC:M--sysroot=*:[1]:C,^--sysroot=,,}
+.endif
+.if !empty(_sysroot)
+LINTFLAGS+= -I${_sysroot}/usr/include
+.endif
.endif
OpenPOWER on IntegriCloud