From a8938978b9bc964f0812c9c79539a91df2763867 Mon Sep 17 00:00:00 2001 From: Quentin Cozette Date: Thu, 8 Apr 2021 19:19:10 +0200 Subject: [PATCH] Fix openturns build - avoid native swig (UB16) and avoid native nlopt (native UB20/FD32) --- products/compil_scripts/openturns.sh | 1 + products/openturns.pyconf | 2 +- products/patches/openturns_nlopt.patch | 11 +++++++++++ 3 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 products/patches/openturns_nlopt.patch diff --git a/products/compil_scripts/openturns.sh b/products/compil_scripts/openturns.sh index d51bb22..3a787d1 100755 --- a/products/compil_scripts/openturns.sh +++ b/products/compil_scripts/openturns.sh @@ -8,6 +8,7 @@ CMAKE_OPTIONS="" CMAKE_OPTIONS=$CMAKE_OPTIONS" -DCMAKE_INSTALL_PREFIX:STRING=${PRODUCT_INSTALL}" CMAKE_OPTIONS=$CMAKE_OPTIONS" -DCMAKE_BUILD_TYPE:STRING=Release" CMAKE_OPTIONS=$CMAKE_OPTIONS" -DPYTHON_EXECUTABLE=${PYTHON_ROOT_DIR}/bin/python" +CMAKE_OPTIONS=$CMAKE_OPTIONS" -DSWIG_EXECUTABLE=${SWIG_ROOT_DIR}/bin/swig" echo echo "*** cmake" $CMAKE_OPTIONS diff --git a/products/openturns.pyconf b/products/openturns.pyconf index fa3efc3..ef18348 100644 --- a/products/openturns.pyconf +++ b/products/openturns.pyconf @@ -28,5 +28,5 @@ default_win : version_1_16 : { - patches : ['openturns-1.16.0001.patch'] + patches : ['openturns-1.16.0001.patch', 'openturns_nlopt.patch'] } diff --git a/products/patches/openturns_nlopt.patch b/products/patches/openturns_nlopt.patch new file mode 100644 index 0000000..bd99012 --- /dev/null +++ b/products/patches/openturns_nlopt.patch @@ -0,0 +1,11 @@ +--- new_openturns/CMakeLists.txt 2021-04-08 17:38:10.804000000 +0200 ++++ openturns/CMakeLists.txt 2021-04-08 18:08:15.428000000 +0200 +@@ -268,7 +268,7 @@ + endif () + + if (USE_NLOPT) +-# find_package (NLopt CONFIG QUIET) ++ find_package (NLopt CONFIG QUIET) + if (NLopt_FOUND) + message(STATUS "Found NLopt: ${NLopt_DIR}") + else () -- 2.39.2