electron-builder icon indicating copy to clipboard operation
electron-builder copied to clipboard

Compressor "lzo" is not supported!

Open MikeJerred opened this issue 2 years ago • 8 comments

  • Electron-Builder Version: 23.2.0
  • Node Version: 16.14.2
  • Electron Version: 19.0.4
  • Electron Type (current, beta, nightly): current
  • Target: linux snap x64

If I add this setting to electron-builder.yml:

snap:
  compression: lzo

Then the build fails with:

  ⨯ cannot execute  cause=exit status 1
                    errorOut=/home/runner/.cache/electron-builder/appimage/appimage-12.0.1/linux-x64/mksquashfs: Compressor "lzo" is not supported!
    /home/runner/.cache/electron-builder/appimage/appimage-12.0.1/linux-x64/mksquashfs: Compressors available:
    	gzip (default)
    	xz

Either this is a bug, or the documentation is incorrect at https://www.electron.build/configuration/snap.html which states:

compression “xz” | “lzo” | “undefined” - Sets the compression type for the snap. Can be xz, lzo, or null.

MikeJerred avatar Jul 20 '22 09:07 MikeJerred

same problem,see here https://github.com/shensven/Yadds/runs/7433015109?check_suite_focus=true

shensven avatar Jul 20 '22 16:07 shensven

Same problem.

mkinitcpio avatar Sep 03 '22 21:09 mkinitcpio

Update: I found the root of problem. This version mksquashfs that used for build package don't have lzo compression flag.

Screenshot Screen Shot 2022-09-04 at 2 31 34 AM

Quick fix: create a symlink to the original mksquashfs from OS (MAC/linux)

For me it works now!

mkinitcpio avatar Sep 03 '22 23:09 mkinitcpio

@mkinitcpio do your AppImage builds still work?

MikeJerred avatar Sep 04 '22 08:09 MikeJerred

@MikeJerred Not tested yet, but now I have a problem with publishing to the snap store. Problem with checksum :(

mkinitcpio avatar Sep 04 '22 08:09 mkinitcpio

@mkinitcpio Might be related to this PR: https://github.com/electron-userland/electron-builder/pull/7110

I managed to get compression working but it required some monkey-patching of app-builder-lib

MikeJerred avatar Sep 04 '22 09:09 MikeJerred

@MikeJerred, Yeees, I used you hack. So, I finded a solution how to publish my package.

https://forum.snapcraft.io/t/snapcraft-review-fails-wrong-permissions-electron-builder/10061

And steps to build "normal" package:

  1. Use your patch for app-builder-lib
  2. Use the solution from the link that I send before.
  3. Upload.

I have no possibility to check it for AppImage (I use only snap in my app).

mkinitcpio avatar Sep 04 '22 09:09 mkinitcpio

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

github-actions[bot] avatar Jan 29 '24 00:01 github-actions[bot]