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

Automated builds from tar archives are not working #91

Closed
sharkwouter opened this issue Jun 21, 2023 · 5 comments
Closed

Automated builds from tar archives are not working #91

sharkwouter opened this issue Jun 21, 2023 · 5 comments
Assignees

Comments

@sharkwouter
Copy link
Member

Summary

It turns out that the file command is broken, which is used by the makepkg command. This makes makepkg think that tar.gz files are gzip archives, making it use gzip to extract it. The result is that tar files are not extracted fully, causing failures.

Details

The makepkg command uses the following file command:

file -S -bizL -- "$file"

The file variable is set to the archive name.

Here is an example in what that results in on alpine:

application/x-empty; charset=binary compressed-encoding=application/gzip; charset=binary

On Arch and Debian 12 (which use the same version of file) this results in the following with the same file:

application/x-tar; charset=binary compressed-encoding=application/gzip; charset=binary

This is not fixed on alpine edge.

Possible solutions

At the moment I see the following options:

  • Fix this in alpine
  • Use an older alpine version
  • Patch pacman to just try bsdtar if the archive is seen as empty

I don't think there are many other ways around this one.

@sharkwouter
Copy link
Member Author

@sharkwouter
Copy link
Member Author

sharkwouter commented Jun 21, 2023

There is a fix for it upstream in file, but it is not available in a new release yet: file/file@1dd21dd

I tested this fix and it did not resolve the problem.

@sharkwouter sharkwouter self-assigned this Jun 21, 2023
@sharkwouter
Copy link
Member Author

I made an upstream issue: https://gitlab.alpinelinux.org/alpine/aports/-/issues/15047

@sharkwouter
Copy link
Member Author

This was resolved upstream now in Alpine 3.18. I'll test it out

@sharkwouter
Copy link
Member Author

This has been resolved now thanks to the upstream fix.

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

1 participant