-
-
Notifications
You must be signed in to change notification settings - Fork 9.9k
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
Make bottle relocation more specific #11302
Comments
Is this just to protect against cases where one of the relocation path regexes matches in the middle of a path or are there more cases that need fixing? If so, can we just add brew/Library/Homebrew/keg_relocate.rb Lines 39 to 52 in eae3558
|
Yes, I think so for now.
Probably but: we don't know what they are yet 😁
Something like that makes sense to me. I'm not sure I fully understand what |
Good point. it don't think it will match /[^a-z]?#{HOMEBREW_PREFIX}/ |
It's worth noting e.g. https://github.com/Homebrew/homebrew-core/blob/a32f8fd08629a24537a01af1e57556007a5fbc29/Formula/fontconfig.rb#L23-L28 (and similar cases in other formulae) Arguably any/all of these are a sign that the bottle relocation logic needs fixed. |
Now that #11332 has been merged, I've opened Homebrew/homebrew-core#77187 and Homebrew/homebrew-core#77188 to remove the There are still 20 other formulae in homebrew/core that have
First of all, is there really a difference between 3 and 4? I think 4 gives better messaging so it should probably be used consistently (see my suggestion below). Second, for number 5, should these be enclosed in I don't think we can really avoid the CLT requirement but I wonder if we should add a shortcut to require the CLT because it seems that the same Maybe one of these could be a shortcut (obviously allowing existing pour_bottle? :require_clt
pour_bottle? :if_clt_installed
pour_bottle? if: :clt_installed |
I'd been contemplating making |
🎉
😭 but thanks for checking
Agreed!
I like this! Maybe |
I'd like (eventually) to get to a point where |
Okay, here's an update on Looking at the contents of the There are also references to |
I like these. No real preference from me; I think they're both very clear. I'll spend some time soon working on this |
Correct!
We should probably rewrite these so it works when unlinked.
Yes, that would make sense to do I think 👍🏻. Should be relatively easy to look at bottle time whether it's a symlink into a cellar and, if so, replace it with a |
Closing this as considering it mostly done. |
Provide a detailed description of the proposed feature
Don't rewrite paths such as e.g.
$foo/build/usr/local/bin
. For example, seeobjc-run
: https://github.com/iljaiwas/objc-run/blob/55f257300154201a40f3631b06d8131dfe47a5a2/objc-run#L110See discussion in Homebrew/homebrew-core#75943 (comment)
This would require changing at least
replace_text_in_files
(brew/Library/Homebrew/keg_relocate.rb
Line 69 in eae3558
each_unique_file_matching
(brew/Library/Homebrew/keg_relocate.rb
Line 112 in eae3558
keg_relocate.rb
.What is the motivation for the feature?
Improve the number of bottles that are relocated and
all:
.How will the feature be relevant to at least 90% of Homebrew users?
Reduce the need to redownload bottles.
What alternatives to the feature have been considered?
The status quo.
The text was updated successfully, but these errors were encountered: