The package rpms/earcut-hpp.git has added or updated architecture specific content in its
spec file (ExclusiveArch/ExcludeArch or %ifarch/%ifnarch) in commit(s):
https://src.fedoraproject.org/cgit/rpms/earcut-hpp.git/commit/?id=6db1576....
Change:
+%ifarch %{arm64} ppc64le s390x
Thanks.
Full change:
============
commit 6db1576f8f0ce501e49cc533cfd508a7e6b21b2d
Author: Benjamin A. Beasley <code(a)musicinmybrain.net>
Date: Tue Oct 26 10:19:37 2021 -0400
Initial package (close RHBZ#2006590)
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..204f04d
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+/earcut.hpp-2.2.3.tar.gz
diff --git a/96.patch b/96.patch
new file mode 100644
index 0000000..abced75
--- /dev/null
+++ b/96.patch
@@ -0,0 +1,39 @@
+From 6e3944e1e164e50575addc11e218773d45c61b8a Mon Sep 17 00:00:00 2001
+From: "Benjamin A. Beasley" <code(a)musicinmybrain.net>
+Date: Tue, 21 Sep 2021 17:59:54 -0400
+Subject: [PATCH] Include headers for everything used in std::
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Manual implementation of the “include what you use” idea, i.e., do not
+rely on implementation-dependent recursive includes.
+
+Added:
+
+- cstddef for: std::size_t
+- limits for: std::numeric_limits
+- utility for: std::forward, std::move
+
+Assumed to be specialized in user code, or a header included therefrom:
+
+ std::get<Point>, std::tuple_element<Point>
+---
+ include/mapbox/earcut.hpp | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/include/mapbox/earcut.hpp b/include/mapbox/earcut.hpp
+index 01bd7e9..e7d4308 100644
+--- a/include/mapbox/earcut.hpp
++++ b/include/mapbox/earcut.hpp
+@@ -3,7 +3,10 @@
+ #include <algorithm>
+ #include <cassert>
+ #include <cmath>
++#include <cstddef>
++#include <limits>
+ #include <memory>
++#include <utility>
+ #include <vector>
+
+ namespace mapbox {
diff --git a/earcut-hpp.spec b/earcut-hpp.spec
new file mode 100644
index 0000000..67d5853
--- /dev/null
+++ b/earcut-hpp.spec
@@ -0,0 +1,113 @@
+Name: earcut-hpp
+Summary: Fast, header-only polygon triangulation
+Version: 2.2.3
+Release: %autorelease
+
+URL:
https://github.com/mapbox/earcut.hpp
+License: ISC
+
+Source0: %{url}/archive/v%{version}/earcut.hpp-%{version}.tar.gz
+
+# Include headers for everything used in std::
+#
https://github.com/mapbox/earcut.hpp/pull/96
+Patch0:
https://github.com/mapbox/earcut.hpp/pull/96.patch
+
+BuildRequires: gcc-c++
+BuildRequires: cmake
+# Our choice; the default UNIX Makefiles backend would also work
+BuildRequires: ninja-build
+
+# For tests (and benchmarks, if enabled):
+BuildRequires: pkgconfig(opengl)
+
+# A copy of libtess2 (
https://github.com/memononen/libtess2) is bundled with
+# the tests as a reference implementation.
+#
+# We do not treat it as a bundled system library (no virtual Provides, for
+# example) because it is provably used only in the tests, and does not
+# contribute to anything installed in the binary RPM. This is just as well, as
+# libtess2 is unmaintained and we would rather not have to package it
+# separately.
+
+# No compiled binaries are installed, so this would be empty.
+%global debug_package %{nil}
+
+%global common_description %{expand:
+A C++ port of earcut.js, a fast, header-only polygon triangulation library.
+
+The library implements a modified ear slicing algorithm, optimized by z-order
+curve hashing and extended to handle holes, twisted polygons, degeneracies and
+self-intersections in a way that doesn’t guarantee correctness of
+triangulation, but attempts to always produce acceptable results for practical
+data like geographical shapes.
+
+It’s based on ideas from FIST: Fast Industrial-Strength Triangulation of
+Polygons by Martin Held and Triangulation by Ear Clipping by David Eberly.}
+
+%description %{common_description}
+
+
+%package devel
+Summary: %{summary}
+
+# Header-only library
+Provides: %{name}-static = %{version}-%{release}
+
+%description devel %{common_description}
+
+
+%prep
+%autosetup -n earcut.hpp-%{version} -p1
+# Increase precision of test output so we can understand any failures:
+sed -r -i 's/(setprecision\()6(\))/\116\2/' test/test.cpp
+
+%ifarch %{arm64} ppc64le s390x
+# With increased format precision in test/test.cpp, as above:
+# > not ok 83 earcut deviation 0.0000000000052002% is not less than
+# > 0.0000000000043556%
+# Loosen tolerance for “self_touching” test on certain architectures
+#
https://github.com/mapbox/earcut.hpp/issues/97
+sed -r -i 's/4\.35559[[:digit:]]+e-14/6\.2002e-14/' \
+ 'test/fixtures/self_touching.cpp'
+%endif
+
+
+%build
+# We do want to build the tests, but we have no use for the benchmarks or the
+# visualizer program.
+%cmake \
+ -DEARCUT_BUILD_TESTS:BOOL=ON \
+ -DEARCUT_BUILD_BENCH:BOOL=OFF \
+ -DEARCUT_BUILD_VIZ:BOOL=OFF \
+ -DEARCUT_WARNING_IS_ERROR:BOOL=OFF \
+ -GNinja
+%cmake_build
+
+
+%install
+# The upstream CMakeLists.txt has no install target; there is only one file to
+# copy, so it is easy to do manually.
+install -D -t '%{buildroot}%{_includedir}/mapbox' -p -m 0644 \
+ 'include/mapbox/earcut.hpp'
+
+
+%check
+# The upstream CMakeLists.txt has no install target; we run the test executable
+# manually.
+%{_vpath_builddir}/tests
+
+
+%files devel
+%license LICENSE
+%doc CHANGELOG.md
+%doc README.md
+
+# All -devel packages for C and C++ libraries from Mapbox should co-own this
+# directory.
+%dir %{_includedir}/mapbox
+
+%{_includedir}/mapbox/earcut.hpp
+
+
+%changelog
+%autochangelog
diff --git a/sources b/sources
new file mode 100644
index 0000000..cb95fe7
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+SHA512 (earcut.hpp-2.2.3.tar.gz) =
f87f0084dbbcda85b409c326587a376d443f2484b6a69c216d2ad94ea8ea238912dfe1174b464b08faec10ea5c29ebae6478e7abfe5ff682a7b043784c1e3acf