Operating system
Linux
Joplin version
3.0.1
What issue do you have?
I am trying to install on Fedora 39 using the supported route. I check the dependency on Node 12+
node -v
v20.17.0
npm -v
10.8.2
but the command suggested here, i.e. NPM_CONFIG_PREFIX=~/.joplin-bin npm install -g joplin
, fails with:
npm error code 1
npm error path /home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp
npm error command failed
npm error command sh -c node install/check
npm error sharp: Detected globally-installed libvips v8.15.1
npm error sharp: Attempting to build from source via node-gyp
npm error sharp: Found node-addon-api
npm error sharp: Found node-gyp version 8.4.1
npm error sharp: See https://sharp.pixelplumbing.com/install#building-from-source
npm error make: Entering directory '/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp/src/build'
npm error CC(target) Release/obj.target/nothing/../../node-addon-api/nothing.o
npm error AR(target) Release/obj.target/../../node-addon-api/nothing.a
npm error COPY Release/nothing.a
npm error TOUCH Release/obj.target/libvips-cpp.stamp
npm error CXX(target) Release/obj.target/sharp-linux-x64/common.o
npm error CXX(target) Release/obj.target/sharp-linux-x64/metadata.o
npm error make: Leaving directory '/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp/src/build'
npm error gyp info it worked if it ends with ok
npm error gyp info using node-gyp@8.4.1
npm error gyp info using node@20.17.0 | linux | x64
npm error gyp info chdir src
npm error gyp info find Python using Python version 3.12.7 found at "/usr/bin/python3"
npm error gyp info spawn /usr/bin/python3
npm error gyp info spawn args [
npm error gyp info spawn args '/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/node-gyp/gyp/gyp_main.py',
npm error gyp info spawn args 'binding.gyp',
npm error gyp info spawn args '-f',
npm error gyp info spawn args 'make',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp/src/build/config.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/node-gyp/addon.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/home/rms/.cache/node-gyp/20.17.0/include/node/common.gypi',
npm error gyp info spawn args '-Dlibrary=shared_library',
npm error gyp info spawn args '-Dvisibility=default',
npm error gyp info spawn args '-Dnode_root_dir=/home/rms/.cache/node-gyp/20.17.0',
npm error gyp info spawn args '-Dnode_gyp_dir=/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/node-gyp',
npm error gyp info spawn args '-Dnode_lib_file=/home/rms/.cache/node-gyp/20.17.0/<(target_arch)/node.lib',
npm error gyp info spawn args '-Dmodule_root_dir=/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp/src',
npm error gyp info spawn args '-Dnode_engine=v8',
npm error gyp info spawn args '--depth=.',
npm error gyp info spawn args '--no-parallel',
npm error gyp info spawn args '--generator-output',
npm error gyp info spawn args 'build',
npm error gyp info spawn args '-Goutput_dir=.'
npm error gyp info spawn args ]
npm error <string>:114: SyntaxWarning: invalid escape sequence '\/'
npm error gyp info spawn make
npm error gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm error ../metadata.cc: In member function ‘virtual void MetadataWorker::OnOK()’:
npm error ../metadata.cc:233:46: error: ‘NewOrCopy’ is not a member of ‘Napi::Buffer<char>’
npm error 233 | info.Set("exif", Napi::Buffer<char>::NewOrCopy(env, baton->exif, baton->exifLength, sharp::FreeCallback));
npm error | ^~~~~~~~~
npm error ../metadata.cc:236:45: error: ‘NewOrCopy’ is not a member of ‘Napi::Buffer<char>’
npm error 236 | info.Set("icc", Napi::Buffer<char>::NewOrCopy(env, baton->icc, baton->iccLength, sharp::FreeCallback));
npm error | ^~~~~~~~~
npm error ../metadata.cc:239:46: error: ‘NewOrCopy’ is not a member of ‘Napi::Buffer<char>’
npm error 239 | info.Set("iptc", Napi::Buffer<char>::NewOrCopy(env, baton->iptc, baton->iptcLength, sharp::FreeCallback));
npm error | ^~~~~~~~~
npm error ../metadata.cc:242:45: error: ‘NewOrCopy’ is not a member of ‘Napi::Buffer<char>’
npm error 242 | info.Set("xmp", Napi::Buffer<char>::NewOrCopy(env, baton->xmp, baton->xmpLength, sharp::FreeCallback));
npm error | ^~~~~~~~~
npm error ../metadata.cc:246:31: error: ‘NewOrCopy’ is not a member of ‘Napi::Buffer<char>’
npm error 246 | Napi::Buffer<char>::NewOrCopy(env, baton->tifftagPhotoshop,
npm error | ^~~~~~~~~
npm error make: *** [sharp-linux-x64.target.mk:172: Release/obj.target/sharp-linux-x64/metadata.o] Error 1
npm error gyp ERR! build error
npm error gyp ERR! stack Error: `make` failed with exit code: 2
npm error gyp ERR! stack at ChildProcess.onExit (/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/node-gyp/lib/build.js:194:23)
npm error gyp ERR! stack at ChildProcess.emit (node:events:519:28)
npm error gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:294:12)
npm error gyp ERR! System Linux 6.11.3-100.fc39.x86_64
npm error gyp ERR! command "/usr/bin/node-20" "/home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/.bin/node-gyp" "rebuild" "--directory=src"
npm error gyp ERR! cwd /home/rms/.joplin-bin/lib/node_modules/joplin/node_modules/sharp/src
npm error gyp ERR! node -v v20.17.0
npm error gyp ERR! node-gyp -v v8.4.1
npm error gyp ERR! not ok
Please advise.