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

Really require everything in buildroot to be packaged #1446

Merged
merged 1 commit into from Nov 23, 2020

Conversation

pmatilai
Copy link
Member

Previously we only checked for unpackaged files and symlinks, completely
ignoring eg extra directories that might be there. Just check for everything
instead. Related to #994.

Directories are a little tricky as some of them are almost always unowned
so we need to allow all path components leading to packaged files.

@pmatilai pmatilai added the bug label Nov 19, 2020
Copy link
Member

@Conan-Kudo Conan-Kudo left a comment

Choose a reason for hiding this comment

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

LGTM.

@Conan-Kudo
Copy link
Member

@pmatilai This means that installed empty directories will get caught now too, right?

@pmatilai
Copy link
Member Author

Yes. That's exactly what the no longer failing testcase does (see the removed XFAIL in the patch)

Previously we only checked for unpackaged files and symlinks, completely
ignoring eg extra directories that might be there. Just check for everything
instead. Related to rpm-software-management#994.

Directories are a little tricky as some of them are almost always unowned
so we need to allow all path components leading to packaged files. This
would be a *lot* of relatively expensive lookups, but we only need to do
the dance when the directory index changes, and we can stop when no new
paths get added to the pool.
@pmatilai
Copy link
Member Author

Realized that we can (and should) optimize this considerably by avoiding redoing the path splitting for files in the same directory, and stopping on a given path when no new strings got added. This reduces the number of lookups for a simple testcase of fedora-release from ~300 to ~20, for large packages like the kernel the initial naive version would likely even show up in wall-clock...

@pmatilai pmatilai merged commit 1110c28 into rpm-software-management:master Nov 23, 2020
@pmatilai pmatilai deleted the checkall-pr branch January 18, 2021 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants