Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Busybox: tar error when installing JuNest #340

Open
TeddyCuoreDolce opened this issue Dec 24, 2023 · 4 comments
Open

Busybox: tar error when installing JuNest #340

TeddyCuoreDolce opened this issue Dec 24, 2023 · 4 comments

Comments

@TeddyCuoreDolce
Copy link

I'm facing some tar related issue

# junest setup
Downloading JuNest...
[...]
Installing JuNest...
tar: invalid option -- 'z'
BusyBox v1.35.0 (2023-03-05 21:13:04 Europe) multi-call binary.

Usage: tar c|x|t [-ahvokO] [-f TARFILE] [-C DIR] [-T FILE] [-X FILE] [LONGOPT]... [FILE]...

Create, extract, or list files from a tar file

	c	Create
	x	Extract
	t	List
	-f FILE	Name of TARFILE ('-' for stdin/out)
	-C DIR	Change to DIR before operation
	-v	Verbose
	-O	Extract to stdout
	-o	Don't restore user:group
	-k	Don't replace existing files
	-a	(De)compress based on extension
	-h	Follow symlinks
	-T FILE	File with names to include
	-X FILE	File with glob patterns to exclude
	--exclude PATTERN	Glob pattern to exclude
	--overwrite		Replace existing files
	--strip-components NUM	NUM of leading components to strip
	--no-recursion		Don't descend in directories
	--numeric-owner		Use numeric user:group
	--no-same-permissions	Don't restore access permissions
	--to-command COMMAND	Pipe files to COMMAND
Error occurred when installing JuNest

So looks like my tar is missing the z option which you're using to extract a .tar.gz
One workaround would be to replace the -z with an equivalent gzip command, which is available to me.
Is it an option to try that in case straight tar fails?

@fsquillace
Copy link
Owner

Hi,

can you check whether gzip is installed in busy box? an alternative could be to run gzip and then tar commands. This would be more generic approach, I guess.

Also, does junest runs well in busybox can you try it?

@TeddyCuoreDolce
Copy link
Author

I'm trying to install JuNest on a Batocera machine. It was a method recommended in this reddit post I made about adding packages.

Not sure why, but others seem to have the -z option, while for some reason mine does not seem to.

gzip is available though with the following options

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

Compress FILEs (or stdin)

	-d	Decompress
	-c	Write to stdout
	-f	Force
	-k	Keep input files
	-t	Test integrity

and BusyBox is v1.35.0, but I can't confirm JuNest works well until I complete the install

@fsquillace
Copy link
Owner

fsquillace commented Dec 26, 2023

I will change the script to include gzip command. In the meantime you can try it by changing this line here: https://github.com/fsquillace/junest/blob/master/lib/core/setup.sh#L55

@fsquillace
Copy link
Owner

Given I do not have busybox, can you try modify that line and tell what is the working commands? Also, I am afraid that constructing general commands might be hard given that tar in busybox accepts a x to extract file whereas in other linux systems is -x.

@fsquillace fsquillace changed the title tar error when installing JuNest Busybox: tar error when installing JuNest Dec 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants