Page MenuHomePhabricator

compilation of mapnik node module fails with new kartotherian packaging repo
Closed, ResolvedPublic


As discussed on parent task, we try to add a layer of indirection to the deployment of tilerator / kartotherian, to all us to add additional dependencies.

An experimental new repo contains the minimal set of files to use it as glue:

When building this repo (./server.js build --deploy-repo --force) the compilation of mapnik node module fails (P6396). This is most probably due to some mistake I did in package.json, but no idea which one...

Event Timeline

Gehel created this task.Nov 30 2017, 2:03 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptNov 30 2017, 2:03 PM
Gehel added a comment.Nov 30 2017, 2:19 PM

As far as I can tell, the error is around:

../../mapnik-vector-tile/src/vector_tile_featureset_pbf.ipp:252:55:   required from 'mapnik::feature_ptr mapnik::vector_tile_impl::tile_featureset_pbf<Filter>::next() [with Filter = mapnik::filter_at_point; mapnik::feature_ptr = std::shared_ptr<mapnik::feature_impl>]'
../src/mapnik_vector_tile.cpp:6636:1:   required from here
/usr/include/c++/4.9/ext/new_allocator.h:120:4: error: no matching function for call to 'mapnik::raster::raster(mapnik::box2d<double>&, mapnik::box2d<double>&, mapnik::image_any, double&)'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
/usr/include/c++/4.9/ext/new_allocator.h:120:4: note: candidate is:
In file included from ../../mapnik-vector-tile/src/vector_tile_featureset_pbf.ipp:10:0,
                 from ../../mapnik-vector-tile/src/vector_tile_featureset_pbf.hpp:69,
                 from ../../mapnik-vector-tile/src/vector_tile_datasource_pbf.ipp:2,
                 from ../../mapnik-vector-tile/src/vector_tile_datasource_pbf.hpp:68,
                 from ../../mapnik-vector-tile/src/vector_tile_composite.hpp:5,
                 from ../src/mapnik_vector_tile.cpp:15:
/usr/include/mapnik/raster.hpp:48:5: note: template<class ImageData> mapnik::raster::raster(const mapnik::box2d<double>&, ImageData&&, double)
     raster(box2d<double> const& ext,
/usr/include/mapnik/raster.hpp:48:5: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/4.9/bits/c++allocator.h:33:0,
                 from /usr/include/c++/4.9/bits/allocator.h:46,
                 from /usr/include/c++/4.9/vector:61,
                 from /home/runuser/.node-gyp/6.11.3/include/node/v8.h:22,
                 from /home/runuser/.node-gyp/6.11.3/include/node/node.h:42,
                 from ../../../../../nan/nan.h:47,
                 from ../src/utils.hpp:7,
                 from ../src/mapnik_vector_tile.cpp:1:
/usr/include/c++/4.9/ext/new_allocator.h:120:4: note:   cannot convert 'std::forward<mapnik::image_any>((* & __args#2))' (type 'mapnik::image_any') to type 'double'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
make: *** [Release/] Error 1 recipe for target 'Release/' failed
make: Leaving directory '/opt/service/node_modules/@mapbox/blend/node_modules/mapnik/build'

This seems to be the same version of mapnik and the same version of node that were previously used and working. So that very much points to the error being in the new package.json, but I'm entirely unsure what I should be looking for.

Gehel added a comment.Nov 30 2017, 8:56 PM

node-mapnik seems to require G++ >= 5, jessie comes with 4.9. Which begs the question: how did it work before?

Gehel added a comment.Dec 1 2017, 10:12 AM

Digging into this with @Pnorman, we found that mapnik 3.6.2 was dragged via an updated transitive dependency. We are in the process of cleaning that up and see if it works...

Change 394576 had a related patch set uploaded (by Gehel; owner: Gehel):
[maps/kartotherian/package@master] Bump Kartotherian version

Change 394576 merged by Gehel:
[maps/kartotherian/package@master] Bump Kartotherian version

Gehel moved this task from Backlog to Done on the Maps-Sprint board.Dec 1 2017, 3:20 PM
Fjalapeno closed this task as Resolved.Jan 10 2018, 2:09 AM