mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-10 07:57:59 -05:00
Ruby => 3.4.1 (#11066)
* Ruby => 3.4.0, and remove old kernel workarounds. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add built packages for linux/386 to ruby * Add built packages for linux/amd64 to ruby * Add built packages for linux/arm/v7 to ruby * dep adjustment for Ruby 3.4 Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add gem adjustment for ruby 3.4. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update ruby gems deps. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust ruby_resolv_replace requirements. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update rubygems package name. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add repl_type_completor package. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update ruby => 3.4.1 Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust build to prevent breakage. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust build workflow script. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add workaround for broken rubocop from ruby upgrade. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Handle case of gem compiler not being installed. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add built packages for linux/386 to ruby * Add built packages for linux/amd64 to ruby * Add built packages for linux/arm/v7 to ruby * Update lib/downloader.rb Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update packages/ruby_repl_type_completor.rb Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update tools/build_updated_packages.rb Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update packages/ruby_repl_type_completor.rb Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update tools/build_updated_packages.rb Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Add broken rake invocation workaround. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update Rubygems. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update gems and fix gem updater to account for rubygems.org/versions appending updates during the month to the bottom of the file. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Sync up logic in buildsystems/ruby.rb and tools/update_ruby_gem_packages.rb Signed-off-by: Satadru Pramanik <satadru@gmail.com> --------- Signed-off-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: satmandu <satmandu@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
8d044a2c73
commit
dce18d8dd9
@@ -62,7 +62,7 @@ def set_vars(passed_name = nil, passed_version = nil)
|
||||
$gems ||= BasicCompactIndexClient.new.gems
|
||||
puts 'Done populating gem information.'.lightgreen
|
||||
end
|
||||
gem_test = $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '')}\\s.*$"}/).first.blank? ? $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '').gsub('_', '-')}\\s.*$"}/).first : $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '')}\\s.*$"}/).first
|
||||
gem_test = $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '')}\\s.*$"}/).last.blank? ? $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '').gsub('_', '-')}\\s.*$"}/).last : $gems.grep(/#{"^#{passed_name.gsub(/^ruby_/, '')}\\s.*$"}/).last
|
||||
gem_test_name = gem_test.split.first
|
||||
gem_test_versions = gem_test.split[1].split(',')
|
||||
# Any version with a letter is considered a prerelease as per
|
||||
@@ -122,6 +122,7 @@ class RUBY < Package
|
||||
|
||||
Kernel.system "gem fetch #{@gem_name} --platform=ruby --version=#{@gem_version}"
|
||||
Kernel.system "gem unpack #{@gem_name}-#{@gem_version}.gem"
|
||||
system 'gem install gem-compiler' unless Kernel.system('gem compile --help 2>/dev/null', %i[out err] => File::NULL)
|
||||
Kernel.system "gem compile --strip --prune #{@gem_name}-#{@gem_version}.gem -O #{CREW_DEST_DIR}/"
|
||||
@just_built_gem = true
|
||||
end
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
require 'etc'
|
||||
|
||||
OLD_CREW_VERSION ||= defined?(CREW_VERSION) ? CREW_VERSION : '1.0'
|
||||
CREW_VERSION ||= '1.56.4' unless defined?(CREW_VERSION) && CREW_VERSION == OLD_CREW_VERSION
|
||||
CREW_VERSION ||= '1.56.5' unless defined?(CREW_VERSION) && CREW_VERSION == OLD_CREW_VERSION
|
||||
|
||||
# Kernel architecture.
|
||||
KERN_ARCH ||= Etc.uname[:machine]
|
||||
|
||||
@@ -29,7 +29,8 @@ require_gem('ptools')
|
||||
|
||||
begin
|
||||
require 'securerandom'
|
||||
require 'resolv-replace'
|
||||
# resolv-replace is no longer needed with ruby 3.4
|
||||
require 'resolv-replace' if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('3.4.0')
|
||||
require 'net/http'
|
||||
rescue RuntimeError => e
|
||||
# hide the error message and fallback to curl if securerandom raise an error
|
||||
|
||||
Reference in New Issue
Block a user