mzmine / mzmine

mzmine source code repository
https://mzmine.github.io/mzmine_documentation/
MIT License
182 stars 122 forks source link

deb Package error because debian does not support zst #1063

Open fdiversion opened 1 year ago

fdiversion commented 1 year ago

mzmine-linux-installer_3.3.0.deb on Debian 11 gives error because an unknown compression was used (zst). dpkg on ubuntu supports zst, while on debian not. So please use a building script for debian, not ubuntu for compatibility with both.

tomas-pluskal commented 1 year ago

That is interesting. We use the jpackage tool to build the packages (https://docs.oracle.com/en/java/javase/19/docs/specs/man/jpackage.html). There doesn't seem to be any way to choose the type of compression with this tool.

fdiversion commented 1 year ago

It seems to be a longer existing problem in debian stable vs. ubuntu versions.

What I found (it works): The deb can be repacked to be compressed with xz instead of zstd (tested):

ar x mzmine-linux-installer_3.3.0.deb zstd -d < control.tar.zst | xz > control.tar.xz zstd -d < data.tar.zst | xz > data.tar.xz ar -m -c -a sdsd mzmine-linux-installer_3.3.0_repacked.deb debian-binary control.tar.xz data.tar.xz rm debian-binary control.tar.xz data.tar.xz control.tar.zst data.tar.zst

I have no experience with java and jpackage, but the latter must contain some debain packaging code where compression can be selected...

robinschmid commented 1 year ago

So currently, GitHub actions run on ubuntu to automatically build both the debian and ubuntu versions.

Maybe you could research if there are some parameters in jpackage or in GitHub actions unbuntu runner to change the compression. Otherwise it might also be possible just to run your commands and repackage the .deb.

Did you try to install the compression standard on your system?

NassimBtk commented 7 months ago

I faced the same issue when building our .deb distribution using jpackage 21 on the ubuntu-latest runner (ubuntu-22.04). After switching to the ubuntu-20.04 runner (↘️build) the package was built successfully with xz compression. Xz delivers the smallest package size, while zst should provide better compression time. The decision between them depends on the specific usage and deployment needs of the package, considering that zst is incompatible with Debian 11.