keg_relocate: split relocate_install_names and relocate_text_files
For bottle with `:any_skip_relocation`, relocating text files is required.
This commit is contained in:
parent
7ce0a2dedb
commit
d911b5689a
@ -169,6 +169,8 @@ module Homebrew
|
||||
begin
|
||||
keg.relocate_install_names prefix, Keg::PREFIX_PLACEHOLDER,
|
||||
cellar, Keg::CELLAR_PLACEHOLDER, :keg_only => f.keg_only?
|
||||
keg.relocate_text_files prefix, Keg::PREFIX_PLACEHOLDER,
|
||||
cellar, Keg::CELLAR_PLACEHOLDER
|
||||
keg.delete_pyc_files!
|
||||
|
||||
cd cellar do
|
||||
|
||||
@ -708,6 +708,8 @@ class FormulaInstaller
|
||||
keg.relocate_install_names Keg::PREFIX_PLACEHOLDER, HOMEBREW_PREFIX.to_s,
|
||||
Keg::CELLAR_PLACEHOLDER, HOMEBREW_CELLAR.to_s, :keg_only => formula.keg_only?
|
||||
end
|
||||
keg.relocate_text_files Keg::PREFIX_PLACEHOLDER, HOMEBREW_PREFIX.to_s,
|
||||
Keg::CELLAR_PLACEHOLDER, HOMEBREW_CELLAR.to_s
|
||||
|
||||
Pathname.glob("#{formula.bottle_prefix}/{etc,var}/**/*") do |path|
|
||||
path.extend(InstallRenamed)
|
||||
|
||||
@ -46,7 +46,9 @@ class Keg
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def relocate_text_files(old_prefix, new_prefix, old_cellar, new_cellar)
|
||||
files = text_files | libtool_files
|
||||
|
||||
files.group_by { |f| f.stat.ino }.each_value do |first, *rest|
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user