-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
vendor: Update ruby-macho to 0.2.6. #1469
vendor: Update ruby-macho to 0.2.6. #1469
Conversation
As #1460 was reverted could you add its changes to this PR too? Thanks! |
48bb65f
to
df8176f
Compare
This brings fixes for behavior expected in Homebrew#1460.
…lib type. This allows us to filter out weak linkages during audits, preventing a false error from occurring when the dylib cannot be found.
Prevents namespace conflict with vendored ruby-macho.
df8176f
to
9267511
Compare
Thanks again @woodruffw! |
def dynamically_linked_libraries(except: :none) | ||
lcs = macho.dylib_load_commands.reject { |lc| lc.type == except } | ||
|
||
lcs.map(&:name).map(&:to_s) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lcs.map(&:name).map(&:to_s)
should be lcs.map(&:name).map(&:to_s).uniq
otherwise universal libraries show up twice. This then triggers a failure to bottle universal binaries & libraries, like my wine PR (Homebrew/homebrew-core#10532 ; test results: https://bot.brew.sh/job/Homebrew%20Core/17442/version=sierra/testReport/junit/brew-test-bot/sierra/bottle_wine/)
Before the commit, this code relied on macho.linked_dylibs
, which does apply uniq
:
def linked_dylibs
# Individual architectures in a fat binary can link to different subsets
# of libraries, but at this point we want to have the full picture, i.e.
# the union of all libraries used by all architectures.
machos.map(&:linked_dylibs).flatten.uniq
end
brew tests
with your changes locally?This brings fixes for behavior expected in #1460.
cc @MikeMcQuaid, @UniqMartin