Package Details: python-mapbox-earcut 1.0.1-1

Git Clone URL: https://aur.archlinux.org/python-mapbox-earcut.git (read-only, click to copy)
Package Base: python-mapbox-earcut
Description: Python bindings for the C++ implementation of the Mapbox Earcut library.
Upstream URL: https://github.com/skogler/mapbox_earcut_python
Licenses: custom
Submitter: groctel
Maintainer: groctel
Last Packager: groctel
Votes: 4
Popularity: 0.90
First Submitted: 2021-04-04 16:32 (UTC)
Last Updated: 2023-11-26 10:19 (UTC)

Latest Comments

michael.platzer commented on 2021-07-21 15:53 (UTC)

With GCC 11 this package fails to compile with following error (repeated several times):

/home/michael/.cache/pacaur/python-mapbox-earcut/src/mapbox_earcut_python-0.12.10/include/mapbox/earcut.hpp:469:23: error: ‘numeric_limits’ is not a member of ‘std’
  469 |     double qx = -std::numeric_limits<double>::infinity();
      |                       ^~~~~~~~~~~~~~

The reason seems to be that some headers are less frequently included in libstdc++, see: https://www.gnu.org/software/gcc/gcc-11/porting_to.html

While waiting for an upstream fix, applying the following patch to the PKGBUILD fixes the issue:

diff --git a/PKGBUILD b/PKGBUILD
index b71f965..f8d72e3 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -33,6 +33,7 @@ prepare ()
 build ()
 {
        cd "$srcdir/$_name-$pkgver"
+       echo "#include <limits>" | cat - include/mapbox/earcut.hpp > tmp && mv tmp include/mapbox/earcut.hpp
        python setup.py build
 }

groctel commented on 2021-05-28 12:36 (UTC)

Thank you @fl0r1an! I've updated the dependencies :)

fl0r1an commented on 2021-05-27 21:13 (UTC)

I think there are 2 packages missing in the makedepends.

I made the package in a chroot and it says that the command git was not found and later, the command pip was not found. I added git and python-pip to the makedepends and then it worked.

Kind regards :)