Skip to content

Commit

Permalink
Merge pull request #18636 from Homebrew/swift-dylib_id-fix
Browse files Browse the repository at this point in the history
os/mac/keg_relocate: don't change Swift stdlib dylib IDs
  • Loading branch information
Bo98 authored Oct 25, 2024
2 parents bbe5a85 + 529eadd commit d0af2d4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Library/Homebrew/extend/os/mac/keg_relocate.rb
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,9 @@ def each_linkage_for(file, linkage_type, resolve_variable_references: false, &bl
end

def dylib_id_for(file)
# Swift dylib IDs should be /usr/lib/swift
return file.dylib_id if file.dylib_id.start_with?("/usr/lib/swift/libswift")

# The new dylib ID should have the same basename as the old dylib ID, not
# the basename of the file itself.
basename = File.basename(file.dylib_id)
Expand Down

0 comments on commit d0af2d4

Please sign in to comment.