Skip to content

npm install returns errors #63

@guyluz11

Description

@guyluz11

I have cloned the project, did npm install and got errors

$ npm install
npm WARN old lockfile 
npm WARN old lockfile The package-lock.json file was created with an old version of npm,
npm WARN old lockfile so supplemental metadata must be fetched from the registry.
npm WARN old lockfile 
npm WARN old lockfile This is a one-time fix-up, please be patient...
npm WARN old lockfile 
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated rimraf@3.0.0: Rimraf versions prior to v4 are no longer supported
npm WARN deprecated glob@7.1.6: Glob versions prior to v9 are no longer supported
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated lodash.get@4.4.2: This package is deprecated. Use the optional chaining (?.) operator instead.
npm WARN deprecated glob@7.1.6: Glob versions prior to v9 are no longer supported
npm WARN deprecated flat@4.1.0: Fixed a prototype pollution security issue in 4.1.0, please upgrade to ^4.1.1 or ^5.0.1.
npm WARN deprecated are-we-there-yet@1.1.5: This package is no longer supported.
npm WARN deprecated sinon@8.1.1: 16.1.1
npm WARN deprecated jquery@3.4.1: This version is deprecated. Please upgrade to the latest version or find support at https://www.herodevs.com/support/jquery-nes.
npm WARN deprecated highlight.js@9.18.0: Version no longer supported. Upgrade to @latest
npm WARN deprecated debug@3.2.6: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated glob@7.1.3: Glob versions prior to v9 are no longer supported
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
npm WARN deprecated inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
npm WARN deprecated npmlog@2.0.4: This package is no longer supported.
npm WARN deprecated mkdirp@0.5.1: Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)
npm WARN deprecated gauge@1.2.7: This package is no longer supported.
npm ERR! code 1
npm ERR! path /home/zrho/Documents/git/node-appletv/node_modules/mdns
npm ERR! command failed
npm ERR! command sh -c node-gyp rebuild
npm ERR! make: Entering directory '/home/zrho/Documents/git/node-appletv/node_modules/mdns/build'
npm ERR!   CXX(target) Release/obj.target/dns_sd_bindings/src/dns_sd.o
npm ERR! make: Leaving directory '/home/zrho/Documents/git/node-appletv/node_modules/mdns/build'
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.3.0
npm ERR! gyp info using node@18.19.1 | linux | x64
npm ERR! gyp info find Python using Python version 3.12.3 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/zrho/Documents/git/node-appletv/node_modules/mdns/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/zrho/Documents/git/node-appletv/node_modules/mdns',
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! In file included from ../src/mdns.hpp:12,
npm ERR!                  from ../src/dns_sd.cpp:1:
npm ERR! ../node_modules/nan/nan.h: In function ‘void Nan::AsyncQueueWorker(AsyncWorker*):
npm ERR! ../node_modules/nan/nan.h:2298:7: warning: cast between incompatible function types from ‘void (*)(uv_work_t*) {aka ‘void (*)(uv_work_s*)} to ‘uv_after_work_cb’ {aka ‘void (*)(uv_work_s*, int)} [-Wcast-function-type]
npm ERR!  2298 |     , reinterpret_cast<uv_after_work_cb>(AsyncExecuteComplete)
npm ERR!       |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! ../node_modules/nan/nan.h: In function ‘void Nan::SetAccessor(v8::Local<v8::ObjectTemplate>, v8::Local<v8::String>, GetterCallback, SetterCallback, v8::Local<v8::Value>, v8::AccessControl, v8::PropertyAttribute, imp::Sig):
npm ERR! ../node_modules/nan/nan.h:2536:19: warning: ‘void v8::ObjectTemplate::SetAccessor(v8::Local<v8::Name>, v8::AccessorNameGetterCallback, v8::AccessorNameSetterCallback, v8::Local<v8::Value>, v8::AccessControl, v8::PropertyAttribute, v8::Local<v8::AccessorSignature>, v8::SideEffectType, v8::SideEffectType) is deprecated: Do signature check in accessor [-Wdeprecated-declarations]
npm ERR!  2536 |   tpl->SetAccessor(
npm ERR!       |   ~~~~~~~~~~~~~~~~^
npm ERR!  2537 |       name
npm ERR!       |       ~~~~         
npm ERR!  2538 |     , getter_
npm ERR!       |     ~~~~~~~~~      
npm ERR!  2539 |     , setter_
npm ERR!       |     ~~~~~~~~~      
npm ERR!  2540 |     , obj
npm ERR!       |     ~~~~~          
npm ERR!  2541 |     , settings
npm ERR!       |     ~~~~~~~~~~     
npm ERR!  2542 |     , attribute
npm ERR!       |     ~~~~~~~~~~~    
npm ERR!  2543 |     , signature);
npm ERR!       |     ~~~~~~~~~~~~   
npm ERR! In file included from /usr/include/nodejs/deps/v8/include/v8-function.h:15,
npm ERR!                  from /usr/include/nodejs/deps/v8/include/v8.h:33,
npm ERR!                  from /usr/include/nodejs/src/node.h:73,
npm ERR!                  from ../src/mdns.hpp:11:
npm ERR! /usr/include/nodejs/deps/v8/include/v8-template.h:838:8: note: declared here
npm ERR!   838 |   void SetAccessor(
npm ERR!       |        ^~~~~~~~~~~
npm ERR! In file included from ../node_modules/nan/nan.h:2884:
npm ERR! ../node_modules/nan/nan_typedarray_contents.h: In constructor ‘Nan::TypedArrayContents<T>::TypedArrayContents(v8::Local<v8::Value>):
npm ERR! ../node_modules/nan/nan_typedarray_contents.h:34:43: error: ‘class v8::ArrayBuffer’ has no member named ‘GetContents’
npm ERR!    34 |       data   = static_cast<char*>(buffer->GetContents().Data()) + byte_offset;
npm ERR!       |                                           ^~~~~~~~~~~
npm ERR! ../src/dns_sd.cpp: At global scope:
npm ERR! /usr/include/nodejs/src/node.h:1014:7: warning: cast between incompatible function types from ‘void (*)(v8::Local<v8::Object>) to ‘node::addon_register_func’ {aka ‘void (*)(v8::Local<v8::Object>, v8::Local<v8::Value>, void*)} [-Wcast-function-type]
npm ERR!  1014 |       (node::addon_register_func) (regfunc),                          \
npm ERR!       |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
npm ERR! /usr/include/nodejs/src/node.h:1048:3: note: in expansion of macro ‘NODE_MODULE_X’
npm ERR!  1048 |   NODE_MODULE_X(modname, regfunc, NULL, 0)  // NOLINT (readability/null_usage)
npm ERR!       |   ^~~~~~~~~~~~~
npm ERR! ../src/dns_sd.cpp:319:1: note: in expansion of macro ‘NODE_MODULE’
npm ERR!   319 | NODE_MODULE(dns_sd_bindings,node_mdns::init);
npm ERR!       | ^~~~~~~~~~~
npm ERR! make: *** [dns_sd_bindings.target.mk:180: Release/obj.target/dns_sd_bindings/src/dns_sd.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.8.0-55-generic
npm ERR! gyp ERR! command "/usr/bin/node" "/usr/share/nodejs/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /home/zrho/Documents/git/node-appletv/node_modules/mdns
npm ERR! gyp ERR! node -v v18.19.1
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!     /home/zrho/.npm/_logs/2025-03-23T18_17_57_136Z-debug-0.log

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions