From 9adf63225aa0723773fec0982a4012e5b886884f Mon Sep 17 00:00:00 2001
From: bdm-oslandia <benoit.de.mezzo@oslandia.com>
Date: Fri, 5 Apr 2024 08:16:15 +0200
Subject: [PATCH] chore(CMakeLists.txt): add flag to exclude SFCGAL system
 libray from build

In case SFCGAL is already installed by a package manager, cmake builds with the system lib
first and does not take into account the local modifications. This flag allows to ignore
system includes during build phase.

ref PR !304
---
 CMakeLists.txt | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index b18da939..1d9affa4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,6 +4,10 @@ project( SFCGAL )
 set( CMAKE_DEBUG_POSTFIX "d" )
 set(CMAKE_CXX_STANDARD 17)
 
+# ignore system installed SFCGAL to avoid conflicts during build/edit
+list(APPEND CMAKE_IGNORE_PREFIX_PATH "/usr/include/SFCGAL")
+list(APPEND CMAKE_IGNORE_PREFIX_PATH "/usr/local/include/SFCGAL")
+
 #
 # Cmake policies
 #