xarchiver icon indicating copy to clipboard operation
xarchiver copied to clipboard

Possible Bug: Busybox compatibility for *.gz

Open Saijin-Naib opened this issue 3 years ago • 2 comments
trafficstars

image

Command: /bin/gzip -l /home/USERNAME/aports/clamtk/src/clamtk-6.14/clamtk.1.gz
/bin/gzip: unrecognized option: l
BusyBox v1.35.0 (2022-04-20 13:37:22 UTC) multi-call binary.

Usage: gzip [-cfkdt123456789] [FILE]...

Compress FILEs (or stdin)

	-1..9	Compression level
	-d	Decompress
	-c	Write to stdout
	-f	Force
	-k	Keep input files
	-t	Test integrity

Saijin-Naib avatar Apr 23 '22 21:04 Saijin-Naib

I am not sure whether to support such programs that have the same name but are not compatible.

This is more likely a busybox issue.

ib avatar Apr 24 '22 08:04 ib

I've filed an issue upstream with Busybox referencing this and the GNU GZip documentation for the -l flag. https://bugs.busybox.net/show_bug.cgi?id=14771

Saijin-Naib avatar Apr 24 '22 15:04 Saijin-Naib

Xarchiver doesn't seem to support gzip 1.5 either

That's not a problem of course, since that version is too old and/or too buggy. I compiled a static gzip 1.12 musl binary to replace the one from Slackware 14.0

I'll take a look at the source code, perhaps it's fixable, but that project is somewhat dead and many patches are ignored... I compiled a static busybox 1.36 with 25 patches from alpine, which add features and fix stuff

wdlkmpx avatar Mar 20 '23 00:03 wdlkmpx

Xarchiver doesn't seem to support gzip 1.5 either

What is not working?

ib avatar Mar 20 '23 09:03 ib

Xarchiver doesn't seem to support gzip 1.5 either

What is not working?

Testing gzip 1.5.. it works as expected now

The problem was that it would display garbled text as the filename and therefore I could not extract the file, Store archiver output was not enabled, so I didn't see what the problem was..

So.. for some reason it seems to work now.. I don't remember if a specific file triggered the problem

One thing to note is that gzip 1.5 doesn't support -k (keep input files)

wdlkmpx avatar Mar 20 '23 15:03 wdlkmpx

This patch for busybox 1.36 adds -l / --list to busybox gzip / gunzip / unxz / lzop / unlzop

busybox_gzip_list_1.36.patch.gz

It's just a hack, it doesn't provide compression info, but it's enough to make the applets work with xarchiver

According to my tests, it just works, although it needs more testing to identify possible side effects?

edit: version is 1.36

wdlkmpx avatar Mar 20 '23 16:03 wdlkmpx

There will be no support for programs that have the same name but are not compatible.

ib avatar Mar 20 '23 19:03 ib

well busybox can be fixed to support xarchiver, it's not hard to add some basic support, the patch above implements it, but it won't find its way to the mailing list

the busybox cpio stuff is also fixable, both in xarchiver and busybox, or a mix of the two, as far as I can tell, probably -- is the main issue when it comes to cmd args

this is certainly not to be discussed here, so it's wise to close it, it will be discussed somewhere someday haha..

wdlkmpx avatar Mar 20 '23 20:03 wdlkmpx