This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Node build failing because of new nan version #11288
Copy link
Copy link
Closed
Labels
Node.jsnode-mapbox-gl-native
Description
Platform: node
Mapbox SDK version: master@dfb9b26e675a152a925fcc5b84c3e14b8b9779d2
Steps to trigger behavior
npm install --build-from-source
Expected behavior
It builds
Actual behavior
▸ Building library libmbgl-loop-uv.a
▸ Building mbgl/mbgl-node [Debug]
▸ Check Dependencies
▸ Compiling node_expression.cpp
▸ Compiling node_feature.cpp
▸ Compiling node_logging.cpp
▸ Compiling node_mapbox_gl_native.cpp
▸ Compiling node_map.cpp
❌ /Users/jesse/projects/mapbox-gl-native/platform/node/src/node_map.cpp:484:13: 'Call' is deprecated [-Werror,-Wdeprecated-declarations]
cb->Call(1, argv);
^
❌ /Users/jesse/projects/mapbox-gl-native/platform/node/src/node_map.cpp:500:13: 'Call' is deprecated [-Werror,-Wdeprecated-declarations]
cb->Call(2, argv);
^
❌ /Users/jesse/projects/mapbox-gl-native/platform/node/src/node_map.cpp:505:13: 'Call' is deprecated [-Werror,-Wdeprecated-declarations]
cb->Call(1, argv);
^
▸ Compiling node_request.cpp
▸ Compiling node_thread_pool.cpp
▸ Linking mbgl-node.node
❌ ld: file not found: /Users/jesse/projects/mapbox-gl-native/build/macos/mbgl.build/Debug/mbgl-node.build/Objects-normal/x86_64/node_map.o
❌ clang: error: linker command failed with exit code 1 (use -v to see invocation)
▸ Running script 'CMake PostBuild Rules'
** BUILD FAILED **
The following build commands failed:
CompileC build/macos/mbgl.build/Debug/mbgl-node.build/Objects-normal/x86_64/node_map.o platform/node/src/node_map.cpp normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler
Ld build/macos/Debug/mbgl-node.node normal x86_64
PhaseScriptExecution CMake\ PostBuild\ Rules build/macos/mbgl.build/Debug/mbgl-node.build/Script-D0C6C748918A4ABE848C3A55.sh
(3 failures)
make: *** [node] Error 65
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! @mapbox/[email protected] install: `node-pre-gyp install --fallback-to-build=false || make node`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the @mapbox/[email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/jesse/.npm/_logs/2018-02-22T22_21_50_875Z-debug.log
The problem seems to be a new release of https://github.com/nodejs/nan, both 2.9.0 and 2.9.1 were released today. This entry in the changelog for 2.9.0 seems like it might be the problem.
Deprecation: Deprecate legacy Callback::Call 6dd5fa690af61ca3523004b433304c581b3ea309
Changing package.json to force use of nan 2.8.0 fixes the problem.
Metadata
Metadata
Assignees
Labels
Node.jsnode-mapbox-gl-native
Activity
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
[core,node] Pin 'nan' to ~2.8 to avoid Callback::Call deprecation.
kkaefer commentedon May 23, 2018
Fixed in #11913