electron-userland / electron-builder

A complete solution to package and build a ready for distribution Electron app with “auto update” support out of the box
https://www.electron.build
MIT License
13.64k stars 1.74k forks source link

Linux build error "ELF SyntaxError: Invalid or unexpected token" #8624

Open avivsalman opened 2 days ago

avivsalman commented 2 days ago

i am getting this error after packing the application in linux (ubuntu) appimage + deb, i am trying to run the application after succesfullt build process and nothing happend, so i tryed to debug the app with electron inspect and i got this error:

"ELF SyntaxError: Invalid or unexpected token"

image
mmaietta commented 1 day ago

Are you intending to debug the packaged application? In which case, I thought that'd be

./dist/dokopos/linux-unpacked/dokopos --inspect=9229

IIRC, running with electron executable expects the file path to be a JS entry point, which is why you're receiving Unexpected token

avivsalman commented 1 day ago

@mmaietta

Yes you right, i understand that now, but i still have the same problem, just dont know how to debug..

After updating electron builder to version big than 24.13.3 the app not opening after packing, appimage dont open and there is no error, for the deb package the install are successful but after trying to run nothing happend..

So how to debig this and to get some error to handle it..?

mmaietta commented 1 day ago

Can you try using --inspect-brk=9229 to attach to the main process before it executes any code? From there, you should find what it's erroring on