From 403a4ef8e1c9101ace84097872f1840cfa731e03 Mon Sep 17 00:00:00 2001 From: Guillaume Pasero <guillaume.pasero@c-s.fr> Date: Mon, 30 Apr 2018 12:47:47 +0200 Subject: [PATCH] BUG: #1574: fix detection of std::isnan in GEOS --- SuperBuild/patches/GEOS/geos-2-isnan-all.diff | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 SuperBuild/patches/GEOS/geos-2-isnan-all.diff diff --git a/SuperBuild/patches/GEOS/geos-2-isnan-all.diff b/SuperBuild/patches/GEOS/geos-2-isnan-all.diff new file mode 100644 index 0000000000..52c99bb4c5 --- /dev/null +++ b/SuperBuild/patches/GEOS/geos-2-isnan-all.diff @@ -0,0 +1,17 @@ +--- GEOS-orig/CMakeLists.txt 2018-04-30 12:38:44.089392211 +0200 ++++ GEOS/CMakeLists.txt 2018-04-30 12:41:18.754980452 +0200 +@@ -189,7 +189,13 @@ + include(CheckPrototypeExists) + include(CheckSymbolExists) + +-check_prototype_exists(isnan cmath HAVE_STD_ISNAN) ++CHECK_CXX_SOURCE_COMPILES(" ++#include <cmath> ++int main() ++{ ++ bool a = std::isnan(3.14); ++ return 0; ++}" HAVE_STD_ISNAN) + if(NOT HAVE_STD_ISNAN) + if(MSVC) + check_prototype_exists(_isnan float.h HAVE_ISNAN) -- GitLab