From ecf8298ab7bba40963efc59896ccaa40d325dacf Mon Sep 17 00:00:00 2001 From: Dmitry Marakasov Date: Tue, 15 Sep 2015 21:24:42 +0000 Subject: [PATCH] - Use -isystem instead of -I to add ${LOCALBASE}/include to the list of header search paths First, this prevents ports which use strict -Werror settings from build failures in third party headers (real life example is devel/pructl which uses -Werror -Weverything and fails in libedit header on actually harmless padding warning). Second, this prevents ports which install headers from picking up their own headers from LOCALBASE instead of using ones from WRKDIR, which leads to any kind of problems when upgrading via ports. PR: 203101 Approved by: bapt Differential Revision: D3618 --- Mk/Uses/localbase.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Mk/Uses/localbase.mk b/Mk/Uses/localbase.mk index 5e2873656a94..8f0c3c61db0a 100644 --- a/Mk/Uses/localbase.mk +++ b/Mk/Uses/localbase.mk @@ -11,9 +11,9 @@ .if !defined(_INCLUDE_USES_LOCALBASE_MK) _INCLUDE_USES_LOCALBASE_MK= yes -CPPFLAGS+= -I${LOCALBASE}/include -CFLAGS+= -I${LOCALBASE}/include -CXXFLAGS+= -I${LOCALBASE}/include +CPPFLAGS+= -isystem ${LOCALBASE}/include +CFLAGS+= -isystem ${LOCALBASE}/include +CXXFLAGS+= -isystem ${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib # Use CONFIGURE_ENV instead of CMAKE_ARGS because devel/cmake itself also needs