From 28e9e680e62ee7b08b5ac5eb6e70073cb42b1b9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 24 Oct 2024 14:43:02 +0200 Subject: [PATCH 01/18] Upgrade to Ruby 3.4.0 (3da3cabf98) --- ...0-Enable-configuration-of-archlibdir.patch | 2 +- ...ed-paths-when-empty-version-string-i.patch | 4 +- ruby-2.1.0-always-use-i386.patch | 2 +- ruby-2.1.0-custom-rubygems-location.patch | 8 +- ruby-2.3.0-ruby_version.patch | 10 +- ruby-2.7.0-Initialize-ABRT-hook.patch | 6 +- ...3.0-Disable-syntax-suggest-test-case.patch | 6 +- ...GS-to-a-special-hardenflags-variable.patch | 302 --------------- ...nssl-respect-crypto-policies-tls-min.patch | 47 --- ruby.spec | 343 +++++++++++------- 10 files changed, 240 insertions(+), 490 deletions(-) delete mode 100644 ruby-3.4.0-Extract-hardening-CFLAGS-to-a-special-hardenflags-variable.patch delete mode 100644 ruby-3.4.0-openssl-respect-crypto-policies-tls-min.patch diff --git a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch index 4cd8dd1..b7b2bf2 100644 --- a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch +++ b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index d261ea57b5..3c13076b82 100644 --- a/configure.ac +++ b/configure.ac -@@ -3482,6 +3482,11 @@ AS_IF([test ${multiarch+set}], [ +@@ -3538,6 +3538,11 @@ AS_IF([test ${multiarch+set}], [ ]) archlibdir='${libdir}/${arch}' diff --git a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index e6315c0..36c343c 100644 --- a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -14,7 +14,7 @@ diff --git a/configure.ac b/configure.ac index c42436c23d..d261ea57b5 100644 --- a/configure.ac +++ b/configure.ac -@@ -4321,7 +4321,8 @@ AS_CASE(["$ruby_version_dir_name"], +@@ -4382,7 +4382,8 @@ AS_CASE(["$ruby_version_dir_name"], ruby_version_dir=/'${ruby_version_dir_name}' if test -z "${ruby_version_dir_name}"; then @@ -66,7 +66,7 @@ diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb index 07076d4..35e6c3c 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb -@@ -115,7 +115,7 @@ +@@ -116,7 +116,7 @@ val = val.gsub(/\$(?:\$|\{?(\w+)\}?)/) {$1 ? "$(#{$1})" : $&}.dump case name when /^prefix$/ diff --git a/ruby-2.1.0-always-use-i386.patch b/ruby-2.1.0-always-use-i386.patch index 8e1b4fe..30188f4 100644 --- a/ruby-2.1.0-always-use-i386.patch +++ b/ruby-2.1.0-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index 3c13076b82..93af30321d 100644 --- a/configure.ac +++ b/configure.ac -@@ -4385,6 +4385,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -4446,6 +4446,8 @@ AC_SUBST(vendorarchdir)dnl AC_SUBST(CONFIGURE, "`echo $0 | sed 's|.*/||'`")dnl AC_SUBST(configure_args, "`echo "${ac_configure_args}" | sed 's/\\$/$$/g'`")dnl diff --git a/ruby-2.1.0-custom-rubygems-location.patch b/ruby-2.1.0-custom-rubygems-location.patch index 7dc8eca..2ef7b5d 100644 --- a/ruby-2.1.0-custom-rubygems-location.patch +++ b/ruby-2.1.0-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.ac b/configure.ac index 93af30321d..bc13397e0e 100644 --- a/configure.ac +++ b/configure.ac -@@ -4357,6 +4357,10 @@ AC_ARG_WITH(vendorarchdir, +@@ -4418,6 +4418,10 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], [vendorarchdir=${multiarch+'${rubysitearchprefix}/vendor_ruby'${ruby_version_dir}}${multiarch-'${vendorlibdir}/${sitearch}'}]) @@ -26,7 +26,7 @@ index 93af30321d..bc13397e0e 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX='' -@@ -4381,6 +4385,7 @@ AC_SUBST(sitearchdir)dnl +@@ -4442,6 +4446,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl @@ -67,7 +67,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index e9110a17ca..76a1f0a315 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -359,6 +359,7 @@ def CONFIG.[](name, mandatory = false) +@@ -386,6 +386,7 @@ def CONFIG.[](name, mandatory = false) vendorlibdir = CONFIG["vendorlibdir"] vendorarchlibdir = CONFIG["vendorarchdir"] end @@ -75,7 +75,7 @@ index e9110a17ca..76a1f0a315 100755 mandir = CONFIG["mandir", true] docdir = CONFIG["docdir", true] enable_shared = CONFIG["ENABLE_SHARED"] == 'yes' -@@ -595,7 +596,16 @@ def stub +@@ -978,7 +979,16 @@ def (bins = []).add(name) install?(:local, :comm, :lib) do prepare "library scripts", rubylibdir noinst = %w[*.txt *.rdoc *.gemspec] diff --git a/ruby-2.3.0-ruby_version.patch b/ruby-2.3.0-ruby_version.patch index 68782cd..58c023b 100644 --- a/ruby-2.3.0-ruby_version.patch +++ b/ruby-2.3.0-ruby_version.patch @@ -20,7 +20,7 @@ diff --git a/configure.ac b/configure.ac index 80b137e380..63cd3b4f8b 100644 --- a/configure.ac +++ b/configure.ac -@@ -4271,9 +4271,6 @@ AS_CASE(["$target_os"], +@@ -4332,9 +4332,6 @@ AS_CASE(["$target_os"], rubyw_install_name='$(RUBYW_INSTALL_NAME)' ]) @@ -30,7 +30,7 @@ index 80b137e380..63cd3b4f8b 100644 rubyarchprefix=${multiarch+'${archlibdir}/${RUBY_BASE_NAME}'}${multiarch-'${rubylibprefix}/${arch}'} AC_ARG_WITH(rubyarchprefix, AS_HELP_STRING([--with-rubyarchprefix=DIR], -@@ -4296,57 +4293,63 @@ AC_ARG_WITH(ridir, +@@ -4357,57 +4354,63 @@ AC_ARG_WITH(ridir, AC_SUBST(ridir) AC_SUBST(RI_BASE_NAME) @@ -122,7 +122,7 @@ index 80b137e380..63cd3b4f8b 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) -@@ -4363,6 +4366,7 @@ AC_SUBST(sitearchincludedir)dnl +@@ -4424,6 +4427,7 @@ AC_SUBST(sitearchincludedir)dnl AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl @@ -171,7 +171,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index d4c110e..d39c9a6 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -453,7 +453,7 @@ def CONFIG.[](name, mandatory = false) +@@ -949,7 +949,7 @@ def (bins = []).add(name) install?(:doc, :rdoc) do if $rdocdir @@ -262,7 +262,7 @@ diff --git a/configure.ac b/configure.ac index a00f2b6776..999e2d6d5d 100644 --- a/configure.ac +++ b/configure.ac -@@ -136,7 +136,7 @@ RUBY_BASE_NAME=`echo ruby | sed "$program_transform_name"` +@@ -142,7 +142,7 @@ RUBY_BASE_NAME=`echo ruby | sed "$program_transform_name"` RUBYW_BASE_NAME=`echo rubyw | sed "$program_transform_name"` AC_SUBST(RUBY_BASE_NAME) AC_SUBST(RUBYW_BASE_NAME) diff --git a/ruby-2.7.0-Initialize-ABRT-hook.patch b/ruby-2.7.0-Initialize-ABRT-hook.patch index 0f32243..0be60f1 100644 --- a/ruby-2.7.0-Initialize-ABRT-hook.patch +++ b/ruby-2.7.0-Initialize-ABRT-hook.patch @@ -44,7 +44,7 @@ diff --git a/common.mk b/common.mk index b2e5b2b6d0..f39f81da5c 100644 --- a/common.mk +++ b/common.mk -@@ -111,7 +111,8 @@ PRISM_FILES = prism/api_node.$(OBJEXT) \ +@@ -110,7 +110,8 @@ PRISM_FILES = prism/api_node.$(OBJEXT) \ prism/prism.$(OBJEXT) \ prism_init.$(OBJEXT) @@ -58,7 +58,7 @@ diff --git a/ruby.c b/ruby.c index 60c57d6259..1eec16f2c8 100644 --- a/ruby.c +++ b/ruby.c -@@ -1724,10 +1724,14 @@ proc_options(long argc, char **argv, ruby_cmdline_options_t *opt, int envopt) +@@ -1740,10 +1740,14 @@ proc_options(long argc, char **argv, ruby_cmdline_options_t *opt, int envopt) void Init_builtin_features(void); @@ -84,5 +84,5 @@ index 60c57d6259..1eec16f2c8 100644 + # Ignore ABRT + features -= %w[abrt] # Ignore CRuby internals - features -= %w[encdb transdb windows_1252] + features -= %w[encdb transdb windows_1252 windows_31j] features.reject! { |feature| feature.end_with?('-fake') } diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index 1119a59..e9c0fbb 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,9 +12,9 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1601,8 +1601,6 @@ yes-test-syntax-suggest: $(PREPARE_SYNTAX_SUGGEST) - $(ACTIONS_ENDGROUP) - no-test-syntax-suggest: +@@ -1616,8 +1616,6 @@ no-test-bundled-gems-spec: + + test-syntax-suggest: -check: $(DOT_WAIT) $(PREPARE_SYNTAX_SUGGEST) test-syntax-suggest - diff --git a/ruby-3.4.0-Extract-hardening-CFLAGS-to-a-special-hardenflags-variable.patch b/ruby-3.4.0-Extract-hardening-CFLAGS-to-a-special-hardenflags-variable.patch deleted file mode 100644 index d0c10a0..0000000 --- a/ruby-3.4.0-Extract-hardening-CFLAGS-to-a-special-hardenflags-variable.patch +++ /dev/null @@ -1,302 +0,0 @@ -From 3d405634f43d39079ee93cdc59ed7fc0a5e8917a Mon Sep 17 00:00:00 2001 -From: KJ Tsanaktsidis -Date: Sun, 9 Jun 2024 21:15:39 +1000 -Subject: [PATCH] Extract hardening CFLAGS to a special $hardenflags variable - -This changes the automatic detection of -fstack-protector, --D_FORTIFY_SOURCE, and -mbranch-protection to write to $hardenflags -instead of $XCFLAGS. The definition of $cflags is changed to -"$hardenflags $orig_cflags $optflags $debugflags $warnflags" to match. - -Furthermore, these flags are _prepended_ to $hardenflags, rather than -appended. - -The implications of doing this are as follows: - -* If a CRuby builder specifies cflags="-mbranch-protection=foobar" at - the ./configure script, and the configure script detects that - -mbranch-protection=pac-ret is accepted, then GCC will be invoked as - "gcc -mbranch-protection=pac-ret -mbranch-protection=foobar". Since - the last flags take precedence, that means that user-supplied values - of these flags in $cflags will take priority. -* Likewise, if a CRuby builder explicitly specifies - "hardenflags=-mbranch-protection=foobar", because we _prepend_ to - $hardenflags in our autoconf script, we will still invoke GCC as - "gcc -mbranch-protection=pac-ret -mbranch-protection=foobar". -* If a CRuby builder specifies CFLAGS="..." at the configure line, - automatic detection of hardening flags is ignored as before. -* C extensions will _also_ be built with hardening flags now as well - (this was not the case by default before because the detected flags - went into $XCFLAGS). - -Additionally, as part of this work, I changed how the detection of -PAC/BTI in Context.S works. Rather than appending the autodetected -option to ASFLAGS, we simply compile a set of test programs with the -actual CFLAGS in use to determine what PAC/BTI settings were actually -chosen by the builder. Context.S is made aware of these choices through -some custom macros. - -The result of this work is that: - -* Ruby will continue to choose some sensible defaults for hardening - options for the C compiler -* Distributors are able to specify CFLAGS that are consistent with their - distribution and override these defaults -* Context.S will react to whatever -mbranch-protection is actually in - use, not what was autodetected -* Extensions get built with hardening flags too. - -[Bug #20154] -[Bug #20520] ---- - configure.ac | 81 ++++++++++++++++++++++++++++++----- - coroutine/arm64/Context.S | 14 +++--- - template/Makefile.in | 1 + - tool/m4/ruby_append_option.m4 | 4 ++ - tool/m4/ruby_try_cflags.m4 | 17 ++++++++ - 5 files changed, 100 insertions(+), 17 deletions(-) - -diff --git a/configure.ac b/configure.ac -index f35fad6a362611..0da15772d36671 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -354,7 +354,7 @@ test -z "$warnflags" || - AS_IF([test -z "${CFLAGS+set}"], [ - cflags=`echo " $cflags " | sed "$cflagspat;s/^ *//;s/ *$//"` - orig_cflags="$cflags" -- cflags="$cflags "'${optflags} ${debugflags} ${warnflags}' -+ cflags='${hardenflags} '"$cflags "'${optflags} ${debugflags} ${warnflags}' - ]) - dnl AS_IF([test -z "${CXXFLAGS+set}"], [ - dnl cxxflags=`echo " $cxxflags " | sed "$cflagspat;s/^ *//;s/ *$//"` -@@ -802,7 +802,7 @@ AS_IF([test "$GCC" = yes], [ - [fortify_source=$enableval]) - AS_IF([test "x$fortify_source" != xno], [ - RUBY_TRY_CFLAGS([$optflags -D_FORTIFY_SOURCE=2], -- [RUBY_APPEND_OPTION(XCFLAGS, -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2)], [], -+ [RUBY_PREPEND_OPTION(hardenflags, -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2)], [], - [@%:@include ]) - ]) - -@@ -823,20 +823,24 @@ AS_IF([test "$GCC" = yes], [ - AC_MSG_CHECKING([for -fstack-protector]) - AC_MSG_RESULT(["$stack_protector"]) - AS_CASE(["$stack_protector"], [-*], [ -- RUBY_APPEND_OPTION(XCFLAGS, $stack_protector) -- RUBY_APPEND_OPTION(XLDFLAGS, $stack_protector) -- RUBY_APPEND_OPTION(LDFLAGS, $stack_protector) -+ RUBY_PREPEND_OPTION(hardenflags, $stack_protector) -+ RUBY_APPEND_OPTION(XLDFLAGS, $stack_protector) -+ RUBY_APPEND_OPTION(LDFLAGS, $stack_protector) - ]) - - # aarch64 branch protection - AS_CASE(["$target_cpu"], [aarch64], [ - AS_FOR(option, opt, [-mbranch-protection=pac-ret -msign-return-address=all], [ -- RUBY_TRY_CFLAGS(option, [branch_protection=yes], [branch_protection=no]) -+ # Try these flags in the _prepended_ position - i.e. we want to try building a program -+ # with CFLAGS="-mbranch-protection=pac-ret $CFLAGS". If the builder has provided different -+ # branch protection flags in CFLAGS, we don't want to overwrite those. We just want to -+ # find some branch protection flags which work if none were provided. -+ RUBY_TRY_CFLAGS_PREPEND(option, [branch_protection=yes], [branch_protection=no]) - AS_IF([test "x$branch_protection" = xyes], [ -- # C compiler and assembler must be consistent for -mbranch-protection -- # since they both check `__ARM_FEATURE_PAC_DEFAULT` definition. -- RUBY_APPEND_OPTION(XCFLAGS, option) -- RUBY_APPEND_OPTION(ASFLAGS, option) -+ # _prepend_ the options to CFLAGS, so that user-provided flags will overwrite them. -+ # These CFLAGS are used during the configure script to compile further test programs; -+ # however, $harden_flags is prepended separately to CFLAGS at the end of the script. -+ RUBY_PREPEND_OPTION(hardenflags, $opt) - break - ]) - ]) -@@ -985,6 +989,59 @@ test -z "${ac_env_CFLAGS_set}" -a -n "${cflags+set}" && eval CFLAGS="\"$cflags $ - test -z "${ac_env_CXXFLAGS_set}" -a -n "${cxxflags+set}" && eval CXXFLAGS="\"$cxxflags $ARCH_FLAG\"" - } - -+# The lines above expand out the $cflags/$optflags/$debugflags/$hardenflags variables into the -+# CFLAGS variable. So, at this point, we have a $CFLAGS var with the actual compiler flags we're -+# going to use. -+# That means this is the right time to check what branch protection flags are going to be in use -+# and define appropriate macros for use in Context.S based on this -+AS_CASE(["$target_cpu"], [aarch64], [ -+ AC_CACHE_CHECK([whether __ARM_FEATURE_BTI_DEFAULT is defined], -+ rb_cv_aarch64_bti_enabled, -+ AC_COMPILE_IFELSE( -+ [AC_LANG_PROGRAM([[ -+ @%:@ifndef __ARM_FEATURE_BTI_DEFAULT -+ @%:@error "__ARM_FEATURE_BTI_DEFAULT not defined" -+ @%:@endif -+ ]])], -+ [rb_cv_aarch64_bti_enabled=yes], -+ [rb_cv_aarch64_bti_enabled=no]) -+ ) -+ AS_IF([test "$rb_cv_aarch64_bti_enabled" = yes], -+ AC_DEFINE(RUBY_AARCH64_BTI_ENABLED, 1)) -+ AC_CACHE_CHECK([whether __ARM_FEATURE_PAC_DEFAULT is defined], -+ rb_cv_aarch64_pac_enabled, -+ AC_COMPILE_IFELSE( -+ [AC_LANG_PROGRAM([[ -+ @%:@ifndef __ARM_FEATURE_PAC_DEFAULT -+ @%:@error "__ARM_FEATURE_PAC_DEFAULT not defined" -+ @%:@endif -+ ]])], -+ [rb_cv_aarch64_pac_enabled=yes], -+ [rb_cv_aarch64_pac_enabled=no]) -+ ) -+ AS_IF([test "$rb_cv_aarch64_pac_enabled" = yes], -+ AC_DEFINE(RUBY_AARCH64_PAC_ENABLED, 1)) -+ # Context.S will only ever sign its return address with the A-key; it doesn't support -+ # the B-key at the moment. -+ AS_IF([test "$rb_cv_aarch64_pac_enabled" = yes], [ -+ AC_CACHE_CHECK([whether __ARM_FEATURE_PAC_DEFAULT specifies the b-key bit 0x02], -+ rb_cv_aarch64_pac_b_key, -+ AC_COMPILE_IFELSE( -+ [AC_LANG_PROGRAM([[ -+ @%:@ifdef __ARM_FEATURE_PAC_DEFAULT -+ @%:@if __ARM_FEATURE_PAC_DEFAULT & 0x02 -+ @%:@error "__ARM_FEATURE_PAC_DEFAULT specifies B key" -+ @%:@endif -+ @%:@endif -+ ]])], -+ [rb_cv_aarch64_pac_b_key=no], -+ [rb_cv_aarch64_pac_b_key=yes]) -+ ) -+ AS_IF([test "$rb_cv_aarch64_pac_b_key" = yes], -+ AC_MSG_ERROR(-mbranch-protection flag specified b-key but Ruby's Context.S does not support this yet.)) -+ ]) -+]) -+ - AC_CACHE_CHECK([whether compiler has statement and declarations in expressions], - rb_cv_have_stmt_and_decl_in_expr, - [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],[[ __extension__ ({ int a = 0; a; }); ]])], -@@ -4215,12 +4272,13 @@ AS_IF([test "${ARCH_FLAG}"], [ - rb_cv_warnflags=`echo "$rb_cv_warnflags" | sed 's/^ *//;s/ *$//'` - warnflags="$rb_cv_warnflags" - AC_SUBST(cppflags)dnl --AC_SUBST(cflags, ["${orig_cflags:+$orig_cflags }"'${optflags} ${debugflags} ${warnflags}'])dnl -+AC_SUBST(cflags, ['${hardenflags} '"${orig_cflags:+$orig_cflags }"' ${optflags} ${debugflags} ${warnflags}'])dnl - AC_SUBST(cxxflags)dnl - AC_SUBST(optflags)dnl - AC_SUBST(debugflags)dnl - AC_SUBST(warnflags)dnl - AC_SUBST(strict_warnflags)dnl -+AC_SUBST(hardenflags)dnl - AC_SUBST(XCFLAGS)dnl - AC_SUBST(XLDFLAGS)dnl - AC_SUBST(EXTLDFLAGS)dnl -@@ -4688,6 +4746,7 @@ config_summary "DLDFLAGS" "$DLDFLAGS" - config_summary "optflags" "$optflags" - config_summary "debugflags" "$debugflags" - config_summary "warnflags" "$warnflags" -+config_summary "hardenflags" "$hardenflags" - config_summary "strip command" "$STRIP" - config_summary "install doc" "$DOCTARGETS" - config_summary "YJIT support" "$YJIT_SUPPORT" -diff --git a/coroutine/arm64/Context.S b/coroutine/arm64/Context.S -index 5251ab214df1f0..54611a247e2f66 100644 ---- a/coroutine/arm64/Context.S -+++ b/coroutine/arm64/Context.S -@@ -5,6 +5,8 @@ - ## Copyright, 2018, by Samuel Williams. - ## - -+#include "ruby/config.h" -+ - #define TOKEN_PASTE(x,y) x##y - #define PREFIXED_SYMBOL(prefix,name) TOKEN_PASTE(prefix,name) - -@@ -27,10 +29,10 @@ - .global PREFIXED_SYMBOL(SYMBOL_PREFIX,coroutine_transfer) - PREFIXED_SYMBOL(SYMBOL_PREFIX,coroutine_transfer): - --#if defined(__ARM_FEATURE_PAC_DEFAULT) && (__ARM_FEATURE_PAC_DEFAULT != 0) -+#if defined(RUBY_AARCH64_PAC_ENABLED) - # paciasp (it also acts as BTI landing pad, so no need to insert BTI also) - hint #25 --#elif defined(__ARM_FEATURE_BTI_DEFAULT) && (__ARM_FEATURE_BTI_DEFAULT != 0) -+#elif defined(RUBY_AARCH64_BTI_ENABLED) - # For the the case PAC is not enabled but BTI is. - # bti c - hint #34 -@@ -73,7 +75,7 @@ PREFIXED_SYMBOL(SYMBOL_PREFIX,coroutine_transfer): - # Pop stack frame - add sp, sp, 0xa0 - --#if defined(__ARM_FEATURE_PAC_DEFAULT) && (__ARM_FEATURE_PAC_DEFAULT != 0) -+#if defined(RUBY_AARCH64_PAC_ENABLED) - # autiasp: Authenticate x30 (LR) with SP and key A - hint #29 - #endif -@@ -85,18 +87,18 @@ PREFIXED_SYMBOL(SYMBOL_PREFIX,coroutine_transfer): - .section .note.GNU-stack,"",%progbits - #endif - --#if __ARM_FEATURE_BTI_DEFAULT != 0 || __ARM_FEATURE_PAC_DEFAULT != 0 -+#if defined(RUBY_AARCH64_BTI_ENABLED) || defined(RUBY_AARCH64_PAC_ENABLED) - /* See "ELF for the Arm 64-bit Architecture (AArch64)" - https://github.com/ARM-software/abi-aa/blob/2023Q3/aaelf64/aaelf64.rst#program-property */ - # define GNU_PROPERTY_AARCH64_FEATURE_1_BTI (1<<0) - # define GNU_PROPERTY_AARCH64_FEATURE_1_PAC (1<<1) - --# if __ARM_FEATURE_BTI_DEFAULT != 0 -+# if defined(RUBY_AARCH64_BTI_ENABLED) - # define BTI_FLAG GNU_PROPERTY_AARCH64_FEATURE_1_BTI - # else - # define BTI_FLAG 0 - # endif --# if __ARM_FEATURE_PAC_DEFAULT != 0 -+# if defined(RUBY_AARCH64_PAC_ENABLED) - # define PAC_FLAG GNU_PROPERTY_AARCH64_FEATURE_1_PAC - # else - # define PAC_FLAG 0 -diff --git a/template/Makefile.in b/template/Makefile.in -index 033ac56cb38886..abb4469777ce8a 100644 ---- a/template/Makefile.in -+++ b/template/Makefile.in -@@ -89,6 +89,7 @@ cflags = @cflags@ - optflags = @optflags@ - debugflags = @debugflags@ - warnflags = @warnflags@ @strict_warnflags@ -+hardenflags = @hardenflags@ - cppflags = @cppflags@ - incflags = @incflags@ - RUBY_DEVEL = @RUBY_DEVEL@ # "yes" or empty -diff --git a/tool/m4/ruby_append_option.m4 b/tool/m4/ruby_append_option.m4 -index ff828d2162c22f..98359fa1f95f52 100644 ---- a/tool/m4/ruby_append_option.m4 -+++ b/tool/m4/ruby_append_option.m4 -@@ -3,3 +3,7 @@ AC_DEFUN([RUBY_APPEND_OPTION], - [# RUBY_APPEND_OPTION($1) - AS_CASE([" [$]{$1-} "], - [*" $2 "*], [], [' '], [ $1="$2"], [ $1="[$]$1 $2"])])dnl -+AC_DEFUN([RUBY_PREPEND_OPTION], -+ [# RUBY_APPEND_OPTION($1) -+ AS_CASE([" [$]{$1-} "], -+ [*" $2 "*], [], [' '], [ $1="$2"], [ $1="$2 [$]$1"])])dnl -diff --git a/tool/m4/ruby_try_cflags.m4 b/tool/m4/ruby_try_cflags.m4 -index b74718fe5e1cef..b397642aad9ca2 100644 ---- a/tool/m4/ruby_try_cflags.m4 -+++ b/tool/m4/ruby_try_cflags.m4 -@@ -22,3 +22,20 @@ AC_DEFUN([RUBY_TRY_CFLAGS], [ - AC_MSG_RESULT(no)], - [$4], [$5]) - ])dnl -+ -+AC_DEFUN([_RUBY_TRY_CFLAGS_PREPEND], [ -+ RUBY_WERROR_FLAG([ -+ CFLAGS="$1 [$]CFLAGS" -+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[$4]], [[$5]])], -+ [$2], [$3]) -+ ])dnl -+])dnl -+AC_DEFUN([RUBY_TRY_CFLAGS_PREPEND], [ -+ AC_MSG_CHECKING([whether ]$1[ is accepted as CFLAGS])dnl -+ _RUBY_TRY_CFLAGS_PREPEND([$1], -+ [$2 -+ AC_MSG_RESULT(yes)], -+ [$3 -+ AC_MSG_RESULT(no)], -+ [$4], [$5]) -+])dnl diff --git a/ruby-3.4.0-openssl-respect-crypto-policies-tls-min.patch b/ruby-3.4.0-openssl-respect-crypto-policies-tls-min.patch deleted file mode 100644 index 6c7a4dd..0000000 --- a/ruby-3.4.0-openssl-respect-crypto-policies-tls-min.patch +++ /dev/null @@ -1,47 +0,0 @@ -From ae215a47ae1a6527bb7b8566e5bcc9430652462f Mon Sep 17 00:00:00 2001 -From: Ewoud Kohl van Wijngaarden -Date: Fri, 5 Jan 2024 15:58:59 +0100 -Subject: [PATCH] Only set min_version on OpenSSL < 1.1.0 - -Both Red Hat and Debian-like systems configure the minimum TLS version -to be 1.2 by default, but allow users to change this via configs. - -On Red Hat and derivatives this happens via crypto-policies[1], which in -writes settings in /etc/crypto-policies/back-ends/opensslcnf.config. -Most notably, it sets TLS.MinProtocol there. For Debian there's -MinProtocol in /etc/ssl/openssl.cnf. Both default to TLSv1.2, which is -considered a secure default. - -In constrast, the SSLContext has a hard coded OpenSSL::SSL::TLS1_VERSION -for min_version. TLS 1.0 and 1.1 are considered insecure. By always -setting this in the default parameters, the system wide default can't be -respected, even if a developer wants to. - -This takes the approach that's also done for ciphers: it's only set for -OpenSSL < 1.1.0. - -[1]: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/security_hardening/using-the-system-wide-cryptographic-policies_security-hardening ---- - lib/openssl/ssl.rb | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/ext/openssl/lib/openssl/ssl.rb b/ext/openssl/lib/openssl/ssl.rb -index e557b8b48..83ecacafb 100644 ---- a/ext/openssl/lib/openssl/ssl.rb -+++ b/ext/openssl/lib/openssl/ssl.rb -@@ -22,7 +22,6 @@ module OpenSSL - module SSL - class SSLContext - DEFAULT_PARAMS = { # :nodoc: -- :min_version => OpenSSL::SSL::TLS1_VERSION, - :verify_mode => OpenSSL::SSL::VERIFY_PEER, - :verify_hostname => true, - :options => -> { -@@ -55,6 +54,7 @@ class SSLContext - if !(OpenSSL::OPENSSL_VERSION.start_with?("OpenSSL") && - OpenSSL::OPENSSL_VERSION_NUMBER >= 0x10100000) - DEFAULT_PARAMS.merge!( -+ min_version: OpenSSL::SSL::TLS1_VERSION, - ciphers: %w{ - ECDHE-ECDSA-AES128-GCM-SHA256 - ECDHE-RSA-AES128-GCM-SHA256 diff --git a/ruby.spec b/ruby.spec index 82b5d34..b356e59 100644 --- a/ruby.spec +++ b/ruby.spec @@ -1,16 +1,16 @@ %global major_version 3 -%global minor_version 3 -%global teeny_version 6 +%global minor_version 4 +%global teeny_version 0 %global major_minor_version %{major_version}.%{minor_version} %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_release %{ruby_version} # Specify the named version. It has precedense to revision. -#%%global milestone rc1 +%dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -#%%global revision ef084cc8f4 +%global revision 3da3cabf98 %global ruby_archive %{name}-%{ruby_version} @@ -27,7 +27,7 @@ %global rubygems_dir %{_datadir}/rubygems # Bundled libraries versions -%global rubygems_version 3.5.22 +%global rubygems_version 3.6.0.dev %global rubygems_molinillo_version 0.8.0 %global rubygems_net_http_version 0.4.1 %global rubygems_net_protocol_version 0.2.2 @@ -39,7 +39,7 @@ %global rubygems_uri_version 0.13.1 # Default gems. -%global bundler_version 2.5.22 +%global bundler_version 2.6.0.dev %global bundler_connection_pool_version 2.4.1 %global bundler_fileutils_version 1.7.2 %global bundler_net_http_persistent_version 4.0.4 @@ -49,39 +49,31 @@ %global bundler_tsort_version 0.2.0 %global bundler_uri_version 0.13.1 -%global abbrev_version 0.1.2 -%global base64_version 0.2.0 %global benchmark_version 0.3.0 %global cgi_version 0.4.1 -%global csv_version 3.2.8 %global date_version 3.3.4 %global delegate_version 0.3.1 %global did_you_mean_version 1.6.3 %global digest_version 3.1.1 -%global drb_version 2.2.0 %global english_version 0.8.0 -%global erb_version 4.0.3 +%global erb_version 4.0.4 %global error_highlight_version 0.6.0 %global etc_version 1.4.3 %global fcntl_version 1.1.0 -%global fiddle_version 1.1.2 +%global fiddle_version 1.1.3.dev %global fileutils_version 1.7.2 %global find_version 0.2.0 %global forwardable_version 1.3.3 -%global getoptlong_version 0.2.1 %global io_nonblock_version 0.3.0 %global io_wait_version 0.3.1 %global ipaddr_version 1.2.6 -%global logger_version 1.6.0 -%global mutex_m_version 0.2.0 +%global logger_version 1.6.1 %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 %global open3_version 0.2.1 %global openssl_version 3.2.0 %global open_uri_version 0.4.1 -%global optparse_version 0.4.0 +%global optparse_version 0.5.0 %global ostruct_version 0.6.0 %global pathname_version 0.3.0 %global pp_version 0.5.0 @@ -89,20 +81,18 @@ %global pstore_version 0.1.3 %global readline_version 0.0.4 %global reline_version 0.5.10 -%global resolv_version 0.3.0 -%global resolv_replace_version 0.1.1 -%global rinda_version 0.2.0 +%global resolv_version 0.4.0 %global ruby2_keywords_version 0.0.5 %global securerandom_version 0.3.1 %global set_version 1.1.0 %global shellwords_version 0.2.0 %global singleton_version 0.2.0 -%global stringio_version 3.1.1 -%global strscan_version 3.0.9 -%global syntax_suggest_version 2.0.1 +%global stringio_version 3.1.2.dev +%global strscan_version 3.1.1.dev +%global syntax_suggest_version 2.0.0 %global syslog_version 0.1.2 %global tempfile_version 0.2.1 -%global time_version 0.3.0 +%global time_version 0.4.0 %global timeout_version 0.4.1 %global tmpdir_version 0.2.0 %global tsort_version 0.2.0 @@ -111,34 +101,48 @@ %global weakref_version 0.1.3 %global win32ole_version 1.8.10 %global yaml_version 0.3.0 -%global prism_version 0.19.0 +%global prism_version 1.0.0 %global zlib_version 3.1.1 # Gemified default gems. -%global bigdecimal_version 3.1.5 -%global io_console_version 0.7.1 -%global irb_version 1.13.1 +%global io_console_version 0.7.2 +%global irb_version 1.14.1 %global json_version 2.7.2 -%global psych_version 5.1.2 -%global rdoc_version 6.6.3.1 +%global psych_version 5.2.0.beta1 +%global rdoc_version 6.7.0 # Bundled gems. +%global abbrev_version 0.1.2 +%global base64_version 0.2.0 +%global bigdecimal_version 3.1.8 +%global csv_version 3.3.0 %global debug_version 1.9.2 -%global net_ftp_version 0.3.4 -%global net_imap_version 0.4.9.1 +%global drb_version 2.2.1 +%global getoptlong_version 0.2.1 +%global net_ftp_version 0.3.8 +%global net_imap_version 0.4.17 %global net_pop_version 0.1.2 -%global net_smtp_version 0.4.0.1 +%global net_smtp_version 0.5.0 +%global nkf_version 0.2.0 %global matrix_version 0.4.2 -%global minitest_version 5.20.0 -%global power_assert_version 2.0.3 +%global minitest_version 5.25.1 +%global mutex_m_version 0.2.0 +%global observer_version 0.1.2 +%global power_assert_version 2.0.4 %global prime_version 0.1.2 -%global racc_version 1.7.3 -%global rake_version 13.1.0 -%global rbs_version 3.4.0 -%global rexml_version 3.3.9 +%global racc_version 1.8.1 +%global rake_version 13.2.1 +%global rbs_version 3.6.1 +%global repl_type_completor_version 0.1.7 +%global resolv_replace_version 0.1.1 +%global rexml_version 3.3.8 +%global rinda_version 0.2.0 %global rss_version 0.3.1 -%global test_unit_version 3.6.1 -%global typeprof_version 0.21.9 +%global syslog_version 0.1.2 +%global test_unit_version 3.6.2 +%global typeprof_version 0.21.11 +%global win32_registry_version 0.0.1 + # Bundled nkf version %global bundled_nkf_version 2.1.5 @@ -276,16 +280,6 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch # Disable syntax_suggest test suite, which tries to download its dependencies. # https://bugs.ruby-lang.org/issues/19297 Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.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 -# Make sure hardeding flags are correctly applied. -# https://bugs.ruby-lang.org/issues/20520 -Patch12: ruby-3.4.0-Extract-hardening-CFLAGS-to-a-special-hardenflags-variable.patch -# Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. -# https://github.com/ruby/openssl/pull/710 -# https://github.com/ruby/ruby/commit/6213ab1a51387fd9cdcb5e87908722f3bbdf78cb -Patch13: ruby-3.4.0-openssl-respect-crypto-policies-tls-min.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} @@ -363,11 +357,6 @@ Provides: bundled(ccan-check_type) Provides: bundled(ccan-container_of) Provides: bundled(ccan-list) -# https://github.com/nurse/nkf -# Please note that nkf going to be promoted to bundled gem in Ruby 3.4: -# https://github.com/ruby/ruby/commit/2e3a7f70ae71650be6ea38a483f66ce17ca5eb1d -Provides: bundled(nkf) = %{bundled_nkf_version} - # StdLib default gems. Provides: bundled(rubygem-did_you_mean) = %{did_you_mean_version} Provides: bundled(rubygem-openssl) = %{openssl_version} @@ -604,13 +593,31 @@ many machines, systematically and repeatably. %package bundled-gems Summary: Bundled gems which are part of Ruby StdLib +Provides: bundled(rubygem-abbrev) = %{abbrev_version} +Provides: bundled(rubygem-base64) = %{base64_version} +Provides: bundled(rubygem-csv) = %{csv_version} Provides: bundled(rubygem-debug) = %{debug_version} +Provides: bundled(rubygem-drb) = %{drb_version} +Provides: bundled(rubygem-getoptlong) = %{getoptlong_version} Provides: bundled(rubygem-matrix) = %{matrix_version} +Provides: bundled(rubygem-mutex_m) = %{mutex_m_version} Provides: bundled(rubygem-net-ftp) = %{net_ftp_version} Provides: bundled(rubygem-net-imap) = %{net_imap_version} Provides: bundled(rubygem-net-pop) = %{net_pop_version} Provides: bundled(rubygem-net-smtp) = %{net_smtp_version} +Provides: bundled(rubygem-nkf) = %{nkf_version} Provides: bundled(rubygem-prime) = %{prime_version} +Provides: bundled(rubygem-observer) = %{observer_version} +Provides: bundled(rubygem-repl_type_completor) = %{repl_type_completor_version} +Provides: bundled(rubygem-resolv-replace) = %{resolv_replace_version} +Provides: bundled(rubygem-rinda) = %{rinda_version} +Provides: bundled(rubygem-syslog) = %{syslog_version} +Provides: bundled(rubygem-win32-registry) = %{win32_registry_version} +# https://github.com/nurse/nkf +# Please note that nkf going to be promoted to bundled gem in Ruby 3.4: +# https://github.com/ruby/ruby/commit/2e3a7f70ae71650be6ea38a483f66ce17ca5eb1d +Provides: bundled(nkf) = %{bundled_nkf_version} + %description bundled-gems Bundled gems which are part of Ruby StdLib. While being part of Ruby, these @@ -764,8 +771,6 @@ analysis result in RBS format, a standard type description format for Ruby %patch 4 -p1 %patch 6 -p1 %patch 9 -p1 -%patch 12 -p1 -%patch 13 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -817,6 +822,11 @@ rm -rf %{buildroot} # multilib systems and install config.h wrapper %multilib_fix_c_header --file %{_includedir}/%{name}/config.h +# `ruby` executable is placed int `libexec` directory for some unknow reasons. +# https://bugs.ruby-lang.org/issues/20800 +find %{buildroot}%{_libexecdir} -name ruby -exec mv '{}' %{buildroot}/%{_bindir} \; +rm -rd %{buildroot}%{_libexecdir} + # Rename the ruby executable. It is replaced by RubyPick. %{?with_rubypick:mv %{buildroot}%{_bindir}/%{name}{,-mri}} @@ -864,7 +874,7 @@ mv %{buildroot}%{ruby_libdir}/gems %{buildroot}%{gem_dir} mkdir -p %{buildroot}%{_exec_prefix}/lib{,64}/gems/%{name} # Move bundled rubygems to %%gem_dir and %%gem_extdir_mri -# make symlinks for io-console and bigdecimal, which are considered to be part of stdlib by other Gems +# make symlinks for io-console, which is considered to be part of stdlib by other Gems mkdir -p %{buildroot}%{gem_libdir irb} mv %{buildroot}%{ruby_libdir}/irb* %{buildroot}%{gem_libdir irb} mv %{buildroot}%{gem_spec -d irb} %{buildroot}%{gem_spec irb} @@ -881,15 +891,6 @@ mkdir -p %{buildroot}%{gem_libdir rdoc} mv %{buildroot}%{ruby_libdir}/rdoc* %{buildroot}%{gem_libdir rdoc} mv %{buildroot}%{gem_spec -d rdoc} %{buildroot}%{gem_spec rdoc} -mkdir -p %{buildroot}%{gem_libdir bigdecimal} -mkdir -p %{buildroot}%{gem_extdir_mri bigdecimal} -mv %{buildroot}%{ruby_libdir}/bigdecimal %{buildroot}%{gem_libdir bigdecimal} -mv %{buildroot}%{ruby_libarchdir}/bigdecimal.so %{buildroot}%{gem_extdir_mri bigdecimal} -touch %{buildroot}%{gem_extdir_mri bigdecimal}/gem.build_complete -mv %{buildroot}%{gem_spec -d bigdecimal} %{buildroot}%{gem_spec bigdecimal} -ln -s %{gem_libdir bigdecimal}/bigdecimal %{buildroot}%{ruby_libdir}/bigdecimal -ln -s %{gem_extdir_mri bigdecimal}/bigdecimal.so %{buildroot}%{ruby_libarchdir}/bigdecimal.so - # TODO: Put help files into proper location. # https://bugs.ruby-lang.org/issues/15359 mkdir -p %{buildroot}%{gem_libdir bundler} @@ -968,7 +969,7 @@ sed -i 's/^/%lang(ja) /' .ruby-doc.ja %check %if 0%{?with_hardening_test} # Check Ruby hardening. -%define fortification_x86_64 fortified="11" fortify-able="28" +%define fortification_x86_64 fortified="12" fortify-able="29" %define fortification_i686 fortified="10" fortify-able="26" %define fortification_aarch64 fortified="10" fortify-able="26" %define fortification_ppc64le fortified="7" fortify-able="24" @@ -1145,6 +1146,7 @@ make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \ # Nkf. make -C %{_vpath_builddir} -s runruby TESTRUN_SCRIPT="-e \" \ + require 'rubygems'; \ require 'nkf'; \ puts '%%{bundled_nkf_version}: %{bundled_nkf_version}'; \ puts %Q[NKF::NKF_VERSION: #{NKF::NKF_VERSION}]; \ @@ -1239,21 +1241,16 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ # List all these files explicitly to prevent surprises # Platform independent libraries. %dir %{ruby_libdir} -%exclude %{ruby_libdir}/bigdecimal* %exclude %{ruby_libdir}/irb* %exclude %{ruby_libdir}/json* %exclude %{ruby_libdir}/psych* -%{ruby_libdir}/abbrev.rb -%{ruby_libdir}/base64.rb %{ruby_libdir}/benchmark* %{ruby_libdir}/bundled_gems.rb %{ruby_libdir}/cgi* %{ruby_libdir}/coverage.rb -%{ruby_libdir}/csv* %{ruby_libdir}/date.rb %{ruby_libdir}/delegate* %{ruby_libdir}/digest* -%{ruby_libdir}/drb* %{ruby_libdir}/English.rb %{ruby_libdir}/erb* %{ruby_libdir}/error_highlight* @@ -1262,16 +1259,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libdir}/fileutils.rb %{ruby_libdir}/find.rb %{ruby_libdir}/forwardable* -%{ruby_libdir}/getoptlong* %{ruby_libdir}/ipaddr.rb -%{ruby_libdir}/kconv.rb %{ruby_libdir}/logger* %{ruby_libdir}/mkmf.rb %{ruby_libdir}/monitor.rb -%{ruby_libdir}/mutex_m.rb %{ruby_libdir}/net %{ruby_libdir}/objspace* -%{ruby_libdir}/observer* %{ruby_libdir}/open-uri.rb %{ruby_libdir}/open3* %{ruby_libdir}/optionparser.rb @@ -1285,8 +1278,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libdir}/readline.rb %{ruby_libdir}/reline* %{ruby_libdir}/resolv.rb -%{ruby_libdir}/resolv-replace.rb -%{ruby_libdir}/rinda %{ruby_libdir}/ripper* %dir %{ruby_libdir}/ruby_vm %{ruby_libdir}/ruby_vm/rjit @@ -1296,7 +1287,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libdir}/singleton* %{ruby_libdir}/socket.rb %{ruby_libdir}/syntax_suggest* -%{ruby_libdir}/syslog %{ruby_libdir}/tempfile.rb %{ruby_libdir}/timeout* %{ruby_libdir}/time.rb @@ -1395,7 +1385,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libarchdir}/io/nonblock.so %{ruby_libarchdir}/io/wait.so %{ruby_libarchdir}/monitor.so -%{ruby_libarchdir}/nkf.so %{ruby_libarchdir}/objspace.so %{ruby_libarchdir}/pathname.so %{ruby_libarchdir}/pty.so @@ -1406,7 +1395,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libarchdir}/socket.so %{ruby_libarchdir}/stringio.so %{ruby_libarchdir}/strscan.so -%{ruby_libarchdir}/syslog.so %{ruby_libarchdir}/zlib.so # Default gems @@ -1446,16 +1434,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{_rpmconfigdir}/rubygems.con %files default-gems -%gem_spec -d abbrev -%gem_spec -d base64 %gem_spec -d benchmark %gem_spec -d cgi -%gem_spec -d csv %gem_spec -d date %gem_spec -d delegate %gem_spec -d did_you_mean %gem_spec -d digest -%gem_spec -d drb %gem_spec -d english %gem_spec -d erb %gem_instdir erb @@ -1468,16 +1452,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %gem_spec -d fileutils %gem_spec -d find %gem_spec -d forwardable -%gem_spec -d getoptlong %gem_spec -d io-nonblock %gem_spec -d io-wait %gem_spec -d ipaddr %gem_spec -d logger -%gem_spec -d mutex_m %gem_spec -d net-http %gem_spec -d net-protocol -%gem_spec -d nkf -%gem_spec -d observer %gem_spec -d open3 %gem_spec -d open-uri %gem_spec -d optparse @@ -1490,8 +1470,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %gem_spec -d readline %gem_spec -d reline %gem_spec -d resolv -%gem_spec -d resolv-replace -%gem_spec -d rinda %gem_spec -d ruby2_keywords %gem_spec -d securerandom %gem_spec -d set @@ -1502,7 +1480,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %gem_spec -d syntax_suggest %{_bindir}/syntax_suggest %gem_instdir syntax_suggest -%gem_spec -d syslog %gem_spec -d tempfile %gem_spec -d time %gem_spec -d timeout @@ -1537,8 +1514,6 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{_datadir}/ri %files -n rubygem-bigdecimal -%{ruby_libdir}/bigdecimal* -%{ruby_libarchdir}/bigdecimal* %{gem_extdir_mri bigdecimal} %{gem_instdir bigdecimal} %{gem_spec bigdecimal} @@ -1575,27 +1550,68 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{_mandir}/man5/gemfile.5* %files bundled-gems -# rdbg -%{_bindir}/rdbg -%dir %{gem_extdir_mri debug} -%{gem_extdir_mri debug}/gem.build_complete -%dir %{gem_extdir_mri debug}/debug -%{gem_extdir_mri debug}/debug/debug.so -%dir %{gem_instdir debug} -%exclude %{gem_instdir debug}/.* -%doc %{gem_instdir debug}/CONTRIBUTING.md -%{gem_instdir debug}/Gemfile -%license %{gem_instdir debug}/LICENSE.txt -%doc %{gem_instdir debug}/README.md -%{gem_instdir debug}/Rakefile -%doc %{gem_instdir debug}/TODO.md -%{gem_instdir debug}/exe -%{gem_libdir debug} -%{gem_instdir debug}/misc -%{gem_spec debug} +# abbrev +%dir %{gem_instdir abbrev} +%license %{gem_instdir abbrev}/LICENSE.txt +%{gem_instdir abbrev}/bin +%{gem_libdir abbrev} +%{gem_spec abbrev} +%{gem_instdir abbrev}/Gemfile +%doc %{gem_instdir abbrev}/README.md +%{gem_instdir abbrev}/Rakefile + +# base64 +%dir %{gem_instdir base64} +%license %{gem_instdir base64}/LICENSE.txt +%{gem_libdir base64} +%{gem_spec base64} +%doc %{gem_instdir base64}/README.md + +# csv +%dir %{gem_instdir csv} +%license %{gem_instdir csv}/LICENSE.txt +%doc %{gem_instdir csv}/NEWS.md +%{gem_libdir csv} +%{gem_spec csv} +%doc %{gem_instdir csv}/README.md +%doc %{gem_instdir csv}/doc + +# drb +%dir %{gem_instdir drb} +%license %{gem_instdir drb}/LICENSE.txt +%{gem_libdir drb} +%{gem_spec drb} + +# getoptlong +%dir %{gem_instdir getoptlong} +%license %{gem_instdir getoptlong}/LICENSE.txt +%{gem_instdir getoptlong}/bin +%{gem_libdir getoptlong} +%{gem_instdir getoptlong}/sample +%{gem_spec getoptlong} +%{gem_instdir getoptlong}/Gemfile +%doc %{gem_instdir getoptlong}/README.md +%{gem_instdir getoptlong}/Rakefile + +# matrix +%dir %{gem_instdir matrix} +%license %{gem_instdir matrix}/LICENSE.txt +%{gem_libdir matrix} +%{gem_spec matrix} + +# mutex_m +%dir %{gem_instdir mutex_m} +%license %{gem_instdir mutex_m}/LICENSE.txt +%{gem_libdir mutex_m} +%{gem_spec mutex_m} +%{gem_instdir mutex_m}/Gemfile +%doc %{gem_instdir mutex_m}/README.md +%{gem_instdir mutex_m}/Rakefile # net-ftp %dir %{gem_instdir net-ftp} +%license %{gem_instdir net-ftp}/BSDL +%license %{gem_instdir net-ftp}/COPYING %{gem_instdir net-ftp}/Gemfile %license %{gem_instdir net-ftp}/LICENSE.txt %doc %{gem_instdir net-ftp}/README.md @@ -1605,6 +1621,8 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ # net-imap %dir %{gem_instdir net-imap} +%license %{gem_instdir net-imap}/BSDL +%license %{gem_instdir net-imap}/COPYING %{gem_instdir net-imap}/Gemfile %license %{gem_instdir net-imap}/LICENSE.txt %doc %{gem_instdir net-imap}/README.md @@ -1612,6 +1630,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{gem_instdir net-imap}/docs %{gem_libdir net-imap} %{gem_instdir net-imap}/rakelib +%{gem_instdir net-imap}/sample %{gem_spec net-imap} # net-pop @@ -1631,11 +1650,27 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{gem_libdir net-smtp} %{gem_spec net-smtp} -# matrix -%dir %{gem_instdir matrix} -%license %{gem_instdir matrix}/LICENSE.txt -%{gem_libdir matrix} -%{gem_spec matrix} +# nkf +%dir %{gem_instdir nkf} +%{gem_extdir_mri nkf} +%license %{gem_instdir nkf}/LICENSE.txt +%{gem_instdir nkf}/bin +%{gem_libdir nkf} +%{gem_spec nkf} +%{gem_instdir nkf}/Gemfile +%doc %{gem_instdir nkf}/README.md +%{gem_instdir nkf}/Rakefile + +# observer +%dir %{gem_instdir observer} +%license %{gem_instdir observer}/LICENSE.txt +%{gem_instdir observer}/bin +%{gem_libdir observer} +%exclude %{gem_cache observer} +%{gem_spec observer} +%{gem_instdir observer}/Gemfile +%doc %{gem_instdir observer}/README.md +%{gem_instdir observer}/Rakefile # prime %dir %{gem_instdir prime} @@ -1647,6 +1682,68 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{gem_libdir prime} %{gem_spec prime} +# rdbg +%{_bindir}/rdbg +%dir %{gem_extdir_mri debug} +%{gem_extdir_mri debug}/gem.build_complete +%dir %{gem_extdir_mri debug}/debug +%{gem_extdir_mri debug}/debug/debug.so +%dir %{gem_instdir debug} +%exclude %{gem_instdir debug}/.* +%doc %{gem_instdir debug}/CONTRIBUTING.md +%{gem_instdir debug}/Gemfile +%license %{gem_instdir debug}/LICENSE.txt +%doc %{gem_instdir debug}/README.md +%{gem_instdir debug}/Rakefile +%doc %{gem_instdir debug}/TODO.md +%{gem_instdir debug}/exe +%{gem_libdir debug} +%{gem_instdir debug}/misc +%{gem_spec debug} + +# repl_type_completor +%dir %{gem_instdir repl_type_completor} +%license %{gem_instdir repl_type_completor}/LICENSE.txt +%{gem_libdir repl_type_completor} +%{gem_instdir repl_type_completor}/sig +%exclude %{gem_cache repl_type_completor} +%{gem_spec repl_type_completor} +%{gem_instdir repl_type_completor}/Gemfile +%doc %{gem_instdir repl_type_completor}/README.md +%{gem_instdir repl_type_completor}/Rakefile + +# rinda +%dir %{gem_instdir rinda} +%license %{gem_instdir rinda}/LICENSE.txt +%{gem_instdir rinda}/bin +%{gem_libdir rinda} +%{gem_spec rinda} +%{gem_instdir rinda}/Gemfile +%doc %{gem_instdir rinda}/README.md +%{gem_instdir rinda}/Rakefile + +# resolv-replace +%dir %{gem_instdir resolv-replace} +%license %{gem_instdir resolv-replace}/LICENSE.txt +%{gem_instdir resolv-replace}/bin +%{gem_libdir resolv-replace} +%{gem_spec resolv-replace} +%{gem_instdir resolv-replace}/Gemfile +%doc %{gem_instdir resolv-replace}/README.md +%{gem_instdir resolv-replace}/Rakefile + +# syslog +%dir %{gem_instdir syslog} +%{gem_extdir_mri syslog} +%license %{gem_instdir syslog}/LICENSE.txt +%{gem_instdir syslog}/bin +%{gem_libdir syslog} +%exclude %{gem_cache syslog} +%{gem_spec syslog} +%{gem_instdir syslog}/Gemfile +%doc %{gem_instdir syslog}/README.md +%{gem_instdir syslog}/Rakefile + %files -n rubygem-minitest %dir %{gem_instdir minitest} %exclude %{gem_instdir minitest}/.* @@ -1683,11 +1780,9 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{gem_extdir_mri rbs}/gem.build_complete %{gem_extdir_mri rbs}/rbs_extension.so %dir %{gem_instdir rbs} -%exclude %{gem_instdir rbs}/.* %license %{gem_instdir rbs}/BSDL %doc %{gem_instdir rbs}/CHANGELOG.md %license %{gem_instdir rbs}/COPYING -%{gem_instdir rbs}/Gemfile* %doc %{gem_instdir rbs}/README.md %{gem_instdir rbs}/Rakefile %{gem_instdir rbs}/Steepfile @@ -1717,6 +1812,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %dir %{gem_instdir racc} %{_bindir}/racc %{gem_extdir_mri racc} +%license %{gem_instdir racc}/BSDL %license %{gem_instdir racc}/COPYING %doc %{gem_instdir racc}/ChangeLog %lang(ja) %doc %{gem_instdir racc}/README.ja.rdoc @@ -1761,6 +1857,9 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog +* Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 +- Upgrade to Ruby 3.4.0 (3da3cabf98) + * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From e04500f7162e2000856814f7817a2d9525703137 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 25 Oct 2024 14:20:44 +0200 Subject: [PATCH 02/18] Update the hardening values for AArch64 --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index b356e59..b050ad2 100644 --- a/ruby.spec +++ b/ruby.spec @@ -971,7 +971,7 @@ sed -i 's/^/%lang(ja) /' .ruby-doc.ja # Check Ruby hardening. %define fortification_x86_64 fortified="12" fortify-able="29" %define fortification_i686 fortified="10" fortify-able="26" -%define fortification_aarch64 fortified="10" fortify-able="26" +%define fortification_aarch64 fortified="12" fortify-able="29" %define fortification_ppc64le fortified="7" fortify-able="24" %define fortification_s390x fortified="10" fortify-able="24" %define fortification_riscv64 fortified="10" fortify-able="26" From a7a0ab6ffe2920568d0ec4a8cdd1c6fdaa7a9018 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 30 Oct 2024 19:08:34 +0100 Subject: [PATCH 03/18] Extract `%gem_version` and `%gem_prerelease` for independent use These macros are useful independently and makes the `%gem_name_version` macro more comprehensive. --- macros.rubygems | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/macros.rubygems b/macros.rubygems index f6e830f..7146c77 100644 --- a/macros.rubygems +++ b/macros.rubygems @@ -2,17 +2,41 @@ %gem_dir %{_datadir}/gems %gem_archdir %{_libdir}/gems +# %gem_prerelease - Provides prerelease string if available. +# +# Usage: %gem_prerelease [custom_gem_name] +# +# If avilable, prints prerelease string, which is a %prerelease macro by +# default. When [custom_gem_name] is provided, the custom_gem_name is used to +# derive %custom_gem_name_prerelease macro, which can be predefined. +# +# Please note that for the prerelease macros are the dashes in +# [custom_gem_name] replaced by underscores. +# +%gem_prerelease() %{?1:%{expand:%%{?%{gsub %{1} - _}_prerelease}}}%{!?1:%{?prerelease}} + +# %gem_version - Provides version string (including prerelease if available). +# +# Usage: %gem_version [custom_gem_name] +# +# Prints version (including prerelease string), that is %version macro by +# default. When [custom_gem_name] is provided, the custom_gem_name is used to +# derive %custom_gem_name_version macro which needs to be predefined. +# +# Please note that for the version macros are the dashes in [custom_gem_name] +# replaced by underscores. +# +%gem_version() %{?1:%{expand:%{%{gsub %{1} - _}_version}}}%{!?1:%{version}}%{gem_prerelease %{?1}} + # %gem_name_version - Provides gem_name-version string. # # Usage: %gem_name_version [custom_gem_name] # # Prints gem_name-version string, by default joining %gem_name, %version and # %prerelease macros. When [custom_gem_name] is provided, the -# custom_gem_name is joined with %custom_gem_name_version macro which needs -# to be predefined. Please note that for the version macros are the dashes -# replaced by underscores. +# custom_gem_name is joined with version as provided by %gem_version macro. # -%gem_name_version() %{?1}%{!?1:%{gem_name}}-%{?1:%{expand:%{%{gsub %{1} - _}_version}}}%{!?1:%{version}}%{?prerelease} +%gem_name_version() %{?1}%{!?1:%{gem_name}}-%{gem_version %{?1}} # Common gem locations and files. # From c122b25ac690e4bba51df7be1b82cc6e866539b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 29 Oct 2024 19:43:57 +0100 Subject: [PATCH 04/18] Improve bundle gems prerelease handling. This attempts to split pre-release version by `tilde`. This should prevent issues such as: ~~~ Problem 1: package rubygems-devel-3.6.0.dev-15.fc42.noarch from copr_base requires ruby(rubygems) >= 3.6.0.dev-15.fc42, but none of the providers can be installed - cannot install the best candidate for the job - nothing provides rubygem(psych) >= 5.2.0.beta1 needed by rubygems-3.6.0.dev-15.fc42.noarch from copr_base ~~~ Where due to this change the `psych` virtual provide becomes: ~~~ rubygem(psych) = 5.2.0~beta1 ~~~ --- ruby.spec | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/ruby.spec b/ruby.spec index b050ad2..d87724c 100644 --- a/ruby.spec +++ b/ruby.spec @@ -87,8 +87,10 @@ %global set_version 1.1.0 %global shellwords_version 0.2.0 %global singleton_version 0.2.0 -%global stringio_version 3.1.2.dev -%global strscan_version 3.1.1.dev +%global stringio_version 3.1.2 +%global stringio_prerelease .dev +%global strscan_version 3.1.1 +%global strscan_prerelease .dev %global syntax_suggest_version 2.0.0 %global syslog_version 0.1.2 %global tempfile_version 0.2.1 @@ -108,7 +110,8 @@ %global io_console_version 0.7.2 %global irb_version 1.14.1 %global json_version 2.7.2 -%global psych_version 5.2.0.beta1 +%global psych_version 5.2.0 +%global psych_prerelease .beta1 %global rdoc_version 6.7.0 # Bundled gems. @@ -393,7 +396,7 @@ Requires: ruby(release) Recommends: rubygem(bundler) >= %{bundler_version} Recommends: rubygem(rdoc) >= %{rdoc_version} Recommends: rubygem(io-console) -Requires: rubygem(psych) >= %{psych_version} +Requires: rubygem(psych) >= %{psych_version}%{?psych_prerelease:~%{sub %{psych_prerelease} 2 -1}} Provides: gem = %{version}-%{release} Provides: ruby(rubygems) = %{version}-%{release} Provides: bundled(rubygems) = %{rubygems_version} @@ -544,9 +547,9 @@ markup language. %package -n rubygem-psych Summary: A libyaml wrapper for Ruby -Version: %{psych_version} +Version: %{psych_version}%{?psych_prerelease:~%{sub %{psych_prerelease} 2 -1}} License: MIT -Provides: bundled(rubygem-psych) = %{psych_version} +Provides: bundled(rubygem-psych) = %{psych_version}%{?psych_prerelease:~%{sub %{psych_prerelease} 2 -1}} %description -n rubygem-psych Psych is a YAML parser and emitter. Psych leverages From fcf414342bb03f163c6676cbe122411492509253 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 5 Nov 2024 11:47:24 +0100 Subject: [PATCH 05/18] Include ruby-{default,bundled}-gems by default. Users are expecting to have them available, because that is what upstream does. --- ruby.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ruby.spec b/ruby.spec index d87724c..3cc34a5 100644 --- a/ruby.spec +++ b/ruby.spec @@ -287,6 +287,8 @@ Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} Recommends: ruby(rubygems) >= %{rubygems_version} +Recommends: ruby-default-gems >= %{version}-%{release} +Recommends: ruby-bundled-gems >= %{version}-%{release} Recommends: rubygem(bigdecimal) >= %{bigdecimal_version} # Build dependencies From 7560438953cc4a0972e9586e9878092a232d2c0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 14 Nov 2024 16:08:39 +0100 Subject: [PATCH 06/18] Upgrade to Ruby 3.4.0 (4074c6b427) --- ...0-Enable-configuration-of-archlibdir.patch | 2 +- ...ed-paths-when-empty-version-string-i.patch | 2 +- ruby-2.1.0-always-use-i386.patch | 2 +- ruby-2.1.0-custom-rubygems-location.patch | 8 +- ruby-2.3.0-ruby_version.patch | 10 +- ruby-2.7.0-Initialize-ABRT-hook.patch | 2 +- ...3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby.spec | 110 +++++++++--------- 8 files changed, 72 insertions(+), 66 deletions(-) diff --git a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch index b7b2bf2..79acc98 100644 --- a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch +++ b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index d261ea57b5..3c13076b82 100644 --- a/configure.ac +++ b/configure.ac -@@ -3538,6 +3538,11 @@ AS_IF([test ${multiarch+set}], [ +@@ -3519,6 +3519,11 @@ AS_IF([test ${multiarch+set}], [ ]) archlibdir='${libdir}/${arch}' diff --git a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index 36c343c..1dec456 100644 --- a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -14,7 +14,7 @@ diff --git a/configure.ac b/configure.ac index c42436c23d..d261ea57b5 100644 --- a/configure.ac +++ b/configure.ac -@@ -4382,7 +4382,8 @@ AS_CASE(["$ruby_version_dir_name"], +@@ -4365,7 +4365,8 @@ AS_CASE(["$ruby_version_dir_name"], ruby_version_dir=/'${ruby_version_dir_name}' if test -z "${ruby_version_dir_name}"; then diff --git a/ruby-2.1.0-always-use-i386.patch b/ruby-2.1.0-always-use-i386.patch index 30188f4..624f34d 100644 --- a/ruby-2.1.0-always-use-i386.patch +++ b/ruby-2.1.0-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index 3c13076b82..93af30321d 100644 --- a/configure.ac +++ b/configure.ac -@@ -4446,6 +4446,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -4429,6 +4429,8 @@ AC_SUBST(vendorarchdir)dnl AC_SUBST(CONFIGURE, "`echo $0 | sed 's|.*/||'`")dnl AC_SUBST(configure_args, "`echo "${ac_configure_args}" | sed 's/\\$/$$/g'`")dnl diff --git a/ruby-2.1.0-custom-rubygems-location.patch b/ruby-2.1.0-custom-rubygems-location.patch index 2ef7b5d..2ff5594 100644 --- a/ruby-2.1.0-custom-rubygems-location.patch +++ b/ruby-2.1.0-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.ac b/configure.ac index 93af30321d..bc13397e0e 100644 --- a/configure.ac +++ b/configure.ac -@@ -4418,6 +4418,10 @@ AC_ARG_WITH(vendorarchdir, +@@ -4401,6 +4401,10 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], [vendorarchdir=${multiarch+'${rubysitearchprefix}/vendor_ruby'${ruby_version_dir}}${multiarch-'${vendorlibdir}/${sitearch}'}]) @@ -26,7 +26,7 @@ index 93af30321d..bc13397e0e 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX='' -@@ -4442,6 +4446,7 @@ AC_SUBST(sitearchdir)dnl +@@ -4425,6 +4429,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl @@ -67,7 +67,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index e9110a17ca..76a1f0a315 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -386,6 +386,7 @@ def CONFIG.[](name, mandatory = false) +@@ -382,6 +382,7 @@ def CONFIG.[](name, mandatory = false) vendorlibdir = CONFIG["vendorlibdir"] vendorarchlibdir = CONFIG["vendorarchdir"] end @@ -75,7 +75,7 @@ index e9110a17ca..76a1f0a315 100755 mandir = CONFIG["mandir", true] docdir = CONFIG["docdir", true] enable_shared = CONFIG["ENABLE_SHARED"] == 'yes' -@@ -978,7 +979,16 @@ def (bins = []).add(name) +@@ -974,7 +975,16 @@ def (bins = []).add(name) install?(:local, :comm, :lib) do prepare "library scripts", rubylibdir noinst = %w[*.txt *.rdoc *.gemspec] diff --git a/ruby-2.3.0-ruby_version.patch b/ruby-2.3.0-ruby_version.patch index 58c023b..8fcdea2 100644 --- a/ruby-2.3.0-ruby_version.patch +++ b/ruby-2.3.0-ruby_version.patch @@ -20,7 +20,7 @@ diff --git a/configure.ac b/configure.ac index 80b137e380..63cd3b4f8b 100644 --- a/configure.ac +++ b/configure.ac -@@ -4332,9 +4332,6 @@ AS_CASE(["$target_os"], +@@ -4315,9 +4315,6 @@ AS_CASE(["$target_os"], rubyw_install_name='$(RUBYW_INSTALL_NAME)' ]) @@ -30,7 +30,7 @@ index 80b137e380..63cd3b4f8b 100644 rubyarchprefix=${multiarch+'${archlibdir}/${RUBY_BASE_NAME}'}${multiarch-'${rubylibprefix}/${arch}'} AC_ARG_WITH(rubyarchprefix, AS_HELP_STRING([--with-rubyarchprefix=DIR], -@@ -4357,57 +4354,63 @@ AC_ARG_WITH(ridir, +@@ -4340,57 +4337,63 @@ AC_ARG_WITH(ridir, AC_SUBST(ridir) AC_SUBST(RI_BASE_NAME) @@ -122,7 +122,7 @@ index 80b137e380..63cd3b4f8b 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) -@@ -4424,6 +4427,7 @@ AC_SUBST(sitearchincludedir)dnl +@@ -4407,6 +4410,7 @@ AC_SUBST(sitearchincludedir)dnl AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl @@ -171,7 +171,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index d4c110e..d39c9a6 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -949,7 +949,7 @@ def (bins = []).add(name) +@@ -945,7 +945,7 @@ def (bins = []).add(name) install?(:doc, :rdoc) do if $rdocdir @@ -262,7 +262,7 @@ diff --git a/configure.ac b/configure.ac index a00f2b6776..999e2d6d5d 100644 --- a/configure.ac +++ b/configure.ac -@@ -142,7 +142,7 @@ RUBY_BASE_NAME=`echo ruby | sed "$program_transform_name"` +@@ -143,7 +143,7 @@ RUBY_BASE_NAME=`echo ruby | sed "$program_transform_name"` RUBYW_BASE_NAME=`echo rubyw | sed "$program_transform_name"` AC_SUBST(RUBY_BASE_NAME) AC_SUBST(RUBYW_BASE_NAME) diff --git a/ruby-2.7.0-Initialize-ABRT-hook.patch b/ruby-2.7.0-Initialize-ABRT-hook.patch index 0be60f1..65d1e65 100644 --- a/ruby-2.7.0-Initialize-ABRT-hook.patch +++ b/ruby-2.7.0-Initialize-ABRT-hook.patch @@ -58,7 +58,7 @@ diff --git a/ruby.c b/ruby.c index 60c57d6259..1eec16f2c8 100644 --- a/ruby.c +++ b/ruby.c -@@ -1740,10 +1740,14 @@ proc_options(long argc, char **argv, ruby_cmdline_options_t *opt, int envopt) +@@ -1744,10 +1744,14 @@ proc_options(long argc, char **argv, ruby_cmdline_options_t *opt, int envopt) void Init_builtin_features(void); diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index e9c0fbb..ded2bf3 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1616,8 +1616,6 @@ no-test-bundled-gems-spec: +@@ -1649,8 +1649,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby.spec b/ruby.spec index 3cc34a5..7eb2bd0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 3da3cabf98 +%global revision 4074c6b427 %global ruby_archive %{name}-%{ruby_version} @@ -29,89 +29,91 @@ # Bundled libraries versions %global rubygems_version 3.6.0.dev %global rubygems_molinillo_version 0.8.0 -%global rubygems_net_http_version 0.4.1 +%global rubygems_net_http_version 0.5.0 %global rubygems_net_protocol_version 0.2.2 -%global rubygems_optparse_version 0.4.0 -%global rubygems_resolv_version 0.4.0 -%global rubygems_securerandom_version 0.3.1 -%global rubygems_timeout_version 0.4.1 +%global rubygems_optparse_version 0.6.0 +%global rubygems_resolv_version 0.5.0 +%global rubygems_securerandom_version 0.3.2 +%global rubygems_timeout_version 0.4.2 %global rubygems_tsort_version 0.2.0 -%global rubygems_uri_version 0.13.1 +%global rubygems_uri_version 1.0.1 # Default gems. %global bundler_version 2.6.0.dev %global bundler_connection_pool_version 2.4.1 -%global bundler_fileutils_version 1.7.2 +%global bundler_fileutils_version 1.7.3 %global bundler_net_http_persistent_version 4.0.4 %global bundler_pub_grub_version 0.5.0 -%global bundler_securerandom_version 0.3.1 -%global bundler_thor_version 1.3.0 +%global bundler_securerandom_version 0.3.2 +%global bundler_thor_version 1.3.2 %global bundler_tsort_version 0.2.0 -%global bundler_uri_version 0.13.1 +%global bundler_uri_version 1.0.1 -%global benchmark_version 0.3.0 +%global benchmark_version 0.4.0 %global cgi_version 0.4.1 -%global date_version 3.3.4 -%global delegate_version 0.3.1 +%global date_version 3.4.0 +%global delegate_version 0.4.0 %global did_you_mean_version 1.6.3 %global digest_version 3.1.1 %global english_version 0.8.0 %global erb_version 4.0.4 %global error_highlight_version 0.6.0 -%global etc_version 1.4.3 -%global fcntl_version 1.1.0 -%global fiddle_version 1.1.3.dev -%global fileutils_version 1.7.2 +%global etc_version 1.4.4 +%global fcntl_version 1.2.0 +%global fiddle_version 1.1.6 +%global fiddle_prerelease .dev +%global fileutils_version 1.7.3 %global find_version 0.2.0 %global forwardable_version 1.3.3 %global io_nonblock_version 0.3.0 %global io_wait_version 0.3.1 -%global ipaddr_version 1.2.6 +%global ipaddr_version 1.2.7 %global logger_version 1.6.1 -%global net_http_version 0.4.1 +%global net_http_version 0.5.0 %global net_protocol_version 0.2.2 %global open3_version 0.2.1 %global openssl_version 3.2.0 -%global open_uri_version 0.4.1 -%global optparse_version 0.5.0 -%global ostruct_version 0.6.0 -%global pathname_version 0.3.0 -%global pp_version 0.5.0 +%global open_uri_version 0.5.0 +%global optparse_version 0.6.0 +%global ostruct_version 0.6.1 +%global pathname_version 0.4.0 +%global pp_version 0.6.1 %global prettyprint_version 0.2.0 -%global pstore_version 0.1.3 +%global prism_version 1.0.0 +%global pstore_version 0.1.4 %global readline_version 0.0.4 -%global reline_version 0.5.10 -%global resolv_version 0.4.0 +%global reline_version 0.5.11 +%global resolv_version 0.5.0 %global ruby2_keywords_version 0.0.5 -%global securerandom_version 0.3.1 +%global securerandom_version 0.3.2 %global set_version 1.1.0 -%global shellwords_version 0.2.0 -%global singleton_version 0.2.0 +%global shellwords_version 0.2.1 +%global singleton_version 0.3.0 %global stringio_version 3.1.2 %global stringio_prerelease .dev %global strscan_version 3.1.1 %global strscan_prerelease .dev -%global syntax_suggest_version 2.0.0 +%global syntax_suggest_version 2.0.1 %global syslog_version 0.1.2 -%global tempfile_version 0.2.1 -%global time_version 0.4.0 -%global timeout_version 0.4.1 -%global tmpdir_version 0.2.0 +%global tempfile_version 0.3.0 +%global time_version 0.4.1 +%global timeout_version 0.4.2 +%global tmpdir_version 0.3.0 %global tsort_version 0.2.0 %global un_version 0.3.0 -%global uri_version 0.13.1 +%global uri_version 1.0.2 %global weakref_version 0.1.3 -%global win32ole_version 1.8.10 -%global yaml_version 0.3.0 -%global prism_version 1.0.0 -%global zlib_version 3.1.1 +%global win32ole_version 1.9.0 +%global win32_registry_version 0.1.0 +%global yaml_version 0.4.0 +%global zlib_version 3.2.0 # Gemified default gems. -%global io_console_version 0.7.2 +%global io_console_version 0.8.0 +%global io_console_prerelease .beta1 %global irb_version 1.14.1 -%global json_version 2.7.2 +%global json_version 2.8.1 %global psych_version 5.2.0 -%global psych_prerelease .beta1 %global rdoc_version 6.7.0 # Bundled gems. @@ -123,7 +125,7 @@ %global drb_version 2.2.1 %global getoptlong_version 0.2.1 %global net_ftp_version 0.3.8 -%global net_imap_version 0.4.17 +%global net_imap_version 0.5.1 %global net_pop_version 0.1.2 %global net_smtp_version 0.5.0 %global nkf_version 0.2.0 @@ -138,13 +140,12 @@ %global rbs_version 3.6.1 %global repl_type_completor_version 0.1.7 %global resolv_replace_version 0.1.1 -%global rexml_version 3.3.8 +%global rexml_version 3.3.9 %global rinda_version 0.2.0 %global rss_version 0.3.1 %global syslog_version 0.1.2 %global test_unit_version 3.6.2 %global typeprof_version 0.21.11 -%global win32_registry_version 0.0.1 # Bundled nkf version @@ -617,7 +618,6 @@ Provides: bundled(rubygem-repl_type_completor) = %{repl_type_completor_version Provides: bundled(rubygem-resolv-replace) = %{resolv_replace_version} Provides: bundled(rubygem-rinda) = %{rinda_version} Provides: bundled(rubygem-syslog) = %{syslog_version} -Provides: bundled(rubygem-win32-registry) = %{win32_registry_version} # https://github.com/nurse/nkf # Please note that nkf going to be promoted to bundled gem in Ruby 3.4: # https://github.com/ruby/ruby/commit/2e3a7f70ae71650be6ea38a483f66ce17ca5eb1d @@ -827,10 +827,15 @@ rm -rf %{buildroot} # multilib systems and install config.h wrapper %multilib_fix_c_header --file %{_includedir}/%{name}/config.h -# `ruby` executable is placed int `libexec` directory for some unknow reasons. +# `ruby` executable is placed in some strange directory for some unknow +# reasons. # https://bugs.ruby-lang.org/issues/20800 -find %{buildroot}%{_libexecdir} -name ruby -exec mv '{}' %{buildroot}/%{_bindir} \; -rm -rd %{buildroot}%{_libexecdir} +# https://github.com/ruby/ruby/pull/12043 +CONFIG_TARGET_DIR=%{buildroot}%{_exec_prefix}/$( \ + %{_vpath_builddir}/miniruby -I%{_vpath_builddir} -rrbconfig -e 'puts RbConfig::CONFIG["config_target"]' +) +mv ${CONFIG_TARGET_DIR}/bin/ruby %{buildroot}%{_bindir} +rm -rd ${CONFIG_TARGET_DIR} # Rename the ruby executable. It is replaced by RubyPick. %{?with_rubypick:mv %{buildroot}%{_bindir}/%{name}{,-mri}} @@ -1494,6 +1499,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %gem_spec -d uri %gem_spec -d weakref #%%gem_spec -d win32ole +#%%gem_spec -d win32-registry %gem_spec -d yaml %gem_spec -d prism %gem_spec -d zlib @@ -1863,7 +1869,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (3da3cabf98) +- Upgrade to Ruby 3.4.0 (4074c6b427) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From afb885fc7a530762be432956a34dd15615bd248a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 15 Nov 2024 10:12:13 +0100 Subject: [PATCH 07/18] Fix documentation generation for gems. --- ruby.spec | 5 + ...act-excerpt-from-raw-pages-correctly.patch | 111 ++++++++++++++++++ 2 files changed, 116 insertions(+) create mode 100644 rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch diff --git a/ruby.spec b/ruby.spec index 7eb2bd0..9b25a88 100644 --- a/ruby.spec +++ b/ruby.spec @@ -284,6 +284,10 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch # Disable syntax_suggest test suite, which tries to download its dependencies. # https://bugs.ruby-lang.org/issues/19297 Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch +# Fix documentation generation for gems. +# https://bugs.ruby-lang.org/issues/20862 +# https://github.com/ruby/rdoc/pull/1200 +Patch10: rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} @@ -776,6 +780,7 @@ analysis result in RBS format, a standard type description format for Ruby %patch 4 -p1 %patch 6 -p1 %patch 9 -p1 +%patch 10 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . diff --git a/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch b/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch new file mode 100644 index 0000000..0e33195 --- /dev/null +++ b/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch @@ -0,0 +1,111 @@ +From 34db821add89ba7dd1e2ed64b7f636e9b6a9261a Mon Sep 17 00:00:00 2001 +From: Stan Lo +Date: Fri, 8 Nov 2024 09:43:28 -0600 +Subject: [PATCH] Extract excerpt from raw pages correctly + +Fixes https://bugs.ruby-lang.org/issues/20862 +--- + lib/rdoc/generator/darkfish.rb | 14 ++++++- + test/rdoc/test_rdoc_generator_darkfish.rb | 50 ++++++++++++++++++++++- + 2 files changed, 61 insertions(+), 3 deletions(-) + +diff --git a/lib/rdoc/generator/darkfish.rb b/lib/rdoc/generator/darkfish.rb +index 25ade1e9f1..08f2b85e3b 100644 +--- a/lib/rdoc/generator/darkfish.rb ++++ b/lib/rdoc/generator/darkfish.rb +@@ -782,7 +782,19 @@ def template_for file, page = true, klass = ERB + + # Returns an excerpt of the content for usage in meta description tags + def excerpt(content) +- text = content.is_a?(RDoc::Comment) ? content.text : content ++ text = case content ++ when RDoc::Comment ++ content.text ++ when RDoc::Markup::Document ++ # This case is for page files that are not markdown nor rdoc ++ # We convert them to markdown for now as it's easier to extract the text ++ formatter = RDoc::Markup::ToMarkdown.new ++ formatter.start_accepting ++ formatter.accept_document(content) ++ formatter.end_accepting ++ else ++ content ++ end + + # Match from a capital letter to the first period, discarding any links, so + # that we don't end up matching badges in the README +diff --git a/test/rdoc/test_rdoc_generator_darkfish.rb b/test/rdoc/test_rdoc_generator_darkfish.rb +index f6c0a1e1cf..0a9be7e4ee 100644 +--- a/test/rdoc/test_rdoc_generator_darkfish.rb ++++ b/test/rdoc/test_rdoc_generator_darkfish.rb +@@ -1,7 +1,7 @@ + # frozen_string_literal: true + require_relative 'helper' + +-class TestRDocGeneratorDarkfish < RDoc::TestCase ++class RDocGeneratorDarkfishTest < RDoc::TestCase + + def setup + super +@@ -348,7 +348,7 @@ def test_meta_tags_for_classes + ) + end + +- def test_meta_tags_for_pages ++ def test_meta_tags_for_rdoc_files + top_level = @store.add_file("CONTRIBUTING.rdoc", parser: RDoc::Parser::Simple) + top_level.comment = <<~RDOC + = Contributing +@@ -367,6 +367,52 @@ def test_meta_tags_for_pages + ) + end + ++ def test_meta_tags_for_markdown_files ++ top_level = @store.add_file("MyPage.md", parser: RDoc::Parser::Markdown) ++ top_level.comment = <<~MARKDOWN ++ # MyPage ++ ++ This is a comment ++ MARKDOWN ++ ++ @g.generate ++ ++ content = File.binread("MyPage_md.html") ++ assert_include(content, '') ++ assert_include( ++ content, ++ '', ++ ) ++ end ++ ++ def test_meta_tags_for_raw_pages ++ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple) ++ top_level.comment = RDoc::Markup::Document.new(RDoc::Markup::Paragraph.new('this is a comment')) ++ ++ @g.generate ++ ++ content = File.binread("MyPage.html") ++ assert_include(content, '') ++ assert_include( ++ content, ++ '', ++ ) ++ end ++ ++ def test_meta_tags_for_empty_document ++ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple) ++ top_level.comment = RDoc::Markup::Document.new ++ ++ @g.generate ++ ++ content = File.binread("MyPage.html") ++ assert_include(content, '') ++ assert_include( ++ content, ++ '', ++ ) ++ end ++ + ## + # Asserts that +filename+ has a link count greater than 1 if hard links to + # @tmpdir are supported. From 23ac0c148a499af412ce7ab94a696c7b89427b58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 18 Nov 2024 10:17:43 +0100 Subject: [PATCH 08/18] Upgrade to Ruby 3.4.0 (0f75ac8380) --- ruby.spec | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ruby.spec b/ruby.spec index 9b25a88..8ecc70e 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 4074c6b427 +%global revision 0f75ac8380 %global ruby_archive %{name}-%{ruby_version} @@ -93,9 +93,9 @@ %global stringio_prerelease .dev %global strscan_version 3.1.1 %global strscan_prerelease .dev -%global syntax_suggest_version 2.0.1 +%global syntax_suggest_version 2.0.2 %global syslog_version 0.1.2 -%global tempfile_version 0.3.0 +%global tempfile_version 0.3.1 %global time_version 0.4.1 %global timeout_version 0.4.2 %global tmpdir_version 0.3.0 @@ -112,7 +112,7 @@ %global io_console_version 0.8.0 %global io_console_prerelease .beta1 %global irb_version 1.14.1 -%global json_version 2.8.1 +%global json_version 2.8.2 %global psych_version 5.2.0 %global rdoc_version 6.7.0 @@ -1874,7 +1874,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (4074c6b427) +- Upgrade to Ruby 3.4.0 (0f75ac8380) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From f6d8680cd7de7200aa999c7a06e06c5b04ecdf79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 25 Nov 2024 11:09:15 +0100 Subject: [PATCH 09/18] Upgrade to Ruby 3.4.0 (4d8c793bc3) --- ...3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby.spec | 29 ++--- ...act-excerpt-from-raw-pages-correctly.patch | 111 ------------------ 3 files changed, 13 insertions(+), 129 deletions(-) delete mode 100644 rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index ded2bf3..71a6a08 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1649,8 +1649,6 @@ no-test-bundled-gems-spec: +@@ -1652,8 +1652,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby.spec b/ruby.spec index 8ecc70e..fa13bc0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 0f75ac8380 +%global revision 4d8c793bc3 %global ruby_archive %{name}-%{ruby_version} @@ -114,7 +114,7 @@ %global irb_version 1.14.1 %global json_version 2.8.2 %global psych_version 5.2.0 -%global rdoc_version 6.7.0 +%global rdoc_version 6.8.1 # Bundled gems. %global abbrev_version 0.1.2 @@ -130,11 +130,11 @@ %global net_smtp_version 0.5.0 %global nkf_version 0.2.0 %global matrix_version 0.4.2 -%global minitest_version 5.25.1 -%global mutex_m_version 0.2.0 +%global minitest_version 5.25.2 +%global mutex_m_version 0.3.0 %global observer_version 0.1.2 %global power_assert_version 2.0.4 -%global prime_version 0.1.2 +%global prime_version 0.1.3 %global racc_version 1.8.1 %global rake_version 13.2.1 %global rbs_version 3.6.1 @@ -284,10 +284,6 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch # Disable syntax_suggest test suite, which tries to download its dependencies. # https://bugs.ruby-lang.org/issues/19297 Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch -# Fix documentation generation for gems. -# https://bugs.ruby-lang.org/issues/20862 -# https://github.com/ruby/rdoc/pull/1200 -Patch10: rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} @@ -780,7 +776,6 @@ analysis result in RBS format, a standard type description format for Ruby %patch 4 -p1 %patch 6 -p1 %patch 9 -p1 -%patch 10 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -1617,12 +1612,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ # mutex_m %dir %{gem_instdir mutex_m} -%license %{gem_instdir mutex_m}/LICENSE.txt +%license %{gem_instdir mutex_m}/BSDL +%license %{gem_instdir mutex_m}/COPYING %{gem_libdir mutex_m} +%{gem_instdir mutex_m}/sig %{gem_spec mutex_m} -%{gem_instdir mutex_m}/Gemfile %doc %{gem_instdir mutex_m}/README.md -%{gem_instdir mutex_m}/Rakefile # net-ftp %dir %{gem_instdir net-ftp} @@ -1690,12 +1685,12 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ # prime %dir %{gem_instdir prime} -%{gem_instdir prime}/Gemfile -%license %{gem_instdir prime}/LICENSE.txt +%license %{gem_instdir prime}/BSDL +%license %{gem_instdir prime}/COPYING %doc %{gem_instdir prime}/README.md %{gem_instdir prime}/Rakefile -%{gem_instdir prime}/bin %{gem_libdir prime} +%{gem_instdir prime}/sig %{gem_spec prime} # rdbg @@ -1874,7 +1869,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (0f75ac8380) +- Upgrade to Ruby 3.4.0 (4d8c793bc3) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. diff --git a/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch b/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch deleted file mode 100644 index 0e33195..0000000 --- a/rubygem-rdoc-6.7.0-Extract-excerpt-from-raw-pages-correctly.patch +++ /dev/null @@ -1,111 +0,0 @@ -From 34db821add89ba7dd1e2ed64b7f636e9b6a9261a Mon Sep 17 00:00:00 2001 -From: Stan Lo -Date: Fri, 8 Nov 2024 09:43:28 -0600 -Subject: [PATCH] Extract excerpt from raw pages correctly - -Fixes https://bugs.ruby-lang.org/issues/20862 ---- - lib/rdoc/generator/darkfish.rb | 14 ++++++- - test/rdoc/test_rdoc_generator_darkfish.rb | 50 ++++++++++++++++++++++- - 2 files changed, 61 insertions(+), 3 deletions(-) - -diff --git a/lib/rdoc/generator/darkfish.rb b/lib/rdoc/generator/darkfish.rb -index 25ade1e9f1..08f2b85e3b 100644 ---- a/lib/rdoc/generator/darkfish.rb -+++ b/lib/rdoc/generator/darkfish.rb -@@ -782,7 +782,19 @@ def template_for file, page = true, klass = ERB - - # Returns an excerpt of the content for usage in meta description tags - def excerpt(content) -- text = content.is_a?(RDoc::Comment) ? content.text : content -+ text = case content -+ when RDoc::Comment -+ content.text -+ when RDoc::Markup::Document -+ # This case is for page files that are not markdown nor rdoc -+ # We convert them to markdown for now as it's easier to extract the text -+ formatter = RDoc::Markup::ToMarkdown.new -+ formatter.start_accepting -+ formatter.accept_document(content) -+ formatter.end_accepting -+ else -+ content -+ end - - # Match from a capital letter to the first period, discarding any links, so - # that we don't end up matching badges in the README -diff --git a/test/rdoc/test_rdoc_generator_darkfish.rb b/test/rdoc/test_rdoc_generator_darkfish.rb -index f6c0a1e1cf..0a9be7e4ee 100644 ---- a/test/rdoc/test_rdoc_generator_darkfish.rb -+++ b/test/rdoc/test_rdoc_generator_darkfish.rb -@@ -1,7 +1,7 @@ - # frozen_string_literal: true - require_relative 'helper' - --class TestRDocGeneratorDarkfish < RDoc::TestCase -+class RDocGeneratorDarkfishTest < RDoc::TestCase - - def setup - super -@@ -348,7 +348,7 @@ def test_meta_tags_for_classes - ) - end - -- def test_meta_tags_for_pages -+ def test_meta_tags_for_rdoc_files - top_level = @store.add_file("CONTRIBUTING.rdoc", parser: RDoc::Parser::Simple) - top_level.comment = <<~RDOC - = Contributing -@@ -367,6 +367,52 @@ def test_meta_tags_for_pages - ) - end - -+ def test_meta_tags_for_markdown_files -+ top_level = @store.add_file("MyPage.md", parser: RDoc::Parser::Markdown) -+ top_level.comment = <<~MARKDOWN -+ # MyPage -+ -+ This is a comment -+ MARKDOWN -+ -+ @g.generate -+ -+ content = File.binread("MyPage_md.html") -+ assert_include(content, '') -+ assert_include( -+ content, -+ '', -+ ) -+ end -+ -+ def test_meta_tags_for_raw_pages -+ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple) -+ top_level.comment = RDoc::Markup::Document.new(RDoc::Markup::Paragraph.new('this is a comment')) -+ -+ @g.generate -+ -+ content = File.binread("MyPage.html") -+ assert_include(content, '') -+ assert_include( -+ content, -+ '', -+ ) -+ end -+ -+ def test_meta_tags_for_empty_document -+ top_level = @store.add_file("MyPage", parser: RDoc::Parser::Simple) -+ top_level.comment = RDoc::Markup::Document.new -+ -+ @g.generate -+ -+ content = File.binread("MyPage.html") -+ assert_include(content, '') -+ assert_include( -+ content, -+ '', -+ ) -+ end -+ - ## - # Asserts that +filename+ has a link count greater than 1 if hard links to - # @tmpdir are supported. From c468fd1cec3ce30930661854e0089a6b9e272d58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 29 Nov 2024 14:47:02 +0100 Subject: [PATCH 10/18] Upgrade to Ruby 3.4.0 (5067a46502) --- ruby-2.1.0-Enable-configuration-of-archlibdir.patch | 2 +- ...-duplicated-paths-when-empty-version-string-i.patch | 2 +- ruby-2.1.0-always-use-i386.patch | 2 +- ruby-2.1.0-custom-rubygems-location.patch | 4 ++-- ruby-2.3.0-ruby_version.patch | 6 +++--- ruby-3.3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby.spec | 10 +++++----- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch index 79acc98..e4142e9 100644 --- a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch +++ b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index d261ea57b5..3c13076b82 100644 --- a/configure.ac +++ b/configure.ac -@@ -3519,6 +3519,11 @@ AS_IF([test ${multiarch+set}], [ +@@ -3520,6 +3520,11 @@ AS_IF([test ${multiarch+set}], [ ]) archlibdir='${libdir}/${arch}' diff --git a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index 1dec456..7990f77 100644 --- a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -14,7 +14,7 @@ diff --git a/configure.ac b/configure.ac index c42436c23d..d261ea57b5 100644 --- a/configure.ac +++ b/configure.ac -@@ -4365,7 +4365,8 @@ AS_CASE(["$ruby_version_dir_name"], +@@ -4366,7 +4366,8 @@ AS_CASE(["$ruby_version_dir_name"], ruby_version_dir=/'${ruby_version_dir_name}' if test -z "${ruby_version_dir_name}"; then diff --git a/ruby-2.1.0-always-use-i386.patch b/ruby-2.1.0-always-use-i386.patch index 624f34d..ba78846 100644 --- a/ruby-2.1.0-always-use-i386.patch +++ b/ruby-2.1.0-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.ac b/configure.ac index 3c13076b82..93af30321d 100644 --- a/configure.ac +++ b/configure.ac -@@ -4429,6 +4429,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -4430,6 +4430,8 @@ AC_SUBST(vendorarchdir)dnl AC_SUBST(CONFIGURE, "`echo $0 | sed 's|.*/||'`")dnl AC_SUBST(configure_args, "`echo "${ac_configure_args}" | sed 's/\\$/$$/g'`")dnl diff --git a/ruby-2.1.0-custom-rubygems-location.patch b/ruby-2.1.0-custom-rubygems-location.patch index 2ff5594..7e199ac 100644 --- a/ruby-2.1.0-custom-rubygems-location.patch +++ b/ruby-2.1.0-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.ac b/configure.ac index 93af30321d..bc13397e0e 100644 --- a/configure.ac +++ b/configure.ac -@@ -4401,6 +4401,10 @@ AC_ARG_WITH(vendorarchdir, +@@ -4402,6 +4402,10 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], [vendorarchdir=${multiarch+'${rubysitearchprefix}/vendor_ruby'${ruby_version_dir}}${multiarch-'${vendorlibdir}/${sitearch}'}]) @@ -26,7 +26,7 @@ index 93af30321d..bc13397e0e 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX='' -@@ -4425,6 +4429,7 @@ AC_SUBST(sitearchdir)dnl +@@ -4426,6 +4430,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-2.3.0-ruby_version.patch b/ruby-2.3.0-ruby_version.patch index 8fcdea2..f089a33 100644 --- a/ruby-2.3.0-ruby_version.patch +++ b/ruby-2.3.0-ruby_version.patch @@ -20,7 +20,7 @@ diff --git a/configure.ac b/configure.ac index 80b137e380..63cd3b4f8b 100644 --- a/configure.ac +++ b/configure.ac -@@ -4315,9 +4315,6 @@ AS_CASE(["$target_os"], +@@ -4316,9 +4316,6 @@ AS_CASE(["$target_os"], rubyw_install_name='$(RUBYW_INSTALL_NAME)' ]) @@ -30,7 +30,7 @@ index 80b137e380..63cd3b4f8b 100644 rubyarchprefix=${multiarch+'${archlibdir}/${RUBY_BASE_NAME}'}${multiarch-'${rubylibprefix}/${arch}'} AC_ARG_WITH(rubyarchprefix, AS_HELP_STRING([--with-rubyarchprefix=DIR], -@@ -4340,57 +4337,63 @@ AC_ARG_WITH(ridir, +@@ -4341,57 +4338,63 @@ AC_ARG_WITH(ridir, AC_SUBST(ridir) AC_SUBST(RI_BASE_NAME) @@ -122,7 +122,7 @@ index 80b137e380..63cd3b4f8b 100644 AS_IF([test "${LOAD_RELATIVE+set}"], [ AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) -@@ -4407,6 +4410,7 @@ AC_SUBST(sitearchincludedir)dnl +@@ -4408,6 +4411,7 @@ AC_SUBST(sitearchincludedir)dnl AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index 71a6a08..0d355e7 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1652,8 +1652,6 @@ no-test-bundled-gems-spec: +@@ -1656,8 +1656,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby.spec b/ruby.spec index fa13bc0..0bf55b1 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 4d8c793bc3 +%global revision 5067a46502 %global ruby_archive %{name}-%{ruby_version} @@ -82,11 +82,11 @@ %global prism_version 1.0.0 %global pstore_version 0.1.4 %global readline_version 0.0.4 -%global reline_version 0.5.11 +%global reline_version 0.5.12 %global resolv_version 0.5.0 %global ruby2_keywords_version 0.0.5 %global securerandom_version 0.3.2 -%global set_version 1.1.0 +%global set_version 1.1.1 %global shellwords_version 0.2.1 %global singleton_version 0.3.0 %global stringio_version 3.1.2 @@ -144,7 +144,7 @@ %global rinda_version 0.2.0 %global rss_version 0.3.1 %global syslog_version 0.1.2 -%global test_unit_version 3.6.2 +%global test_unit_version 3.6.4 %global typeprof_version 0.21.11 @@ -1869,7 +1869,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (4d8c793bc3) +- Upgrade to Ruby 3.4.0 (5067a46502) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From afd61ca4f4172c5ce9e90d949f68b95fb091c3e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 6 Dec 2024 14:01:32 +0100 Subject: [PATCH 11/18] Upgrade to Ruby 3.4.0 (3901df708d) --- ...3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby.spec | 32 +++++++++++-------- 2 files changed, 19 insertions(+), 15 deletions(-) diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index 0d355e7..dd45ca3 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1656,8 +1656,6 @@ no-test-bundled-gems-spec: +@@ -1658,8 +1658,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby.spec b/ruby.spec index 0bf55b1..ae0ba87 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 5067a46502 +%global revision 3901df708d %global ruby_archive %{name}-%{ruby_version} @@ -51,13 +51,13 @@ %global benchmark_version 0.4.0 %global cgi_version 0.4.1 -%global date_version 3.4.0 +%global date_version 3.4.1 %global delegate_version 0.4.0 -%global did_you_mean_version 1.6.3 +%global did_you_mean_version 2.0.0 %global digest_version 3.1.1 %global english_version 0.8.0 %global erb_version 4.0.4 -%global error_highlight_version 0.6.0 +%global error_highlight_version 0.7.0 %global etc_version 1.4.4 %global fcntl_version 1.2.0 %global fiddle_version 1.1.6 @@ -65,11 +65,11 @@ %global fileutils_version 1.7.3 %global find_version 0.2.0 %global forwardable_version 1.3.3 -%global io_nonblock_version 0.3.0 +%global io_nonblock_version 0.3.1 %global io_wait_version 0.3.1 %global ipaddr_version 1.2.7 -%global logger_version 1.6.1 -%global net_http_version 0.5.0 +%global logger_version 1.6.2 +%global net_http_version 0.6.0 %global net_protocol_version 0.2.2 %global open3_version 0.2.1 %global openssl_version 3.2.0 @@ -77,7 +77,7 @@ %global optparse_version 0.6.0 %global ostruct_version 0.6.1 %global pathname_version 0.4.0 -%global pp_version 0.6.1 +%global pp_version 0.6.2 %global prettyprint_version 0.2.0 %global prism_version 1.0.0 %global pstore_version 0.1.4 @@ -85,7 +85,7 @@ %global reline_version 0.5.12 %global resolv_version 0.5.0 %global ruby2_keywords_version 0.0.5 -%global securerandom_version 0.3.2 +%global securerandom_version 0.4.0 %global set_version 1.1.1 %global shellwords_version 0.2.1 %global singleton_version 0.3.0 @@ -110,9 +110,8 @@ # Gemified default gems. %global io_console_version 0.8.0 -%global io_console_prerelease .beta1 %global irb_version 1.14.1 -%global json_version 2.8.2 +%global json_version 2.9.0 %global psych_version 5.2.0 %global rdoc_version 6.8.1 @@ -130,14 +129,14 @@ %global net_smtp_version 0.5.0 %global nkf_version 0.2.0 %global matrix_version 0.4.2 -%global minitest_version 5.25.2 +%global minitest_version 5.25.4 %global mutex_m_version 0.3.0 %global observer_version 0.1.2 %global power_assert_version 2.0.4 %global prime_version 0.1.3 %global racc_version 1.8.1 %global rake_version 13.2.1 -%global rbs_version 3.6.1 +%global rbs_version 3.7.0 %global repl_type_completor_version 0.1.7 %global resolv_replace_version 0.1.1 %global rexml_version 3.3.9 @@ -1296,6 +1295,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{ruby_libdir}/shellwords.rb %{ruby_libdir}/singleton* %{ruby_libdir}/socket.rb +%{ruby_libdir}/strscan %{ruby_libdir}/syntax_suggest* %{ruby_libdir}/tempfile.rb %{ruby_libdir}/timeout* @@ -1797,14 +1797,18 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %doc %{gem_instdir rbs}/README.md %{gem_instdir rbs}/Rakefile %{gem_instdir rbs}/Steepfile +%{gem_instdir rbs}/config.yml %{gem_instdir rbs}/core %doc %{gem_instdir rbs}/docs %{gem_instdir rbs}/exe %{gem_instdir rbs}/goodcheck.yml +%{gem_instdir rbs}/include %{gem_libdir rbs} %{gem_instdir rbs}/schema %{gem_instdir rbs}/sig +%{gem_instdir rbs}/src %{gem_instdir rbs}/stdlib +%{gem_instdir rbs}/templates %{gem_spec rbs} %files -n rubygem-test-unit @@ -1869,7 +1873,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (5067a46502) +- Upgrade to Ruby 3.4.0 (3901df708d) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From 9c27c8bc0f53ec4e7e715e65bea4c67c277c3421 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 19 Dec 2024 16:51:19 +0100 Subject: [PATCH 12/18] Upgrade to Ruby 3.4.0 (335bba0fde) --- ...3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby.spec | 84 +++++++++---------- 2 files changed, 40 insertions(+), 46 deletions(-) diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index dd45ca3..e82069a 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1658,8 +1658,6 @@ no-test-bundled-gems-spec: +@@ -1654,8 +1654,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby.spec b/ruby.spec index ae0ba87..40048d9 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 3901df708d +%global revision 335bba0fde %global ruby_archive %{name}-%{ruby_version} @@ -27,48 +27,47 @@ %global rubygems_dir %{_datadir}/rubygems # Bundled libraries versions -%global rubygems_version 3.6.0.dev +%global rubygems_version 3.6.1 %global rubygems_molinillo_version 0.8.0 -%global rubygems_net_http_version 0.5.0 +%global rubygems_net_http_version 0.6.0 %global rubygems_net_protocol_version 0.2.2 %global rubygems_optparse_version 0.6.0 -%global rubygems_resolv_version 0.5.0 -%global rubygems_securerandom_version 0.3.2 -%global rubygems_timeout_version 0.4.2 +%global rubygems_resolv_version 0.6.0 +%global rubygems_securerandom_version 0.4.1 +%global rubygems_timeout_version 0.4.3 %global rubygems_tsort_version 0.2.0 -%global rubygems_uri_version 1.0.1 +%global rubygems_uri_version 1.0.2 # Default gems. -%global bundler_version 2.6.0.dev +%global bundler_version 2.6.1 %global bundler_connection_pool_version 2.4.1 %global bundler_fileutils_version 1.7.3 %global bundler_net_http_persistent_version 4.0.4 %global bundler_pub_grub_version 0.5.0 -%global bundler_securerandom_version 0.3.2 +%global bundler_securerandom_version 0.4.1 %global bundler_thor_version 1.3.2 %global bundler_tsort_version 0.2.0 -%global bundler_uri_version 1.0.1 +%global bundler_uri_version 1.0.2 %global benchmark_version 0.4.0 %global cgi_version 0.4.1 %global date_version 3.4.1 %global delegate_version 0.4.0 %global did_you_mean_version 2.0.0 -%global digest_version 3.1.1 +%global digest_version 3.2.0 %global english_version 0.8.0 %global erb_version 4.0.4 %global error_highlight_version 0.7.0 -%global etc_version 1.4.4 +%global etc_version 1.4.5 %global fcntl_version 1.2.0 %global fiddle_version 1.1.6 -%global fiddle_prerelease .dev %global fileutils_version 1.7.3 %global find_version 0.2.0 %global forwardable_version 1.3.3 %global io_nonblock_version 0.3.1 %global io_wait_version 0.3.1 %global ipaddr_version 1.2.7 -%global logger_version 1.6.2 +%global logger_version 1.6.4 %global net_http_version 0.6.0 %global net_protocol_version 0.2.2 %global open3_version 0.2.1 @@ -79,52 +78,50 @@ %global pathname_version 0.4.0 %global pp_version 0.6.2 %global prettyprint_version 0.2.0 -%global prism_version 1.0.0 +%global prism_version 1.2.0 %global pstore_version 0.1.4 %global readline_version 0.0.4 -%global reline_version 0.5.12 -%global resolv_version 0.5.0 +%global reline_version 0.6.0 +%global resolv_version 0.6.0 %global ruby2_keywords_version 0.0.5 -%global securerandom_version 0.4.0 +%global securerandom_version 0.4.1 %global set_version 1.1.1 -%global shellwords_version 0.2.1 +%global shellwords_version 0.2.2 %global singleton_version 0.3.0 %global stringio_version 3.1.2 -%global stringio_prerelease .dev -%global strscan_version 3.1.1 -%global strscan_prerelease .dev +%global strscan_version 3.1.2 %global syntax_suggest_version 2.0.2 -%global syslog_version 0.1.2 +%global syslog_version 0.2.0 %global tempfile_version 0.3.1 %global time_version 0.4.1 -%global timeout_version 0.4.2 -%global tmpdir_version 0.3.0 +%global timeout_version 0.4.3 +%global tmpdir_version 0.3.1 %global tsort_version 0.2.0 %global un_version 0.3.0 %global uri_version 1.0.2 %global weakref_version 0.1.3 -%global win32ole_version 1.9.0 +%global win32ole_version 1.9.1 %global win32_registry_version 0.1.0 %global yaml_version 0.4.0 -%global zlib_version 3.2.0 +%global zlib_version 3.2.1 # Gemified default gems. %global io_console_version 0.8.0 -%global irb_version 1.14.1 -%global json_version 2.9.0 -%global psych_version 5.2.0 -%global rdoc_version 6.8.1 +%global irb_version 1.14.3 +%global json_version 2.9.1 +%global psych_version 5.2.2 +%global rdoc_version 6.10.0 # Bundled gems. %global abbrev_version 0.1.2 %global base64_version 0.2.0 %global bigdecimal_version 3.1.8 -%global csv_version 3.3.0 -%global debug_version 1.9.2 +%global csv_version 3.3.1 +%global debug_version 1.10.0 %global drb_version 2.2.1 %global getoptlong_version 0.2.1 %global net_ftp_version 0.3.8 -%global net_imap_version 0.5.1 +%global net_imap_version 0.5.2 %global net_pop_version 0.1.2 %global net_smtp_version 0.5.0 %global nkf_version 0.2.0 @@ -137,14 +134,14 @@ %global racc_version 1.8.1 %global rake_version 13.2.1 %global rbs_version 3.7.0 -%global repl_type_completor_version 0.1.7 +%global repl_type_completor_version 0.1.9 %global resolv_replace_version 0.1.1 -%global rexml_version 3.3.9 +%global rexml_version 3.4.0 %global rinda_version 0.2.0 %global rss_version 0.3.1 -%global syslog_version 0.1.2 -%global test_unit_version 3.6.4 -%global typeprof_version 0.21.11 +%global syslog_version 0.2.0 +%global test_unit_version 3.6.7 +%global typeprof_version 0.30.0 # Bundled nkf version @@ -1861,19 +1858,16 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{_bindir}/typeprof %exclude %{gem_instdir typeprof}/.* %license %{gem_instdir typeprof}/LICENSE -%{gem_instdir typeprof}/exe +%{gem_instdir typeprof}/bin +%doc %{gem_instdir typeprof}/doc %{gem_libdir typeprof} -%doc %{gem_instdir typeprof}/tools -%exclude %{gem_instdir typeprof}/typeprof-lsp %{gem_spec typeprof} -%doc %{gem_instdir typeprof}/Gemfile* %doc %{gem_instdir typeprof}/README.md -%doc %{gem_instdir typeprof}/Rakefile %changelog * Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (3901df708d) +- Upgrade to Ruby 3.4.0 (335bba0fde) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From af738757b14d63beb29c42eba964e50a31161700 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 20 Dec 2024 16:02:58 +0100 Subject: [PATCH 13/18] Fix `OpenSSL::TestSSLSession#test_ctx_client_session_cb_tls13_exception` test This test fails on i686: https://github.com/ruby/openssl/pull/829 --- ruby-3.4.0-ssl-fix-flaky-test-case.patch | 32 ++++++++++++++++++++++++ ruby.spec | 5 ++++ 2 files changed, 37 insertions(+) create mode 100644 ruby-3.4.0-ssl-fix-flaky-test-case.patch diff --git a/ruby-3.4.0-ssl-fix-flaky-test-case.patch b/ruby-3.4.0-ssl-fix-flaky-test-case.patch new file mode 100644 index 0000000..4ff20a6 --- /dev/null +++ b/ruby-3.4.0-ssl-fix-flaky-test-case.patch @@ -0,0 +1,32 @@ +From 210ba0334ad15bf1219ea3c93ac45581c5abc20e Mon Sep 17 00:00:00 2001 +From: Kazuki Yamaguchi +Date: Fri, 20 Dec 2024 20:48:54 +0900 +Subject: [PATCH] ssl: fix flaky test case + test_ctx_client_session_cb_tls13_exception + +In the test case, the client raises an exception in the session_new_cb +and may not cleanly close the connection. Let's ignore exceptions raised +at the server side. + +Fixes: https://github.com/ruby/openssl/issues/828 +--- + test/openssl/test_ssl_session.rb | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/test/openssl/test_ssl_session.rb b/test/openssl/test_ssl_session.rb +index d9b49a20..25ba6a8c 100644 +--- a/test/openssl/test_ssl_session.rb ++++ b/test/openssl/test_ssl_session.rb +@@ -277,7 +277,11 @@ def test_ctx_client_session_cb_tls13_exception + omit "TLS 1.3 not supported" unless tls13_supported? + omit "LibreSSL does not call session_new_cb in TLS 1.3" if libressl? + +- start_server do |port| ++ server_proc = lambda do |ctx, ssl| ++ readwrite_loop(ctx, ssl) ++ rescue SystemCallError, OpenSSL::SSL::SSLError ++ end ++ start_server(server_proc: server_proc) do |port| + ctx = OpenSSL::SSL::SSLContext.new + ctx.min_version = :TLS1_3 + ctx.session_cache_mode = OpenSSL::SSL::SSLContext::SESSION_CACHE_CLIENT diff --git a/ruby.spec b/ruby.spec index 40048d9..49c5820 100644 --- a/ruby.spec +++ b/ruby.spec @@ -280,6 +280,10 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch # Disable syntax_suggest test suite, which tries to download its dependencies. # https://bugs.ruby-lang.org/issues/19297 Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch +# Fix `OpenSSL::TestSSLSession#test_ctx_client_session_cb_tls13_exception` test +# failure on i686. +# https://github.com/ruby/openssl/pull/829 +Patch10: ruby-3.4.0-ssl-fix-flaky-test-case.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} @@ -772,6 +776,7 @@ analysis result in RBS format, a standard type description format for Ruby %patch 4 -p1 %patch 6 -p1 %patch 9 -p1 +%patch 10 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . From 36c09dd4b4093c751e8d0932dabfdfae19918fb0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 23 Dec 2024 10:17:33 +0100 Subject: [PATCH 14/18] Upgrade to Ruby 3.4.0 (a11bb36316) --- ...3.0-Disable-syntax-suggest-test-case.patch | 2 +- ruby-3.4.0-ssl-fix-flaky-test-case.patch | 32 ------------------- ruby.spec | 21 +++++------- 3 files changed, 9 insertions(+), 46 deletions(-) delete mode 100644 ruby-3.4.0-ssl-fix-flaky-test-case.patch diff --git a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch index e82069a..10679ee 100644 --- a/ruby-3.3.0-Disable-syntax-suggest-test-case.patch +++ b/ruby-3.3.0-Disable-syntax-suggest-test-case.patch @@ -12,7 +12,7 @@ diff --git a/common.mk b/common.mk index d55d1788aa..73755f6ccd 100644 --- a/common.mk +++ b/common.mk -@@ -1654,8 +1654,6 @@ no-test-bundled-gems-spec: +@@ -1662,8 +1662,6 @@ no-test-bundled-gems-spec: test-syntax-suggest: diff --git a/ruby-3.4.0-ssl-fix-flaky-test-case.patch b/ruby-3.4.0-ssl-fix-flaky-test-case.patch deleted file mode 100644 index 4ff20a6..0000000 --- a/ruby-3.4.0-ssl-fix-flaky-test-case.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 210ba0334ad15bf1219ea3c93ac45581c5abc20e Mon Sep 17 00:00:00 2001 -From: Kazuki Yamaguchi -Date: Fri, 20 Dec 2024 20:48:54 +0900 -Subject: [PATCH] ssl: fix flaky test case - test_ctx_client_session_cb_tls13_exception - -In the test case, the client raises an exception in the session_new_cb -and may not cleanly close the connection. Let's ignore exceptions raised -at the server side. - -Fixes: https://github.com/ruby/openssl/issues/828 ---- - test/openssl/test_ssl_session.rb | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/test/openssl/test_ssl_session.rb b/test/openssl/test_ssl_session.rb -index d9b49a20..25ba6a8c 100644 ---- a/test/openssl/test_ssl_session.rb -+++ b/test/openssl/test_ssl_session.rb -@@ -277,7 +277,11 @@ def test_ctx_client_session_cb_tls13_exception - omit "TLS 1.3 not supported" unless tls13_supported? - omit "LibreSSL does not call session_new_cb in TLS 1.3" if libressl? - -- start_server do |port| -+ server_proc = lambda do |ctx, ssl| -+ readwrite_loop(ctx, ssl) -+ rescue SystemCallError, OpenSSL::SSL::SSLError -+ end -+ start_server(server_proc: server_proc) do |port| - ctx = OpenSSL::SSL::SSLContext.new - ctx.min_version = :TLS1_3 - ctx.session_cache_mode = OpenSSL::SSL::SSLContext::SESSION_CACHE_CLIENT diff --git a/ruby.spec b/ruby.spec index 49c5820..891cecf 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision 335bba0fde +%global revision a11bb36316 %global ruby_archive %{name}-%{ruby_version} @@ -71,7 +71,7 @@ %global net_http_version 0.6.0 %global net_protocol_version 0.2.2 %global open3_version 0.2.1 -%global openssl_version 3.2.0 +%global openssl_version 3.3.0 %global open_uri_version 0.5.0 %global optparse_version 0.6.0 %global ostruct_version 0.6.1 @@ -116,12 +116,12 @@ %global abbrev_version 0.1.2 %global base64_version 0.2.0 %global bigdecimal_version 3.1.8 -%global csv_version 3.3.1 +%global csv_version 3.3.2 %global debug_version 1.10.0 %global drb_version 2.2.1 %global getoptlong_version 0.2.1 %global net_ftp_version 0.3.8 -%global net_imap_version 0.5.2 +%global net_imap_version 0.5.4 %global net_pop_version 0.1.2 %global net_smtp_version 0.5.0 %global nkf_version 0.2.0 @@ -129,11 +129,11 @@ %global minitest_version 5.25.4 %global mutex_m_version 0.3.0 %global observer_version 0.1.2 -%global power_assert_version 2.0.4 +%global power_assert_version 2.0.5 %global prime_version 0.1.3 %global racc_version 1.8.1 %global rake_version 13.2.1 -%global rbs_version 3.7.0 +%global rbs_version 3.8.0.pre.1 %global repl_type_completor_version 0.1.9 %global resolv_replace_version 0.1.1 %global rexml_version 3.4.0 @@ -280,10 +280,6 @@ Patch6: ruby-2.7.0-Initialize-ABRT-hook.patch # Disable syntax_suggest test suite, which tries to download its dependencies. # https://bugs.ruby-lang.org/issues/19297 Patch9: ruby-3.3.0-Disable-syntax-suggest-test-case.patch -# Fix `OpenSSL::TestSSLSession#test_ctx_client_session_cb_tls13_exception` test -# failure on i686. -# https://github.com/ruby/openssl/pull/829 -Patch10: ruby-3.4.0-ssl-fix-flaky-test-case.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} %{?with_rubypick:Suggests: rubypick} @@ -776,7 +772,6 @@ analysis result in RBS format, a standard type description format for Ruby %patch 4 -p1 %patch 6 -p1 %patch 9 -p1 -%patch 10 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -1871,8 +1866,8 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog -* Thu Dec 19 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (335bba0fde) +* Mon Dec 23 2024 Vít Ondruch - 3.4.0-18 +- Upgrade to Ruby 3.4.0 (a11bb36316) * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. From 4df943f8fa5758fbf990090e17469eaddae6e86d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 2 Jan 2025 12:56:00 +0100 Subject: [PATCH 15/18] Upgrade to Ruby 3.4.1. Resolves: rhbz#2334047 --- ruby.spec | 17 +++++++++-------- sources | 2 +- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/ruby.spec b/ruby.spec index 891cecf..e764e7b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -1,6 +1,6 @@ %global major_version 3 %global minor_version 4 -%global teeny_version 0 +%global teeny_version 1 %global major_minor_version %{major_version}.%{minor_version} %global ruby_version %{major_minor_version}.%{teeny_version} @@ -10,7 +10,7 @@ %dnl %global milestone preview2 # Keep the revision enabled for pre-releases from GIT. -%global revision a11bb36316 +%dnl %global revision 48d4efcb85 %global ruby_archive %{name}-%{ruby_version} @@ -27,7 +27,7 @@ %global rubygems_dir %{_datadir}/rubygems # Bundled libraries versions -%global rubygems_version 3.6.1 +%global rubygems_version 3.6.2 %global rubygems_molinillo_version 0.8.0 %global rubygems_net_http_version 0.6.0 %global rubygems_net_protocol_version 0.2.2 @@ -39,7 +39,7 @@ %global rubygems_uri_version 1.0.2 # Default gems. -%global bundler_version 2.6.1 +%global bundler_version 2.6.2 %global bundler_connection_pool_version 2.4.1 %global bundler_fileutils_version 1.7.3 %global bundler_net_http_persistent_version 4.0.4 @@ -133,7 +133,7 @@ %global prime_version 0.1.3 %global racc_version 1.8.1 %global rake_version 13.2.1 -%global rbs_version 3.8.0.pre.1 +%global rbs_version 3.8.0 %global repl_type_completor_version 0.1.9 %global resolv_replace_version 0.1.1 %global rexml_version 3.4.0 @@ -141,7 +141,7 @@ %global rss_version 0.3.1 %global syslog_version 0.2.0 %global test_unit_version 3.6.7 -%global typeprof_version 0.30.0 +%global typeprof_version 0.30.1 # Bundled nkf version @@ -1866,8 +1866,9 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %changelog -* Mon Dec 23 2024 Vít Ondruch - 3.4.0-18 -- Upgrade to Ruby 3.4.0 (a11bb36316) +* Thu Jan 02 2025 Vít Ondruch - 3.4.1-18 +- Upgrade to Ruby 3.4.1. + Resolves: rhbz#2334047 * Mon Dec 16 2024 Jun Aruga - 3.3.6-18 - Fix Ruby OpenSSL to respect crypto-policies TLS minimal version. diff --git a/sources b/sources index 491b163..504f64b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (ruby-3.3.6.tar.xz) = c4b86188bf539fa737932e1ba5b746bc295e7c43b2f8cca2668eb7c88aa7228e2ce9032bbcd244a7d558a11bc842445b5fbeac3503ca7d223b63c53e08dba4ab +SHA512 (ruby-3.4.1.tar.xz) = 8d2e34117696f9debf463ae1eed288fdbb5c1a12e32800e901b69218e3b7302a0066052077e2ebca851e3a635296199bd5a10437eea1d6f787f69a77bb865680 From b5a9c2685f0f1e17bd03b2b4649aa246c46b7e43 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 2 Jan 2025 19:54:47 +0100 Subject: [PATCH 16/18] Fix `gem install` to generate documentation --- ruby.spec | 15 +++++++++++++++ rubygems_plugin.rb | 23 +++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 rubygems_plugin.rb diff --git a/ruby.spec b/ruby.spec index e764e7b..470caa6 100644 --- a/ruby.spec +++ b/ruby.spec @@ -241,6 +241,10 @@ Source16: rpm_test_helper.rb Source17: test_rubygems_req.rb Source18: test_rubygems_prov.rb Source19: test_rubygems_con.rb +# This file is available in official RDoc 6.9+, while it is missing from +# default RDoc gem as shipped in Ruby tarball. This should not be needed for +# Ruby 3.5+. +Source20: https://github.com/ruby/rdoc/blob/master/lib/rubygems_plugin.rb # The load directive is supported since RPM 4.12, i.e. F21+. The build process # fails on older Fedoras. @@ -896,6 +900,16 @@ popd mkdir -p %{buildroot}%{gem_libdir rdoc} mv %{buildroot}%{ruby_libdir}/rdoc* %{buildroot}%{gem_libdir rdoc} mv %{buildroot}%{gem_spec -d rdoc} %{buildroot}%{gem_spec rdoc} +# Default gem is missing the RubyGems plugin, using various sorts of +# heuristics to workadound this. Restore the plugin to let the documentaion +# generator work properly. This shold not be needed for Ruby 3.5+. +# https://github.com/ruby/rdoc/pull/1171 +# https://github.com/rubygems/rubygems/pull/8340 +# Make sure to not overwrite the file, because it should not exist. +test ! -e %{buildroot}%{gem_libdir rdoc}/%{basename:%{SOURCE20}} +mv %{SOURCE20} %{buildroot}%{gem_libdir rdoc} +echo "require_relative '../gems/rdoc-%{rdoc_version}/lib/rubygems_plugin.rb'" \ + > %{buildroot}%{gem_plugin rdoc} # TODO: Put help files into proper location. # https://bugs.ruby-lang.org/issues/15359 @@ -1513,6 +1527,7 @@ make -C %{_vpath_builddir} runruby TESTRUN_SCRIPT=" \ %{_bindir}/ri %{gem_instdir rdoc} %{gem_spec rdoc} +%{gem_plugin rdoc} %{_mandir}/man1/ri* %files doc -f .ruby-doc.en -f .ruby-doc.ja diff --git a/rubygems_plugin.rb b/rubygems_plugin.rb new file mode 100644 index 0000000..55c75da --- /dev/null +++ b/rubygems_plugin.rb @@ -0,0 +1,23 @@ +# frozen_string_literal: true + +# If this file is exist, RDoc generates and removes documents by rubygems plugins. +# +# In follwing cases, +# RubyGems directly exectute RDoc::RubygemsHook.generation_hook and RDoc::RubygemsHook#remove to generate and remove documents. +# +# - RDoc is used as a default gem. +# - RDoc is a old version that doesn't have rubygems_plugin.rb. + +require_relative 'rdoc/rubygems_hook' + +# To install dependency libraries of RDoc, you need to run bundle install. +# At that time, rdoc/markdown is not generated. +# If generate and remove are executed at that time, an error will occur. +# So, we can't register generate and remove to Gem at that time. +begin + require_relative 'rdoc/markdown' +rescue LoadError +else + Gem.done_installing(&RDoc::RubyGemsHook.method(:generate)) + Gem.pre_uninstall(&RDoc::RubyGemsHook.method(:remove)) +end From f7794c19e14f2ff6bebc89aa6b32449cfb106147 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 3 Jan 2025 15:13:32 +0100 Subject: [PATCH 17/18] Ignore additional `non-executable-script` rpmlint reports. --- ruby.rpmlintrc | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/ruby.rpmlintrc b/ruby.rpmlintrc index 90e14d6..ec8ac11 100644 --- a/ruby.rpmlintrc +++ b/ruby.rpmlintrc @@ -13,15 +13,13 @@ addFilter(r'ruby\.(spec|src):\d+: W: unversioned-explicit-provides bundled\(ccan # The template files do not have to have executable bits. addFilter(r'^rubygem-bundler\.noarch: E: non-executable-script /usr/share/gems/gems/bundler-[\d\.]+/lib/bundler/templates/[\w/\.]+ 644 /usr/bin/env ') +# Samples don't really need executable bits. +addFilter(r'^rubygem-bigdecimal\.x86_64: E: non-executable-script /usr/share/gems/gems/bigdecimal-[\d\.]+/sample/\w+.rb 644 /usr/local/bin/ruby$') + # The bundled gem files permissions are overridden as 644 by `make install`. # https://bugs.ruby-lang.org/issues/17840 # https://github.com/rubygems/rubygems/issues/5255 -# https://github.com/ruby/debug/pull/481 -# https://github.com/ruby/net-ftp/pull/12 -# https://github.com/ruby/net-imap/pull/53 -# https://github.com/ruby/net-pop/pull/7 -# https://github.com/ruby/prime/pull/16 -addFilter(r'^.*: E: non-executable-script /usr/share/gems/gems/(debug|net-(ftp|imap|pop)|prime)-[\d\.]+/bin/\w+ 644 ') +addFilter(r'^.*: E: non-executable-script /usr/share/gems/gems/(abbrev|getoptlong|nkf|observer|resolv|resolv-replace|rinda|syslog)-[\d\.]+/bin/\w+ 644 ') # Ruby provides API to set the cipher list. addFilter(r'^ruby-libs\.\w+: W: crypto-policy-non-compliance-openssl /usr/lib(64)?/ruby/openssl.so SSL_CTX_set_cipher_list$') From 00b4ba04bca73103774f595a236f8ed8db9852e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 3 Jan 2025 17:58:30 +0100 Subject: [PATCH 18/18] Remove the problematic license The code was replaced with new implementation: https://github.com/ruby/json/pull/567 However, there are still new uncertainties about licenses: https://github.com/ruby/json/issues/723 --- ruby.spec | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/ruby.spec b/ruby.spec index 470caa6..733be94 100644 --- a/ruby.spec +++ b/ruby.spec @@ -187,12 +187,6 @@ Release: 18%{?dist} # GPL-1.0-or-later OR Artistic-1.0-Perl: win32/win32.c, include/ruby/win32.h, # ext/win32ole/win32ole.c # -# !!! Problematic licenses: -# LicenseRef-scancode-unicode-mappings: ext/json/generator/generator.c -# https://bugs.ruby-lang.org/issues/11844#note-19 -# https://github.com/flori/json/issues/277 -# https://github.com/flori/json/pull/567 -# # Licenses under review: # .bundle/gems/net-imap-0.4.9/LICENSE.txt # https://gitlab.com/fedora/legal/fedora-license-data/-/issues/506 @@ -537,8 +531,7 @@ provide higher layer features, such like curses and readline. %package -n rubygem-json Summary: This is a JSON implementation as a Ruby extension in C Version: %{json_version} -# Unicode-DFS-2015: ext/json/ext/generator/generator.c -License: (Ruby OR BSD-2-Clause) AND Unicode-DFS-2015 +License: Ruby OR BSD-2-Clause Provides: bundled(rubygem-json) = %{json_version} %description -n rubygem-json