brew vendor-gems: commit updates.

This commit is contained in:
BrewTestBot 2024-04-24 15:24:41 +00:00
parent ade22ccdb9
commit 5e43456282
No known key found for this signature in database
GPG Key ID: 82D7D104050B0F0F
12 changed files with 10 additions and 8 deletions

View File

@ -158,6 +158,7 @@ GEM
PLATFORMS
aarch64-linux
arm-linux
arm64-darwin
x86_64-darwin
x86_64-linux

View File

@ -65,7 +65,7 @@ $:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/rainbow-3.1.1/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/sorbet-runtime-0.5.11353/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/parlour-8.1.0/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/patchelf-1.5.0/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/patchelf-1.5.1/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/plist-3.7.1/lib")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/extensions/arm64-darwin-20/#{Gem.extension_api_version}/prism-0.24.0")
$:.unshift File.expand_path("#{__dir__}/../#{RUBY_ENGINE}/#{Gem.ruby_api_version}/gems/prism-0.24.0/lib")

View File

@ -451,10 +451,10 @@ module PatchELF
begin
new_index = new_section_idx(old_shndx)
next unless new_index
rescue ArgumentError
Logger.warn "entry #{entry} in symbol table refers to a non existing section, skipping"
end
next unless new_index
sym[pack[:st_shndx]] = new_index
@ -561,11 +561,12 @@ module PatchELF
if needed_space > start_offset
needed_space += seg_num_bytes # new load segment is required
needed_pages = Helper.alignup(needed_space - start_offset, page_size) / page_size
extra_bytes = needed_space - start_offset
needed_pages = Helper.alignup(extra_bytes, page_size) / page_size
Logger.debug "needed pages is #{needed_pages}"
raise PatchError, 'virtual address space underrun' if needed_pages * page_size > first_page
shift_file(needed_pages, start_offset)
shift_file(needed_pages, start_offset, extra_bytes)
first_page -= needed_pages * page_size
start_offset += needed_pages * page_size
@ -776,7 +777,7 @@ module PatchELF
end
# rubocop:enable Metrics/PerceivedComplexity
def shift_file(extra_pages, start_offset)
def shift_file(extra_pages, start_offset, extra_bytes)
raise PatchError, "start_offset(#{start_offset}) < ehdr.num_bytes" if start_offset < ehdr.num_bytes
oldsz = @buffer.size
@ -799,8 +800,8 @@ module PatchELF
p_offset: split_phdr.p_offset - split_shift - shift,
p_vaddr: split_phdr.p_vaddr - split_shift - shift,
p_paddr: split_phdr.p_paddr - split_shift - shift,
p_filesz: split_shift + shift,
p_memsz: split_shift + shift,
p_filesz: split_shift + extra_bytes,
p_memsz: split_shift + extra_bytes,
p_flags: ELFTools::Constants::PF_R | ELFTools::Constants::PF_W,
p_align: page_size
)

View File

@ -2,5 +2,5 @@
module PatchELF
# Current gem version.
VERSION = '1.5.0'.freeze
VERSION = '1.5.1'.freeze
end