Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 29 May 2016 01:15:15 +0000 (UTC)
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r300920 - head/usr.bin/xlint/llib
Message-ID:  <201605290115.u4T1FFYI086411@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bdrewery
Date: Sun May 29 01:15:15 2016
New Revision: 300920
URL: https://svnweb.freebsd.org/changeset/base/300920

Log:
  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

Modified:
  head/usr.bin/xlint/llib/Makefile

Modified: head/usr.bin/xlint/llib/Makefile
==============================================================================
--- head/usr.bin/xlint/llib/Makefile	Sun May 29 00:40:29 2016	(r300919)
+++ head/usr.bin/xlint/llib/Makefile	Sun May 29 01:15:15 2016	(r300920)
@@ -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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201605290115.u4T1FFYI086411>