From 8f30a5af25a34523e937e7c8096705b6214dcd88 Mon Sep 17 00:00:00 2001 From: Tony Theodore Date: Mon, 13 Aug 2018 22:13:32 +1000 Subject: [PATCH] =?UTF-8?q?cmake=20toolchain:=20fix=20gcc=20=E2=89=A5=206?= =?UTF-8?q?=20with=20CMAKE=5F=5FIMPLICIT=5FINCLUDE=5FDIRECTORIES?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/cmake/conf/mxe-conf.cmake.in | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/cmake/conf/mxe-conf.cmake.in b/src/cmake/conf/mxe-conf.cmake.in index b0ab0923..8fb213fd 100644 --- a/src/cmake/conf/mxe-conf.cmake.in +++ b/src/cmake/conf/mxe-conf.cmake.in @@ -49,6 +49,15 @@ set(CMAKE_INSTALL_PREFIX @PREFIX@/@TARGET@ CACHE PATH "Installation Prefix") # For custom mxe FindPackage scripts set(CMAKE_MODULE_PATH "@PREFIX@/share/cmake/modules" ${CMAKE_MODULE_PATH}) +# projects (mis)use `-isystem` to silence warnings from 3rd-party +# source (among other things). gcc6 introduces changes to search +# order which breaks this usage. +# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70129 +# https://gitlab.kitware.com/cmake/cmake/issues/16291 +# https://gitlab.kitware.com/cmake/cmake/issues/16919 +set(CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES @PREFIX@/@TARGET@/include) +set(CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES @PREFIX@/@TARGET@/include) + ## Programs set(CMAKE_C_COMPILER @PREFIX@/bin/@TARGET@-gcc)