Leaflet.VectorGrid
Leaflet.VectorGrid copied to clipboard
Build requirements and how to build Leaflet.VectorGrid
Is there a more recent version available? I can find 1.3.0 (3 years old) but I would need a more recent version to have #132 included (merged in 2019).
My attempt to build this project (using npm 6.13.7 and 6.14.4 on Linux, gcc version 7.5.0) failed:
npm install
...
CXX(target) Release/obj.target/magic/src/binding.o
../src/binding.cc:345:28: error: ‘Handle’ has not been declared
static void Initialize(Handle<Object> target) {
^~~~~~
../src/binding.cc:345:34: error: expected ‘,’ or ‘...’ before ‘<’ token
static void Initialize(Handle<Object> target) {
^
../src/binding.cc: In static member function ‘static void Magic::New(const Nan::FunctionCallbackInfo<v8::Value>&)’:
../src/binding.cc:83:45: error: no matching function for call to ‘v8::Value::Int32Value()’
magic_flags = args[1]->Int32Value();
^
In file included from /home/peter/.cache/node-gyp/12.3.1/include/node/node.h:63:0,
from ../src/binding.cc:1:
/home/peter/.cache/node-gyp/12.3.1/include/node/v8.h:2569:40: note: candidate: v8::Maybe<int> v8::Value::Int32Value(v8::Local<v8::Context>) const
V8_WARN_UNUSED_RESULT Maybe<int32_t> Int32Value(Local<Context> context) const;
^~~~~~~~~~
/home/peter/.cache/node-gyp/12.3.1/include/node/v8.h:2569:40: note: candidate expects 1 argument, 0 provided
../src/binding.cc:91:51: error: no matching function for call to ‘v8::Value::ToString()’
String::Utf8Value str(args[0]->ToString());
^
....
Failed at the [email protected] install script
What are the build requirements? Maybe I need an older version of npm?
Hey @karussell - fyi I just tried to build this on macos 10.15.6
and encountered the same issue.
I was using node 12.18.2
, npm 6.14.5
.
I tried a bunch of node-gyp
related things (e.g.) but had no luck.
I just downgrading node to 10.22.0
, and used with npm 6.14.6
- and managed to get a successful build.. 🤷♂️
@danwild still getting failures on 10.22.0 and 6.14.6