Upgrade to Ruby 3.3.1.

Resolves: rhbz#2276680
This commit is contained in:
Vít Ondruch 2024-04-23 17:48:45 +02:00
commit 85d18e8bd3
12 changed files with 73 additions and 581 deletions

View file

@ -1,6 +1,6 @@
%global major_version 3
%global minor_version 3
%global teeny_version 0
%global teeny_version 1
%global major_minor_version %{major_version}.%{minor_version}
%global ruby_version %{major_minor_version}.%{teeny_version}
@ -27,7 +27,7 @@
%global rubygems_dir %{_datadir}/rubygems
# Bundled libraries versions
%global rubygems_version 3.5.3
%global rubygems_version 3.5.9
%global rubygems_molinillo_version 0.8.0
%global rubygems_net_http_version 0.4.0
%global rubygems_net_protocol_version 0.2.2
@ -35,9 +35,10 @@
%global rubygems_resolv_version 0.3.0
%global rubygems_timeout_version 0.4.1
%global rubygems_tsort_version 0.2.0
%global rubygems_uri_version 0.13.0
# Default gems.
%global bundler_version 2.5.3
%global bundler_version 2.5.9
%global bundler_connection_pool_version 2.4.1
%global bundler_fileutils_version 1.7.2
%global bundler_net_http_persistent_version 4.0.2
@ -71,7 +72,7 @@
%global ipaddr_version 1.2.6
%global logger_version 1.6.0
%global mutex_m_version 0.2.0
%global net_http_version 0.4.0
%global net_http_version 0.4.1
%global net_protocol_version 0.2.2
%global nkf_version 0.1.3
%global observer_version 0.1.2
@ -117,14 +118,14 @@
%global irb_version 1.11.0
%global json_version 2.7.1
%global psych_version 5.1.2
%global rdoc_version 6.6.2
%global rdoc_version 6.6.3.1
# Bundled gems.
%global debug_version 1.9.1
%global net_ftp_version 0.3.3
%global net_imap_version 0.4.9
%global net_ftp_version 0.3.4
%global net_imap_version 0.4.9.1
%global net_pop_version 0.1.2
%global net_smtp_version 0.4.0
%global net_smtp_version 0.4.0.1
%global matrix_version 0.4.2
%global minitest_version 5.20.0
%global power_assert_version 2.0.3
@ -170,7 +171,7 @@
Summary: An interpreter of object-oriented scripting language
Name: ruby
Version: %{ruby_version}%{?development_release}
Release: 6%{?dist}
Release: 7%{?dist}
# Licenses, which are likely not included in binary RPMs:
# Apache-2.0:
# benchmark/gc/redblack.rb
@ -273,26 +274,13 @@ Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch
# Revert patches causing segfaults in alexandria package.
# https://bugs.ruby-lang.org/issues/20079
Patch10: ruby-3.3.0-Revert-Optimize-allocations-in-Hash-compare_by_identity.patch
# Fix net-http test errors due to expired certificate
# https://github.com/ruby/ruby/commit/d3933fc753187a055a4904af82f5f3794c88c416
# https://bugs.ruby-lang.org/issues/20106
Patch11: ruby-3.4.0-ruby-net-http-Renew-test-certificates.patch
# Armv8.3+ capable CPUs might segfault with incorrect compilation options.
# See related upstream report: https://bugs.ruby-lang.org/issues/20085
# https://bugs.ruby-lang.org/issues/20154
Patch12: ruby-3.4.0-fix-branch-protection-compilation-for-arm.patch
# Revert adding AI_ADDRCONFIG flag to getaddrinfo(3) calls.
# It is causing problems when network is in certain, valid, configuration.
# When loopback interface is IPv6 capable, but no regular network interface
# is IPv6 capable, in some situations (such as in TestNetHTTPLocalBind)
# this might result in creating IPv4 socket and then binding it
# to IPv6 family connection.
# That is incorrect behavior and such operation will result in
# Errno::EAFNOSUPPORT exception.
# The point of the upstream change is to workaround a glibc bug
# that is not present for us. Therefore we can safely revert the change.
# https://bugs.ruby-lang.org/issues/20208
Patch13: ruby-3.4.0-Revert-Set-AI_ADDRCONFIG-when-making-getaddrinfo.patch
# Fix build issue on i686 due to "incompatible pointer type" error.
# https://bugs.ruby-lang.org/issues/20447
Patch13: ruby-3.4.0-Fix-pointer-incompatiblity.patch
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%{?with_rubypick:Suggests: rubypick}
@ -770,7 +758,6 @@ analysis result in RBS format, a standard type description format for Ruby
%patch 6 -p1
%patch 9 -p1
%patch 10 -p1
%patch 11 -p1
%patch 12 -p1
%patch 13 -p1
@ -987,16 +974,16 @@ checksec --file=%{_vpath_builddir}/libruby.so.%{ruby_version} | \
# Molinillo.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; module Resolver; end; end; \
require 'rubygems/resolver/molinillo/lib/molinillo/gem_metadata'; \
require 'rubygems/vendor/molinillo/lib/molinillo/gem_metadata'; \
puts '%%{rubygems_molinillo_version}: %{rubygems_molinillo_version}'; \
puts %Q[Gem::Resolver::Molinillo::VERSION: #{Gem::Resolver::Molinillo::VERSION}]; \
exit 1 if Gem::Resolver::Molinillo::VERSION != '%{rubygems_molinillo_version}'; \
puts %Q[Gem::Molinillo::VERSION: #{Gem::Molinillo::VERSION}]; \
exit 1 if Gem::Molinillo::VERSION != '%{rubygems_molinillo_version}'; \
\""
# Net::HTTP.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; module Net; end; end; \
require 'rubygems/net-http/lib/net/http'; \
require 'rubygems/vendor/net-http/lib/net/http'; \
puts '%%{rubygems_net_http_version}: %{rubygems_net_http_version}'; \
puts %Q[Gem::Net::HTTP::VERSION: #{Gem::Net::HTTP::VERSION}]; \
exit 1 if Gem::Net::HTTP::VERSION != '%{rubygems_net_http_version}'; \
@ -1005,7 +992,7 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
# Net::Protocol.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; module Net; end; end; \
require 'rubygems/net-protocol/lib/net/protocol'; \
require 'rubygems/vendor/net-protocol/lib/net/protocol'; \
puts '%%{rubygems_net_protocol_version}: %{rubygems_net_protocol_version}'; \
puts %Q[Gem::Net::Protocol::VERSION: #{Gem::Net::Protocol::VERSION}]; \
exit 1 if Gem::Net::Protocol::VERSION != '%{rubygems_net_protocol_version}'; \
@ -1014,7 +1001,7 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
# OptParse.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; end; \
require 'rubygems/optparse/lib/optparse'; \
require 'rubygems/vendor/optparse/lib/optparse'; \
puts '%%{rubygems_optparse_version}: %{rubygems_optparse_version}'; \
puts %Q[Gem::OptionParser::Version: #{Gem::OptionParser::Version}]; \
exit 1 if Gem::OptionParser::Version != '%{rubygems_optparse_version}'; \
@ -1023,7 +1010,7 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
# Resolv.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; end; \
require 'rubygems/resolv/lib/resolv'; \
require 'rubygems/vendor/resolv/lib/resolv'; \
puts '%%{rubygems_resolv_version}: %{rubygems_resolv_version}'; \
puts %Q[Gem::Resolv::VERSION: #{Gem::Resolv::VERSION}]; \
exit 1 if Gem::Resolv::VERSION != '%{rubygems_resolv_version}'; \
@ -1032,7 +1019,7 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
# Timeout.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; end; \
require 'rubygems/timeout/lib/timeout'; \
require 'rubygems/vendor/timeout/lib/timeout'; \
puts '%%{rubygems_timeout_version}: %{rubygems_timeout_version}'; \
puts %Q[Gem::Timeout::VERSION: #{Gem::Timeout::VERSION}]; \
exit 1 if Gem::Timeout::VERSION != '%{rubygems_timeout_version}'; \
@ -1041,12 +1028,21 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
# TSort
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; end; \
require 'rubygems/tsort/lib/tsort'; \
require 'rubygems/vendor/tsort/lib/tsort'; \
puts '%%{rubygems_tsort_version}: %{rubygems_tsort_version}'; \
puts %Q[Gem::TSort::VERSION: #{Gem::TSort::VERSION}]; \
exit 1 if Gem::TSort::VERSION != '%{rubygems_tsort_version}'; \
\""
# URI.
make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \
module Gem; end; \
require 'rubygems/vendor/uri/lib/uri/version'; \
puts '%%{rubygems_uri_version}: %{rubygems_uri_version}'; \
puts %Q[Gem::URI::VERSION: #{Gem::URI::VERSION}]; \
exit 1 if Gem::URI::VERSION != '%{rubygems_uri_version}'; \
\""
# Check Bundler bundled dependencies versions.
# connection_pool.
@ -1718,6 +1714,10 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \
%changelog
* Tue Apr 23 2024 Vít Ondruch <vondruch@redhat.com> - 3.3.1-7
- Upgrade to Ruby 3.3.1.
Resolves: rhbz#2276680
* Fri Apr 12 2024 Vít Ondruch <vondruch@redhat.com> - 3.3.0-6
- Add `bundled` provide for NKF.
- License review and fixes of SPDX syntax.