mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-30 05:51:45 -09:00
package/libgeos: bump version to 3.14.0
Changelog: https://github.com/libgeos/geos/releases/tag/3.14.0 Bump minimal GCC version to 7. (Switched to C++17 as minimum requirement)e142764b77Since commit26292ce880libgeos uses fenv.h to catch FPU exceptions. Some libc implementation may have no fenv support. So add a patch to detect fenv.h availability. Signed-off-by: Maxim Kochetkov <fido_max@inbox.ru> [Julien: - reformat patch title to fix check-package error - add Upstream header in patch to fix check-package error ] Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
committed by
Julien Olivain
parent
cbc3cb2c8d
commit
c7be3e6038
@@ -0,0 +1,71 @@
|
|||||||
|
From a6bac7bd506988085fa692ff2e12727ae0e9db84 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Maxim Kochetkov <fido_max@inbox.ru>
|
||||||
|
Date: Mon, 15 Sep 2025 17:16:08 +0300
|
||||||
|
Subject: [PATCH] geosop: make floating-point exceptions optional
|
||||||
|
|
||||||
|
commit 26292ce ("geosop: show most floating-point exceptions in verbose mode")
|
||||||
|
add fenv.h dependency. Some libc implementations (uclibc-ng )may have no fenv
|
||||||
|
support. So make floating-point exceptions optional and detetct fenv.h at
|
||||||
|
configure stage.
|
||||||
|
|
||||||
|
Upstream: https://github.com/libgeos/geos/pull/1305
|
||||||
|
Signed-off-by: Maxim Kochetkov <fido_max@inbox.ru>
|
||||||
|
---
|
||||||
|
CMakeLists.txt | 7 +++++++
|
||||||
|
util/geosop/GeosOp.cpp | 6 ++++++
|
||||||
|
2 files changed, 13 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||||
|
index 12411e586..a1e2f0c6e 100644
|
||||||
|
--- a/CMakeLists.txt
|
||||||
|
+++ b/CMakeLists.txt
|
||||||
|
@@ -558,3 +558,10 @@ if(PROJECT_IS_TOP_LEVEL)
|
||||||
|
|
||||||
|
unset(_is_multi_config_generator)
|
||||||
|
endif() # PROJECT_IS_TOP_LEVEL
|
||||||
|
+
|
||||||
|
+include(CheckIncludeFile)
|
||||||
|
+check_include_file(fenv.h HAVE_FENV_H)
|
||||||
|
+
|
||||||
|
+if(HAVE_FENV_H)
|
||||||
|
+ target_compile_definitions(geos_cxx_flags INTERFACE HAVE_FENV)
|
||||||
|
+endif()
|
||||||
|
diff --git a/util/geosop/GeosOp.cpp b/util/geosop/GeosOp.cpp
|
||||||
|
index 2cb17f000..05307cf30 100644
|
||||||
|
--- a/util/geosop/GeosOp.cpp
|
||||||
|
+++ b/util/geosop/GeosOp.cpp
|
||||||
|
@@ -26,7 +26,9 @@
|
||||||
|
#include <geos/io/WKBStreamReader.h>
|
||||||
|
#include <geos/io/WKBWriter.h>
|
||||||
|
|
||||||
|
+#if defined(HAVE_FENV)
|
||||||
|
#include <cfenv>
|
||||||
|
+#endif
|
||||||
|
#include <fstream>
|
||||||
|
#include <iostream>
|
||||||
|
#include <sstream>
|
||||||
|
@@ -394,10 +396,13 @@ void GeosOp::run(OpArguments& opArgs) {
|
||||||
|
//------------------------
|
||||||
|
|
||||||
|
try {
|
||||||
|
+#if defined(HAVE_FENV)
|
||||||
|
std::feclearexcept(FE_ALL_EXCEPT); // clear floating-point status flags
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
execute(op, opArgs);
|
||||||
|
|
||||||
|
+#if defined(HAVE_FENV)
|
||||||
|
// Catch everything except for FE_INEXACT, which is usually harmless
|
||||||
|
const int fpexp = std::fetestexcept(FE_ALL_EXCEPT ^ FE_INEXACT);
|
||||||
|
if (args.isVerbose && (fpexp != 0)) {
|
||||||
|
@@ -414,6 +419,7 @@ void GeosOp::run(OpArguments& opArgs) {
|
||||||
|
std::cerr << " FE_UNDERFLOW";
|
||||||
|
std::cerr << std::endl;
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
}
|
||||||
|
catch (std::exception &e) {
|
||||||
|
std::cerr << "Run-time exception: " << e.what() << std::endl;
|
||||||
|
--
|
||||||
|
2.51.0
|
||||||
|
|
||||||
@@ -3,7 +3,7 @@ config BR2_PACKAGE_LIBGEOS
|
|||||||
depends on BR2_INSTALL_LIBSTDCPP
|
depends on BR2_INSTALL_LIBSTDCPP
|
||||||
depends on BR2_USE_WCHAR
|
depends on BR2_USE_WCHAR
|
||||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||||
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # C++14
|
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # C++17
|
||||||
help
|
help
|
||||||
GEOS (Geometry Engine - Open Source) is a C++ port of the
|
GEOS (Geometry Engine - Open Source) is a C++ port of the
|
||||||
JTS Topology Suite (JTS). It aims to contain the complete
|
JTS Topology Suite (JTS). It aims to contain the complete
|
||||||
@@ -13,7 +13,7 @@ config BR2_PACKAGE_LIBGEOS
|
|||||||
|
|
||||||
https://trac.osgeo.org/geos
|
https://trac.osgeo.org/geos
|
||||||
|
|
||||||
comment "libgeos needs a toolchain w/ C++, wchar, gcc >= 4.9, threads"
|
comment "libgeos needs a toolchain w/ C++, wchar, gcc >= 7, threads"
|
||||||
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR || \
|
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR || \
|
||||||
!BR2_TOOLCHAIN_HAS_THREADS || \
|
!BR2_TOOLCHAIN_HAS_THREADS || \
|
||||||
!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
|
!BR2_TOOLCHAIN_GCC_AT_LEAST_7
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
# Locally calculated
|
# Locally calculated
|
||||||
sha256 df2c50503295f325e7c8d7b783aca8ba4773919cde984193850cf9e361dfd28c geos-3.13.1.tar.bz2
|
sha256 fe85286b1977121894794b36a7464d05049361bedabf972e70d8f9bf1e3ce928 geos-3.14.0.tar.bz2
|
||||||
sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING
|
sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
#
|
#
|
||||||
################################################################################
|
################################################################################
|
||||||
|
|
||||||
LIBGEOS_VERSION = 3.13.1
|
LIBGEOS_VERSION = 3.14.0
|
||||||
LIBGEOS_SITE = http://download.osgeo.org/geos
|
LIBGEOS_SITE = http://download.osgeo.org/geos
|
||||||
LIBGEOS_SOURCE = geos-$(LIBGEOS_VERSION).tar.bz2
|
LIBGEOS_SOURCE = geos-$(LIBGEOS_VERSION).tar.bz2
|
||||||
LIBGEOS_LICENSE = LGPL-2.1
|
LIBGEOS_LICENSE = LGPL-2.1
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ config BR2_PACKAGE_POSTGIS
|
|||||||
bool "postgis"
|
bool "postgis"
|
||||||
depends on BR2_PACKAGE_POSTGRESQL_FULL
|
depends on BR2_PACKAGE_POSTGRESQL_FULL
|
||||||
depends on BR2_INSTALL_LIBSTDCPP # libgeos, proj
|
depends on BR2_INSTALL_LIBSTDCPP # libgeos, proj
|
||||||
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libgeos
|
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # libgeos
|
||||||
depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # proj
|
depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # proj
|
||||||
depends on BR2_USE_WCHAR # libgeos, proj
|
depends on BR2_USE_WCHAR # libgeos, proj
|
||||||
select BR2_PACKAGE_LIBGEOS
|
select BR2_PACKAGE_LIBGEOS
|
||||||
@@ -17,6 +17,6 @@ config BR2_PACKAGE_POSTGIS
|
|||||||
|
|
||||||
https://postgis.net/
|
https://postgis.net/
|
||||||
|
|
||||||
comment "postgis needs a toolchain w/ C++, NPTL, wchar, gcc >= 4.9"
|
comment "postgis needs a toolchain w/ C++, NPTL, wchar, gcc >= 7"
|
||||||
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 || \
|
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_GCC_AT_LEAST_7 || \
|
||||||
!BR2_TOOLCHAIN_HAS_THREADS_NPTL || !BR2_USE_WCHAR
|
!BR2_TOOLCHAIN_HAS_THREADS_NPTL || !BR2_USE_WCHAR
|
||||||
|
|||||||
Reference in New Issue
Block a user