From 089d18ef757dd17c26f2a216b81841326dd7184e Mon Sep 17 00:00:00 2001 From: Ben Altieri Date: Fri, 8 May 2020 09:58:16 -0700 Subject: [PATCH] Revert "Fix cross compiling system includes (#45)" This reverts commit 5ad907857bd4967590f2b32fc1be5607659fbf81. --- GenericFindDependency.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/GenericFindDependency.cmake b/GenericFindDependency.cmake index 79869c8..4b8c1e8 100644 --- a/GenericFindDependency.cmake +++ b/GenericFindDependency.cmake @@ -347,7 +347,9 @@ function(GenericFindDependency) # Final validation that the target was properly created from some source if(TARGET ${x_TARGET}) if(x_SYSTEM_INCLUDES) - mark_target_as_system_includes(${x_TARGET}) + if(NOT CMAKE_CROSSCOMPILING OR THIRD_PARTY_INCLUDES_AS_SYSTEM) + mark_target_as_system_includes(${x_TARGET}) + endif() endif() else() # Target not found in any location