Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't install mdns package on ubuntu 22.04 and nodejs v20.13.0 #265

Closed
ernestas17 opened this issue May 23, 2024 · 2 comments
Closed

Can't install mdns package on ubuntu 22.04 and nodejs v20.13.0 #265

ernestas17 opened this issue May 23, 2024 · 2 comments

Comments

@ernestas17
Copy link

ernestas17 commented May 23, 2024

When runing comand npm i mdns (or npm ci when package is added to package.js) getting error

rutkauskaser@MED-RUTKAUSKASE:~/Desktop/dpv/server/telemedicine/backend$ npm i
npm warn deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm warn deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
npm warn deprecated source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
npm warn deprecated tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see palantir/tslint#4534 for more information.
npm warn deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm error code 1
npm error path /home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns
npm error command failed
npm error command sh -c node-gyp rebuild
npm error make: Entering directory '/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns/build'
npm error CXX(target) Release/obj.target/dns_sd_bindings/src/dns_sd.o
npm error make: Leaving directory '/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns/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.13.0 | linux | x64
npm error gyp info find Python using Python version 3.10.12 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/rutkauskaser/Desktop/dpv/server/telemedicine/backend/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/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns/build/config.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/node-gyp/addon.gypi',
npm error gyp info spawn args '-I',
npm error gyp info spawn args '/home/rutkauskaser/.cache/node-gyp/20.13.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/rutkauskaser/.cache/node-gyp/20.13.0',
npm error gyp info spawn args '-Dnode_gyp_dir=/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/node-gyp',
npm error gyp info spawn args '-Dnode_lib_file=/home/rutkauskaser/.cache/node-gyp/20.13.0/<(target_arch)/node.lib',
npm error gyp info spawn args '-Dmodule_root_dir=/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns',
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 gyp info spawn make
npm error gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm error cc1plus: error: /usr/local/include/x86_64-linux-gnu: Permission denied
npm error make: *** [dns_sd_bindings.target.mk:176: Release/obj.target/dns_sd_bindings/src/dns_sd.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/rutkauskaser/Desktop/dpv/server/telemedicine/backend/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.5.0-35-generic
npm error gyp ERR! command "/home/rutkauskaser/.nvm/versions/node/v20.13.0/bin/node" "/home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/.bin/node-gyp" "rebuild"
npm error gyp ERR! cwd /home/rutkauskaser/Desktop/dpv/server/telemedicine/backend/node_modules/mdns
npm error gyp ERR! node -v v20.13.0
npm error gyp ERR! node-gyp -v v8.4.1
npm error gyp ERR! not ok

npm error A complete log of this run can be found in: /home/rutkauskaser/.npm/_logs/2024-05-23T14_20_14_199Z-debug-0.log

About my local setup environment:
OS: Ubuntu 22.04
Node: v20.13.0
NPM: 10.7.0

@ernestas17 ernestas17 changed the title Can't install mdns package on ububtu 22.04 and nodejs v20.13.0 Can't install mdns package on ubuntu 22.04 and nodejs v20.13.0 May 23, 2024
@agnat
Copy link
Owner

agnat commented May 24, 2024

npm error gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm error cc1plus: error: /usr/local/include/x86_64-linux-gnu: Permission denied
npm error make: ***

I don’t think this is an issue with the mdns package. I think it’s a local problem with the c++ toolchain (compiler, linker, &c.).

@agnat
Copy link
Owner

agnat commented Jun 3, 2024

Hoping this got resolved I'm going to close this ticket. Feel free to reopen if it is in fact an issue with the mdns package.

@agnat agnat closed this as completed Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants