electron-quick-start icon indicating copy to clipboard operation
electron-quick-start copied to clipboard

Missing shared libraries

Open qbitroot opened this issue 3 years ago • 19 comments

When I run npm start, it shows the following output:

> [email protected] start /tmp/electron-quick-start
> electron .

/tmp/electron-quick-start/node_modules/electron/dist/electron: error while loading shared libraries: libcups.so.2: cannot open shared object file: No such file or directory
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! [email protected] start: `electron .`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] start 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!     /home/user/.npm/_logs/2021-05-20T16_43_01_585Z-debug.log

As 4th line says, there is no libcups shared library. I tried installing it, but there are new missing shared libraries. I don't use systemd and it may be one of the reasons of bug.

After hours of troubleshooting, I solved it by putting .so libraries from Debian 10 image into the dist directory. You can download them from the attachment (for testing purposes).

qbitroot avatar May 20 '21 16:05 qbitroot

I've never used linxsis

DrockDaniel avatar Jan 05 '22 10:01 DrockDaniel

Sorry I'm pooped out.

DrockDaniel avatar Jan 05 '22 10:01 DrockDaniel

im using wsl 2 on windows 11, and im getting the same error. #519 point to this issue. So im kinda stuck in the loop, any ideas?

The error:

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! [email protected] start: electron . npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the [email protected] start 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! /home/fullpl4nch3/.npm/_logs/2022-01-24T12_57_29_222Z-debug.log

steps to reproduce: npm install && npm start

fullpl4nch3 avatar Jan 24 '22 12:01 fullpl4nch3

@qbitroot @fullpl4nch3 if use wsl, please try

rm -rdf node_modules
npm install --platform=win32

to tell dependenies your are running on a win system. this resolved my problem.

genru avatar Feb 25 '22 11:02 genru

Unfortunately the above command from @genru didn't work for me. Trying to run the overmind dev tools via npx and am running into this same error. Any help greatly appreciated, thank you in advance

burt23 avatar Mar 03 '22 23:03 burt23

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

tammaroivan avatar Jun 13 '22 06:06 tammaroivan

sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev

Thanks @tammaroivan , you legend!

PoweredByEnergyDrinks avatar Sep 18 '22 14:09 PoweredByEnergyDrinks

Having this issue today in Selenium IDE and I solved it by installing google-chrome in ubuntu on Windows WSL and using vcxsrv as Windows X Server with export DISPLAY ... in .bashrc ... (of course it also worked for this quick start then)

giuliohome avatar Oct 01 '22 10:10 giuliohome

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

This worked!!!

anbarasu97 avatar Oct 05 '22 06:10 anbarasu97

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

I love you

LuigiImVector avatar Oct 15 '22 12:10 LuigiImVector

Ok, better to unsubscribe this thread

giuliohome avatar Oct 15 '22 13:10 giuliohome

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

awesome

long9nt avatar Dec 08 '22 10:12 long9nt

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

Thanks, worked for me bro!

danielwust99 avatar Jul 13 '23 17:07 danielwust99

I ran the same command sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev and got this error: error while loading shared libraries: libasound.so.2: cannot open shared object file: No such file or directory

what else could I try?

ValsiRod avatar Nov 15 '23 10:11 ValsiRod

I ran the same command sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev and got this error: error while loading shared libraries: libasound.so.2: cannot open shared object file: No such file or directory

what else could I try?

Try install the apel release packages before run.

danielwust99 avatar Dec 01 '23 12:12 danielwust99

I ran the same command sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev and got this error: error while loading shared libraries: libasound.so.2: cannot open shared object file: No such file or directory

what else could I try?

sudo apt-get install libasound2

this works for me

TeqGin avatar Jan 06 '24 09:01 TeqGin

There is this closed issue about documenting runtime (as opposed to build time) dependencies for Electron: https://github.com/electron/electron/issues/26673

marcospgp avatar Jan 11 '24 19:01 marcospgp

Thank you so much @tammaroivan 💯

manojborugadda avatar Apr 01 '24 09:04 manojborugadda

Could you try with sudo apt install libnss3-dev libgdk-pixbuf2.0-dev libgtk-3-dev libxss-dev, that worked for me

thanks ! that works

Carolzhangzz avatar Jul 22 '24 17:07 Carolzhangzz