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

Fix unpacking of tarfiles with softlinks to subdirectories #1382

Merged
merged 5 commits into from
May 31, 2023

Conversation

mosteo
Copy link
Member

@mosteo mosteo commented May 23, 2023

Without this is impossible to install e.g. gcc 13.

mosteo added 5 commits May 20, 2023 22:47
Remains: GC.VFS.Remove_Dir fails because of the same reason, probably.
Otherwise, depending on the links' targets, both Ada.Directories and
GNATCOLL.VFS had trouble with fully deleting a tree containing such links.
@mosteo mosteo marked this pull request as ready for review May 23, 2023 19:12
@mosteo mosteo requested a review from Fabien-Chouteau May 31, 2023 08:09
Copy link
Member

@Fabien-Chouteau Fabien-Chouteau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

How is this related to GCC 13?

@mosteo
Copy link
Member Author

mosteo commented May 31, 2023

How is this related to GCC 13?

The tarfile for gcc13 that I've been using (the one from Maxim IIRC) contains a softlink from a parent directory to a child one, something like:

parent/bits --> parent/x86_64/bits
parent/x86_64/bits

And our current tree remover is unable to remove that. Also, the contents of "parent/bits" are visited without "parent/bits" itself being ever visited (because it's a softlink), and that confuses the copy process.

It's a safeguard in our side, but the ideal situation would be that no softlinks existed in the tarfile.

@mosteo mosteo merged commit 9cac98b into alire-project:master May 31, 2023
@mosteo mosteo deleted the fix/install branch May 31, 2023 15:52
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

Successfully merging this pull request may close these issues.

2 participants