From 7520e86ab3e9326259cc7cfc5511150becd8eb9d Mon Sep 17 00:00:00 2001 From: AnyOldName3 Date: Wed, 17 Sep 2025 19:02:51 +0100 Subject: [PATCH] Don't treat the repo root as a system include directory This is a regression from https://gitlab.com/OpenMW/openmw/-/commit/99ba45a308c09f01976da483160dba93007413d1#9a2aa4db38d3115ed60da621e012c0efc0172aae_322_319, and caused many of our headers not to generate warnings. It also combined with MSVC bug https://developercommunity.visualstudio.com/t/Including-a-header-with-pragma-system_h/10968424?port=1025&fsid=327e3050-e79a-41b0-8237-b262a60103e3 to prevent warnings in any TU that includes a CMake-generated precompiled header. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 834668e92a..66b4e9debc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -481,8 +481,8 @@ set(SOL_INCLUDE_DIR ${OpenMW_SOURCE_DIR}/extern/sol3) set(SOL_CONFIG_DIR ${OpenMW_SOURCE_DIR}/extern/sol_config) include_directories( - BEFORE SYSTEM "." + BEFORE SYSTEM ${MyGUI_INCLUDE_DIRS} ${OPENAL_INCLUDE_DIR} ${OPENGL_INCLUDE_DIR}