node-epd icon indicating copy to clipboard operation
node-epd copied to clipboard

npm install fails on Raspberry Pi Zero 2 W

Open prithwirajbose opened this issue 6 months ago • 0 comments

I am trying to install the library on Raspberry Pi Zero 2 W but the gyp build fails. I have the prerequisites installed. Here is the error log:

root@raspberrypi:/home/pi/workspaces/nodejs/epaper# npm i node-epd npm ERR! code 1 npm ERR! path /home/pi/workspaces/nodejs/epaper/node_modules/node-epd npm ERR! command failed npm ERR! command sh -c node-gyp rebuild npm ERR! make: Entering directory '/home/pi/workspaces/nodejs/epaper/node_modules/node-epd/build' npm ERR! CXX(target) Release/obj.target/epd/src/lcd.o npm ERR! make: Leaving directory '/home/pi/workspaces/nodejs/epaper/node_modules/node-epd/build' npm ERR! gyp info it worked if it ends with ok npm ERR! gyp info using [email protected] npm ERR! gyp info using [email protected] | linux | arm64 npm ERR! gyp info find Python using Python version 3.11.2 found at "/usr/bin/python3" npm ERR! gyp info spawn /usr/bin/python3 npm ERR! gyp info spawn args [ npm ERR! gyp info spawn args '/usr/share/nodejs/node-gyp/gyp/gyp_main.py', npm ERR! gyp info spawn args 'binding.gyp', npm ERR! gyp info spawn args '-f', npm ERR! gyp info spawn args 'make', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/home/pi/workspaces/nodejs/epaper/node_modules/node-epd/build/config.gypi', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/usr/share/nodejs/node-gyp/addon.gypi', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/usr/include/nodejs/common.gypi', npm ERR! gyp info spawn args '-Dlibrary=shared_library', npm ERR! gyp info spawn args '-Dvisibility=default', npm ERR! gyp info spawn args '-Dnode_root_dir=/usr/include/nodejs', npm ERR! gyp info spawn args '-Dnode_gyp_dir=/usr/share/nodejs/node-gyp', npm ERR! gyp info spawn args '-Dnode_lib_file=/usr/include/nodejs/<(target_arch)/node.lib', npm ERR! gyp info spawn args '-Dmodule_root_dir=/home/pi/workspaces/nodejs/epaper/node_modules/node-epd', npm ERR! gyp info spawn args '-Dnode_engine=v8', npm ERR! gyp info spawn args '--depth=.', npm ERR! gyp info spawn args '--no-parallel', npm ERR! gyp info spawn args '--generator-output', npm ERR! gyp info spawn args 'build', npm ERR! gyp info spawn args '-Goutput_dir=.' npm ERR! gyp info spawn args ] npm ERR! gyp info spawn make npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ] npm ERR! ../src/lcd.cc: In static member function ‘static void EpdLcd::Init()’: npm ERR! ../src/lcd.cc:76:40: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’ npm ERR! 76 | constructor.Reset(ctor->GetFunction()); npm ERR! | ~~~~~~~~~~~~~~~~~^~ npm ERR! compilation terminated due to -Wfatal-errors. npm ERR! make: *** [epd.target.mk:120: Release/obj.target/epd/src/lcd.o] Error 1 npm ERR! gyp ERR! build error npm ERR! gyp ERR! stack Error: make failed with exit code: 2 npm ERR! gyp ERR! stack at ChildProcess.onExit (/usr/share/nodejs/node-gyp/lib/build.js:203:23) npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:517:28) npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:292:12) npm ERR! gyp ERR! System Linux 6.12.25+rpt-rpi-v8 npm ERR! gyp ERR! command "/usr/bin/node" "/usr/share/nodejs/node-gyp/bin/node-gyp.js" "rebuild" npm ERR! gyp ERR! cwd /home/pi/workspaces/nodejs/epaper/node_modules/node-epd npm ERR! gyp ERR! node -v v18.19.0 npm ERR! gyp ERR! node-gyp -v v9.3.0 npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2025-07-14T23_42_57_411Z-debug-0.log

prithwirajbose avatar Jul 14 '25 23:07 prithwirajbose