From 023fc73511f0b43fbcff68ba41b44ae7219f8fa2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 23 Feb 2012 09:14:02 +0100 Subject: [PATCH 01/87] Initial .spec for Ruby 2.0.0. --- ...9.3-added-site-and-vendor-arch-flags.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 2 +- ruby-1.9.3-bignum-test-fix.patch | 31 -------------- ruby-1.9.3-mkmf-verbose.patch | 4 +- ruby-1.9.3-webrick-test-fix.patch | 24 ----------- ruby.spec | 42 +++++++++---------- 6 files changed, 24 insertions(+), 81 deletions(-) delete mode 100644 ruby-1.9.3-bignum-test-fix.patch delete mode 100644 ruby-1.9.3-webrick-test-fix.patch diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 1363063..6f217c2 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -43,7 +43,7 @@ index 83e5d76..31532bd 100644 +done + AC_ARG_WITH(vendordir, - AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]]]), + AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], @@ -2820,19 +2829,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 8440ea7..acf60c8 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -40,7 +40,7 @@ index 83e5d76..e6dc38c 100644 +done + AC_ARG_WITH(sitedir, - AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]]]), + AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], @@ -2815,16 +2824,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) diff --git a/ruby-1.9.3-bignum-test-fix.patch b/ruby-1.9.3-bignum-test-fix.patch deleted file mode 100644 index cb3682d..0000000 --- a/ruby-1.9.3-bignum-test-fix.patch +++ /dev/null @@ -1,31 +0,0 @@ ---- ruby-1.9.3-p0/test/ruby/test_bignum.rb.orig 2011-11-10 09:52:59.101925465 +0100 -+++ ruby-1.9.3-p0/test/ruby/test_bignum.rb 2011-11-10 09:54:14.580798826 +0100 -@@ -378,7 +378,7 @@ - assert_equal(true, (2**32).even?) - end - -- def interrupt -+ def assert_interrupt - time = Time.now - start_flag = false - end_flag = false -@@ -387,14 +387,16 @@ - yield - end_flag = true - end -- sleep 1 -+ Thread.pass until start_flag - thread.raise - thread.join rescue nil -- start_flag && !end_flag && Time.now - time < 10 -+ time = Time.now - time -+ assert_equal([true, false], [start_flag, end_flag]) -+ assert_operator(time, :<, 10) - end - - def test_interrupt -- assert(interrupt { (65536 ** 65536).to_s }) -+ assert_interrupt {(65536 ** 65536).to_s} - end - - def test_too_big_to_s diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 7da66c8..f23d6cc 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -1,6 +1,6 @@ --- ruby-1.9.3-p0/lib/mkmf.rb.debug 2011-08-11 15:07:37.000000000 +0900 +++ ruby-1.9.3-p0/lib/mkmf.rb 2012-01-29 21:34:17.000000000 +0900 -@@ -1638,7 +1638,7 @@ +@@ -1701,7 +1701,7 @@ SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. @@ -8,4 +8,4 @@ +V = 1 Q1 = $(V:1=) Q = $(Q1:0=@) - n=$(NULLCMD) + ECHO1 = $(V:1=@#{CONFIG['NULLCMD']}) diff --git a/ruby-1.9.3-webrick-test-fix.patch b/ruby-1.9.3-webrick-test-fix.patch deleted file mode 100644 index c6eb3fa..0000000 --- a/ruby-1.9.3-webrick-test-fix.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/test/webrick/test_cgi.rb b/test/webrick/test_cgi.rb -index 1185316..0ef1b37 100644 ---- a/test/webrick/test_cgi.rb -+++ b/test/webrick/test_cgi.rb -@@ -14,6 +14,7 @@ class TestWEBrickCGI < Test::Unit::TestCase - def req.meta_vars - meta = super - meta["RUBYLIB"] = $:.join(File::PATH_SEPARATOR) -+ meta[RbConfig::CONFIG['LIBPATHENV']] = ENV[RbConfig::CONFIG['LIBPATHENV']] - return meta - end - }, -diff --git a/test/webrick/test_filehandler.rb b/test/webrick/test_filehandler.rb -index bcdb3df..f78ba5c 100644 ---- a/test/webrick/test_filehandler.rb -+++ b/test/webrick/test_filehandler.rb -@@ -252,6 +252,7 @@ class WEBrick::TestFileHandler < Test::Unit::TestCase - def req.meta_vars - meta = super - meta["RUBYLIB"] = $:.join(File::PATH_SEPARATOR) -+ meta[RbConfig::CONFIG['LIBPATHENV']] = ENV[RbConfig::CONFIG['LIBPATHENV']] - return meta - end - }, diff --git a/ruby.spec b/ruby.spec index dd74ad9..75fbf85 100644 --- a/ruby.spec +++ b/ruby.spec @@ -1,13 +1,15 @@ -%global major_version 1 -%global minor_version 9 -%global teeny_version 3 -%global patch_level 125 +%global major_version 2 +%global minor_version 0 +%global teeny_version 0 +%global patch_level 0 %global major_minor_version %{major_version}.%{minor_version} %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_version_patch_level %{major_minor_version}.%{teeny_version}.%{patch_level} -%global ruby_abi %{major_minor_version}.1 +# Keep the ruby abi 1.9.1 for compatibility with gems. +# %global ruby_abi %{major_minor_version}.0 +%global ruby_abi 1.9.1 %global ruby_archive %{name}-%{ruby_version}-p%{patch_level} @@ -44,7 +46,7 @@ %global bigdecimal_version 1.1.0 %global io_console_version 0.3 %global json_version 1.5.4 -%global minitest_version 2.5.1 +%global minitest_version 2.8.1 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/;s/armv.*/arm/') @@ -72,11 +74,6 @@ Patch4: ruby-1.9.3-fix-s390x-build.patch # Fix the uninstaller, so that it doesn't say that gem doesn't exist # when it exists outside of the GEM_HOME (already fixed in the upstream) Patch5: ruby-1.9.3-rubygems-1.8.11-uninstaller.patch -# http://redmine.ruby-lang.org/issues/5135 - see comment 29 -Patch6: ruby-1.9.3-webrick-test-fix.patch -# Already fixed upstream: -# https://github.com/ruby/ruby/commit/f212df564a4e1025f9fb019ce727022a97bfff53 -Patch7: ruby-1.9.3-bignum-test-fix.patch # Allows to install RubyGems into custom directory, outside of Ruby's tree. # http://redmine.ruby-lang.org/issues/5617 Patch8: ruby-1.9.3-custom-rubygems-location.patch @@ -288,6 +285,9 @@ minitest/pride shows pride in testing and adds coloring to your test output. +# TODO: +# %%pacakge -n rubygem-psych + %package tcltk Summary: Tcl/Tk interface for scripting language Ruby Group: Development/Languages @@ -306,8 +306,6 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch3 -p1 %patch4 -p1 %patch5 -p1 -%patch6 -p1 -%patch7 -p1 %patch8 -p1 %patch9 -p1 %patch12 -p1 @@ -373,7 +371,7 @@ mkdir -p %{buildroot}%{rubygems_dir}/rubygems/defaults cp %{SOURCE1} %{buildroot}%{rubygems_dir}/rubygems/defaults # Move gems root into common direcotry, out of Ruby directory structure. -mv %{buildroot}%{ruby_libdir}/gems/%{ruby_abi} %{buildroot}%{gem_dir} +mv %{buildroot}%{ruby_libdir}/gems/2.0.0 %{buildroot}%{gem_dir} # Create folders for gem binary extensions. mkdir -p %{buildroot}%{gem_extdir}/exts @@ -404,31 +402,31 @@ mkdir -p %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib mv %{buildroot}%{ruby_libdir}/minitest %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib # Adjust the gemspec files so that the gems will load properly -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/rake-%{rake_version}.gemspec -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]\ s.extensions = ["bigdecimal.so"]' %{buildroot}/%{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]\ s.extensions = ["io/console.so"]' %{buildroot}/%{gem_dir}/specifications/io-console-%{io_console_version}.gemspec -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]\ s.extensions = ["json/ext/parser.so", "json/ext/generator.so"]' %{buildroot}/%{gem_dir}/specifications/json-%{json_version}.gemspec -sed -i '2 a\ +sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check # TODO: Investigate the test failures. # https://bugs.ruby-lang.org/issues/6036 -make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_parse.rb -x test_x509cert.rb" +make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_x509cert.rb" %post libs -p /sbin/ldconfig @@ -443,7 +441,6 @@ make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_parse.rb -x t %doc NEWS %doc README %lang(ja) %doc README.ja -%doc ToDo %doc doc/ChangeLog-* %doc doc/NEWS-* %{_bindir}/erb @@ -595,6 +592,7 @@ make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_parse.rb -x t %{ruby_libarchdir}/enc/utf_32be.so %{ruby_libarchdir}/enc/utf_32le.so %{ruby_libarchdir}/enc/windows_1251.so +%{ruby_libarchdir}/enc/windows_31j.so %{ruby_libarchdir}/etc.so %{ruby_libarchdir}/fcntl.so %{ruby_libarchdir}/fiber.so From e05ada2daad1e48edb249ca65c36c7c7f4d96c94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 23 Feb 2012 09:28:12 +0100 Subject: [PATCH 02/87] Upgrade to Ruby 2.0.0 (r34723). --- ruby.spec | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ruby.spec b/ruby.spec index 75fbf85..92f6d5b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -696,6 +696,9 @@ make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_x509cert.rb" %{ruby_libdir}/tkextlib %changelog +* Thu Feb 23 2012 Vít Ondruch - 2.0.0.0-1 +- Upgrade to Ruby 2.0.0 (r34723). + * Mon Feb 20 2012 Vít Ondruch - 1.9.3.125-1 - Upgrade to Ruby 1.9.3-p125. From d122868330fdf1489a005444c8de73afe612d54c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 18 Apr 2012 19:40:36 +0200 Subject: [PATCH 03/87] Upgrade to Ruby 2.0.0 (r35368). --- ...9.3-added-site-and-vendor-arch-flags.patch | 31 +++++++++---------- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 18 +++++------ ruby-1.9.3-custom-rubygems-location.patch | 14 ++++----- ruby-1.9.3-disable-versioned-paths.patch | 10 +++--- ruby-1.9.3-mkmf-verbose.patch | 2 +- ruby.spec | 26 ++++++++++++---- 7 files changed, 58 insertions(+), 45 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 6f217c2..cf91b02 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -15,7 +15,7 @@ diff --git a/Makefile.in b/Makefile.in index bcdaf5f..f57e4c4 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -34,6 +34,9 @@ datadir = @datadir@ +@@ -37,6 +37,9 @@ datadir = @datadir@ archdir = @archdir@ sitearch = @sitearch@ sitedir = @sitedir@ @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..31532bd 100644 --- a/configure.in +++ b/configure.in -@@ -2811,6 +2811,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -2866,6 +2866,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 83e5d76..31532bd 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -2820,19 +2829,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -2875,19 +2884,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 83e5d76..31532bd 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -2850,6 +2872,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -2905,12 +2927,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,31 +92,30 @@ index 83e5d76..31532bd 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -2857,6 +2886,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], + ], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" - ]) ++ ]) +AS_CASE(["$RUBY_VENDOR_ARCHLIB_PATH"], + ["$RUBY_LIB_PREFIX/"*], [ + RUBY_VENDOR_ARCHLIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_ARCHLIB_PATH\" : \"$pat\"`"'"' + ], + [ + RUBY_VENDOR_ARCHLIB_PATH="\"${RUBY_VENDOR_ARCHLIB_PATH}\"" -+ ]) + ]) pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], - ["$RUBY_EXEC_PREFIX/"*], [ -@@ -2878,19 +2914,23 @@ if test "x$SITE_DIR" = xno; then - AC_DEFINE(NO_RUBY_SITE_LIB) +@@ -2933,19 +2969,23 @@ if test "x$SITE_DIR" = xno; then + AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else - AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH}) -+ AC_DEFINE_UNQUOTED(RUBY_SITE_ARCHLIB, ${RUBY_SITE_ARCHLIB_PATH}) + AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) ++ AC_DEFINE_UNQUOTED(RUBY_SITE_ARCHLIB, ${RUBY_SITE_ARCHLIB_PATH} !!) fi if test "x$VENDOR_DIR" = xno; then - AC_DEFINE(NO_RUBY_VENDOR_LIB) + AC_DEFINE(NO_RUBY_VENDOR_LIB, [] !!) else - AC_DEFINE_UNQUOTED(RUBY_VENDOR_LIB, ${RUBY_VENDOR_LIB_PATH}) -+ AC_DEFINE_UNQUOTED(RUBY_VENDOR_ARCHLIB, ${RUBY_VENDOR_ARCHLIB_PATH}) + AC_DEFINE_UNQUOTED(RUBY_VENDOR_LIB, ${RUBY_VENDOR_LIB_PATH} !!) ++ AC_DEFINE_UNQUOTED(RUBY_VENDOR_ARCHLIB, ${RUBY_VENDOR_ARCHLIB_PATH} !!) fi AC_SUBST(arch)dnl @@ -170,7 +169,7 @@ diff --git a/version.c b/version.c index 59d4e5e..2558aa0 100644 --- a/version.c +++ b/version.c -@@ -50,8 +50,12 @@ +@@ -51,8 +51,12 @@ #ifndef RUBY_ARCHLIB #define RUBY_ARCHLIB RUBY_LIB "/"RUBY_ARCH #endif diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index f5a8c3d..c7e3b75 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -1,6 +1,6 @@ --- a/configure.in.orig 2011-10-18 08:56:21.587594685 +0200 +++ b/configure.in 2011-10-18 08:56:59.751593321 +0200 -@@ -2935,6 +2935,8 @@ +@@ -2990,6 +2990,8 @@ configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index acf60c8..c5017e3 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -14,7 +14,7 @@ diff --git a/Makefile.in b/Makefile.in index bcdaf5f..d61b2ee 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -31,6 +31,7 @@ libexecdir = @libexecdir@ +@@ -34,6 +34,7 @@ libexecdir = @libexecdir@ datarootdir = @datarootdir@ datadir = @datadir@ arch = @arch@ @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..e6dc38c 100644 --- a/configure.in +++ b/configure.in -@@ -2793,6 +2793,15 @@ else +@@ -2848,6 +2848,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index 83e5d76..e6dc38c 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -2815,16 +2824,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -2870,16 +2879,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,15 +68,15 @@ index 83e5d76..e6dc38c 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -2855,6 +2873,7 @@ else +@@ -2910,6 +2928,7 @@ fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") - AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX}) -+AC_DEFINE_UNQUOTED(RUBY_ARCHLIB, ${RUBY_ARCH_LIB_PATH}) + AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) ++AC_DEFINE_UNQUOTED(RUBY_ARCHLIB, ${RUBY_ARCH_LIB_PATH} !!) if test "x$SITE_DIR" = xno; then - AC_DEFINE(NO_RUBY_SITE_LIB) + AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -2869,6 +2888,7 @@ fi +@@ -2924,6 +2943,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl @@ -117,7 +117,7 @@ diff --git a/version.c b/version.c index 59d4e5e..915a0a2 100644 --- a/version.c +++ b/version.c -@@ -47,7 +47,9 @@ +@@ -48,7 +48,9 @@ #define RUBY_SITE_LIB2 RUBY_SITE_LIB "/"RUBY_LIB_VERSION #define RUBY_VENDOR_LIB2 RUBY_VENDOR_LIB "/"RUBY_LIB_VERSION #endif diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 62d3dad..1db16aa 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index b1bc951..91c5d0d 100644 --- a/configure.in +++ b/configure.in -@@ -2838,6 +2838,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -2893,6 +2893,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index b1bc951..91c5d0d 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -2931,6 +2938,7 @@ AC_SUBST(sitearch)dnl +@@ -2986,6 +2993,7 @@ AC_SUBST(sitearch)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl @@ -53,15 +53,15 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index 6bfc73e..31dc446 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -300,6 +300,7 @@ sitelibdir = CONFIG["sitelibdir"] +@@ -311,6 +311,7 @@ sitelibdir = CONFIG["sitelibdir"] sitearchlibdir = CONFIG["sitearchdir"] vendorlibdir = CONFIG["vendorlibdir"] vendorarchlibdir = CONFIG["vendorarchdir"] +rubygemsdir = CONFIG["rubygemsdir"] - mandir = CONFIG["mandir"] - capidir = CONFIG["docdir"] + mandir = CONFIG["mandir", true] + capidir = CONFIG["docdir", true] configure_args = Shellwords.shellwords(CONFIG["configure_args"]) -@@ -487,7 +488,15 @@ end +@@ -498,7 +499,15 @@ end install?(:local, :comm, :lib) do prepare "library scripts", rubylibdir noinst = %w[README* *.txt *.rdoc] @@ -81,7 +81,7 @@ diff --git a/version.c b/version.c index 59d4e5e..12ba7e9 100644 --- a/version.c +++ b/version.c -@@ -103,6 +103,10 @@ const char ruby_initial_load_paths[] = +@@ -104,6 +104,10 @@ const char ruby_initial_load_paths[] = #endif #endif diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 6d0c5e1..2b7f6fb 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -13,7 +13,7 @@ diff --git a/configure.in b/configure.in index e742e74..86cb68f 100644 --- a/configure.in +++ b/configure.in -@@ -2963,6 +2963,17 @@ else +@@ -3018,6 +3018,17 @@ else fi AC_SUBST(USE_RUBYGEMS) @@ -75,7 +75,7 @@ diff --git a/version.c b/version.c index 59d4e5e..641dc33 100644 --- a/version.c +++ b/version.c -@@ -38,9 +38,15 @@ +@@ -39,9 +39,15 @@ #define RUBY_VENDOR_LIB RUBY_LIB_PREFIX"/vendor_ruby" #endif @@ -91,7 +91,7 @@ index 59d4e5e..641dc33 100644 #define RUBY_ARCHLIB RUBY_LIB "/"RUBY_ARCH #define RUBY_SITE_ARCHLIB RUBY_SITE_LIB2 "/"RUBY_SITEARCH #define RUBY_VENDOR_ARCHLIB RUBY_VENDOR_LIB2 "/"RUBY_SITEARCH -@@ -75,8 +81,10 @@ const char ruby_initial_load_paths[] = +@@ -76,8 +82,10 @@ const char ruby_initial_load_paths[] = RUBY_SITE_THIN_ARCHLIB "\0" #endif RUBY_SITE_ARCHLIB "\0" @@ -102,7 +102,7 @@ index 59d4e5e..641dc33 100644 #ifndef NO_RUBY_VENDOR_LIB RUBY_VENDOR_LIB2 "\0" -@@ -84,8 +92,10 @@ const char ruby_initial_load_paths[] = +@@ -85,8 +93,10 @@ const char ruby_initial_load_paths[] = RUBY_VENDOR_THIN_ARCHLIB "\0" #endif RUBY_VENDOR_ARCHLIB "\0" @@ -135,7 +135,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index cec8c9f..fed14d2 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -379,7 +379,7 @@ end +@@ -390,7 +390,7 @@ end install?(:doc, :rdoc) do if $rdocdir diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index f23d6cc..69e61bd 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -1,6 +1,6 @@ --- ruby-1.9.3-p0/lib/mkmf.rb.debug 2011-08-11 15:07:37.000000000 +0900 +++ ruby-1.9.3-p0/lib/mkmf.rb 2012-01-29 21:34:17.000000000 +0900 -@@ -1701,7 +1701,7 @@ +@@ -1725,7 +1725,7 @@ SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. diff --git a/ruby.spec b/ruby.spec index 92f6d5b..cf6c4c5 100644 --- a/ruby.spec +++ b/ruby.spec @@ -11,7 +11,13 @@ # %global ruby_abi %{major_minor_version}.0 %global ruby_abi 1.9.1 -%global ruby_archive %{name}-%{ruby_version}-p%{patch_level} +# If revision is removed/commented out, the official release build is expected. +# Keep the revision enabled for pre-releases from SVN. +%global revision 35368 + +%global release 1 + +%global ruby_archive %{name}-%{ruby_version}-%{?revision:r%{revision}}%{!?revision:p%{patch_level}} %global ruby_libdir %{_datadir}/%{name} %global ruby_libarchdir %{_libdir}/%{name} @@ -45,7 +51,7 @@ %global rdoc_version 3.9.4 %global bigdecimal_version 1.1.0 %global io_console_version 0.3 -%global json_version 1.5.4 +%global json_version 1.6.6 %global minitest_version 2.8.1 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/;s/armv.*/arm/') @@ -53,7 +59,7 @@ Summary: An interpreter of object-oriented scripting language Name: ruby Version: %{ruby_version_patch_level} -Release: 1%{?dist} +Release: %{?revision:0.}%{release}%{?revision:.r%{revision}}%{?dist} Group: Development/Languages License: Ruby or BSD URL: http://ruby-lang.org/ @@ -425,8 +431,13 @@ sed -i '8 a\ %check # TODO: Investigate the test failures. -# https://bugs.ruby-lang.org/issues/6036 -make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_x509cert.rb" +# OpenSSL 1.0.1 is breaking the drb test suite. +# https://bugs.ruby-lang.org/issues/6221 +# TestTimeTZ failures - Resolved by r35377. +# https://bugs.ruby-lang.org/issues/6318 +# TestWEBrickHTTPRequest and WEBrick::TestFileHandler fail +# https://bugs.ruby-lang.org/issues/6319 +make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb -x test_filehandler.rb" %post libs -p /sbin/ldconfig @@ -696,7 +707,10 @@ make check TESTS="-v -x test_pathname.rb -x test_drbssl.rb -x test_x509cert.rb" %{ruby_libdir}/tkextlib %changelog -* Thu Feb 23 2012 Vít Ondruch - 2.0.0.0-1 +* Wed Apr 18 2012 Vít Ondruch - 2.0.0.0-0.1.r35368 +- Upgrade to Ruby 2.0.0 (r35368). + +* Thu Feb 23 2012 Vít Ondruch - 2.0.0.0-0.1.r34723 - Upgrade to Ruby 2.0.0 (r34723). * Mon Feb 20 2012 Vít Ondruch - 1.9.3.125-1 From e814bd3766dd564162c8fb220b59dcfbd2251c82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 5 Jun 2012 14:52:00 +0200 Subject: [PATCH 04/87] Upgrade to Ruby 2.0.0 (r35922). --- ruby-1.9.3-custom-rubygems-location.patch | 2 +- ruby.spec | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 1db16aa..8ea2162 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -59,7 +59,7 @@ index 6bfc73e..31dc446 100755 vendorarchlibdir = CONFIG["vendorarchdir"] +rubygemsdir = CONFIG["rubygemsdir"] mandir = CONFIG["mandir", true] - capidir = CONFIG["docdir", true] + docdir = CONFIG["docdir", true] configure_args = Shellwords.shellwords(CONFIG["configure_args"]) @@ -498,7 +499,15 @@ end install?(:local, :comm, :lib) do diff --git a/ruby.spec b/ruby.spec index cf6c4c5..e7737a6 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ # If revision is removed/commented out, the official release build is expected. # Keep the revision enabled for pre-releases from SVN. -%global revision 35368 +%global revision 35922 %global release 1 @@ -51,8 +51,8 @@ %global rdoc_version 3.9.4 %global bigdecimal_version 1.1.0 %global io_console_version 0.3 -%global json_version 1.6.6 -%global minitest_version 2.8.1 +%global json_version 1.7.1 +%global minitest_version 3.0.0 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/;s/armv.*/arm/') @@ -523,6 +523,7 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{ruby_libdir}/rss %{ruby_libdir}/shell %{ruby_libdir}/syck +%{ruby_libdir}/syslog %{ruby_libdir}/test %exclude %{ruby_libdir}/tk %exclude %{ruby_libdir}/tkextlib @@ -609,7 +610,6 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{ruby_libarchdir}/fiber.so %{ruby_libarchdir}/fiddle.so %{ruby_libarchdir}/gdbm.so -%{ruby_libarchdir}/iconv.so %dir %{ruby_libarchdir}/io %{ruby_libarchdir}/io/nonblock.so %{ruby_libarchdir}/io/wait.so From 5c90ae31fe0d67aea4781dcc4e7217d629f58acd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 6 Jun 2012 14:19:36 +0200 Subject: [PATCH 05/87] Patch updated to contain !! mark. Moves the RUBYGEMS_DIR macro definition into verconf.h. This change was requested by nobu at https://bugs.ruby-lang.org/issues/5617 --- ruby-1.9.3-custom-rubygems-location.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 8ea2162..24195c7 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -23,7 +23,7 @@ index b1bc951..91c5d0d 100644 + AS_HELP_STRING([--with-rubygemsdir=DIR], [custom rubygems directory]), + [rubygemsdir=$withval]) +if test "$rubygemsdir" != ""; then -+ AC_DEFINE_UNQUOTED(RUBYGEMS_DIR,"$rubygemsdir") ++ AC_DEFINE_UNQUOTED(RUBYGEMS_DIR,"$rubygemsdir" !!) +fi + if test "${LOAD_RELATIVE+set}"; then From 4f02fd5e5044401e25b4cde947dcd4847b3b8f98 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 19 Apr 2012 10:03:22 +0200 Subject: [PATCH 06/87] Remove superfluous slashes. --- ruby.spec | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ruby.spec b/ruby.spec index e7737a6..ffba4ad 100644 --- a/ruby.spec +++ b/ruby.spec @@ -409,25 +409,25 @@ mv %{buildroot}%{ruby_libdir}/minitest %{buildroot}%{gem_dir}/gems/minitest-%{mi # Adjust the gemspec files so that the gems will load properly sed -i '8 a\ - s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/rake-%{rake_version}.gemspec + s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rake-%{rake_version}.gemspec sed -i '8 a\ - s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec + s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec sed -i '8 a\ s.require_paths = ["lib"]\ - s.extensions = ["bigdecimal.so"]' %{buildroot}/%{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec + s.extensions = ["bigdecimal.so"]' %{buildroot}%{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec sed -i '8 a\ s.require_paths = ["lib"]\ - s.extensions = ["io/console.so"]' %{buildroot}/%{gem_dir}/specifications/io-console-%{io_console_version}.gemspec + s.extensions = ["io/console.so"]' %{buildroot}%{gem_dir}/specifications/io-console-%{io_console_version}.gemspec sed -i '8 a\ s.require_paths = ["lib"]\ - s.extensions = ["json/ext/parser.so", "json/ext/generator.so"]' %{buildroot}/%{gem_dir}/specifications/json-%{json_version}.gemspec + s.extensions = ["json/ext/parser.so", "json/ext/generator.so"]' %{buildroot}%{gem_dir}/specifications/json-%{json_version}.gemspec sed -i '8 a\ - s.require_paths = ["lib"]' %{buildroot}/%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec + s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check # TODO: Investigate the test failures. From 07726fdd15a9bf7b7182d293c8e54686442c8b3c Mon Sep 17 00:00:00 2001 From: Bohuslav Kabrda Date: Wed, 30 May 2012 13:46:44 +0200 Subject: [PATCH 07/87] Fix license to contain Public Domain. macros.ruby now contains unexpanded macros. --- ruby.spec | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/ruby.spec b/ruby.spec index ffba4ad..bb079e4 100644 --- a/ruby.spec +++ b/ruby.spec @@ -61,7 +61,8 @@ Name: ruby Version: %{ruby_version_patch_level} Release: %{?revision:0.}%{release}%{?revision:.r%{revision}}%{?dist} Group: Development/Languages -License: Ruby or BSD +# Public Domain for example for: include/ruby/st.h, strftime.c, ... +License: (Ruby or BSD) and Public Domain URL: http://ruby-lang.org/ Source0: ftp://ftp.ruby-lang.org/pub/%{name}/%{major_minor_version}/%{ruby_archive}.tar.gz Source1: operating_system.rb @@ -344,19 +345,19 @@ make install DESTDIR=%{buildroot} # Dump the macros into macro.ruby to use them to build other Ruby libraries. mkdir -p %{buildroot}%{_sysconfdir}/rpm cat >> %{buildroot}%{_sysconfdir}/rpm/macros.ruby << \EOF -%%ruby_libdir %{_datadir}/%{name} -%%ruby_libarchdir %{_libdir}/%{name} +%%ruby_libdir %%{_datadir}/%{name} +%%ruby_libarchdir %%{_libdir}/%{name} # This is the local lib/arch and should not be used for packaging. %%ruby_sitedir site_ruby -%%ruby_sitelibdir %{_prefix}/local/share/ruby/%{ruby_sitedir} -%%ruby_sitearchdir %{_prefix}/local/%{_lib}/ruby/%{ruby_sitedir} +%%ruby_sitelibdir %%{_prefix}/local/share/%{name}/%%{ruby_sitedir} +%%ruby_sitearchdir %%{_prefix}/local/%%{_lib}/%{name}/%%{ruby_sitedir} # This is the general location for libs/archs compatible with all # or most of the Ruby versions available in the Fedora repositories. %%ruby_vendordir vendor_ruby -%%ruby_vendorlibdir %{_datadir}/ruby/%{ruby_vendordir} -%%ruby_vendorarchdir %{_libdir}/ruby/%{ruby_vendordir} +%%ruby_vendorlibdir %%{ruby_libdir}/%%{ruby_vendordir} +%%ruby_vendorarchdir %%{ruby_libarchdir}/%%{ruby_vendordir} EOF cat >> %{buildroot}%{_sysconfdir}/rpm/macros.rubygems << \EOF @@ -707,6 +708,10 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{ruby_libdir}/tkextlib %changelog +* Tue May 29 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 +- Fix license to contain Public Domain. +- macros.ruby now contains unexpanded macros. + * Wed Apr 18 2012 Vít Ondruch - 2.0.0.0-0.1.r35368 - Upgrade to Ruby 2.0.0 (r35368). From efb81c3bcffa1483cf78b0552b6733e2e3605e0d Mon Sep 17 00:00:00 2001 From: Bohuslav Kabrda Date: Mon, 11 Jun 2012 09:29:11 +0200 Subject: [PATCH 08/87] Make symlinks for bigdecimal and io-console gems to ruby stdlib dirs (RHBZ 829209). --- ruby.spec | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/ruby.spec b/ruby.spec index bb079e4..18c428f 100644 --- a/ruby.spec +++ b/ruby.spec @@ -384,6 +384,7 @@ mv %{buildroot}%{ruby_libdir}/gems/2.0.0 %{buildroot}%{gem_dir} mkdir -p %{buildroot}%{gem_extdir}/exts # Move bundled rubygems to %%gem_dir and %%gem_extdir +# make symlinks for io-console and bigdecimal, which are considered to be part of stdlib by other Gems mkdir -p %{buildroot}%{gem_dir}/gems/rake-%{rake_version}/lib mv %{buildroot}%{ruby_libdir}/rake* %{buildroot}%{gem_dir}/gems/rake-%{rake_version}/lib @@ -394,11 +395,15 @@ mkdir -p %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{ruby_libdir}/bigdecimal %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{ruby_libarchdir}/bigdecimal.so %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib +ln -s %{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib/bigdecimal %{buildroot}%{ruby_libdir}/bigdecimal +ln -s %{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib/bigdecimal.so %{buildroot}%{ruby_libarchdir}/bigdecimal.so mkdir -p %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io mv %{buildroot}%{ruby_libdir}/io %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib mv %{buildroot}%{ruby_libarchdir}/io/console.so %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io +ln -s %{gem_dir}/gems/io-console-%{io_console_version}/lib/io %{buildroot}%{ruby_libdir}/io +ln -s %{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io/console.so %{buildroot}%{ruby_libarchdir}/io/console.so mkdir -p %{buildroot}%{gem_dir}/gems/json-%{json_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/json-%{json_version}/lib @@ -680,11 +685,15 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{_datadir}/ri %files -n rubygem-bigdecimal +%{ruby_libdir}/bigdecimal +%{ruby_libarchdir}/bigdecimal.so %{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version} %{gem_dir}/gems/bigdecimal-%{bigdecimal_version} %{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec %files -n rubygem-io-console +%{ruby_libdir}/io +%{ruby_libarchdir}/io/console.so %{_libdir}/gems/exts/io-console-%{io_console_version} %{gem_dir}/gems/io-console-%{io_console_version} %{gem_dir}/specifications/io-console-%{io_console_version}.gemspec @@ -708,6 +717,9 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{ruby_libdir}/tkextlib %changelog +* Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 +- Make symlinks for bigdecimal and io-console gems to ruby stdlib dirs (RHBZ 829209). + * Tue May 29 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Fix license to contain Public Domain. - macros.ruby now contains unexpanded macros. From decd212d2ba25102d08c887804ddc3fab68f6bd7 Mon Sep 17 00:00:00 2001 From: Bohuslav Kabrda Date: Mon, 11 Jun 2012 10:20:53 +0200 Subject: [PATCH 09/87] Make the bigdecimal gem a runtime dependency of Ruby. --- ruby.spec | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ruby.spec b/ruby.spec index 18c428f..9cf6d32 100644 --- a/ruby.spec +++ b/ruby.spec @@ -92,6 +92,11 @@ Patch12: ruby-1.9.3-mkmf-verbose.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} +# Make the bigdecimal gem a runtime dependency of Ruby to avoid problems +# with user-installed gems, that don't require it in gemspec/Gemfile +# See https://bugzilla.redhat.com/show_bug.cgi?id=829209 +# and http://bugs.ruby-lang.org/issues/6123 +Requires: rubygem(bigdecimal) >= %{bigdecimal_version} BuildRequires: autoconf BuildRequires: gdbm-devel @@ -717,6 +722,9 @@ make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb %{ruby_libdir}/tkextlib %changelog +* Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 +- Make the bigdecimal gem a runtime dependency of Ruby. + * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make symlinks for bigdecimal and io-console gems to ruby stdlib dirs (RHBZ 829209). From 421f1d3c9ff77acbe7b07c52301710cb579c479e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 14 Jun 2012 14:56:26 +0200 Subject: [PATCH 10/87] Enable tests and small ARM tweaks. The most of the tests are functional now. The only exception is the one test failing on armv7. Not sure about the PPC though. --- ruby.spec | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/ruby.spec b/ruby.spec index 9cf6d32..3304d64 100644 --- a/ruby.spec +++ b/ruby.spec @@ -54,7 +54,7 @@ %global json_version 1.7.1 %global minitest_version 3.0.0 -%global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/;s/armv.*/arm/') +%global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') Summary: An interpreter of object-oriented scripting language Name: ruby @@ -441,14 +441,17 @@ sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check -# TODO: Investigate the test failures. -# OpenSSL 1.0.1 is breaking the drb test suite. -# https://bugs.ruby-lang.org/issues/6221 -# TestTimeTZ failures - Resolved by r35377. -# https://bugs.ruby-lang.org/issues/6318 -# TestWEBrickHTTPRequest and WEBrick::TestFileHandler fail -# https://bugs.ruby-lang.org/issues/6319 -make check TESTS="-v -x test_drbssl.rb -x test_time_tz.rb -x test_httprequest.rb -x test_filehandler.rb" +DISABLE_TESTS="" + +%ifarch armv7l armv7hl armv7hnl +# test_call_double(DL::TestDL) fails on ARM HardFP +# http://bugs.ruby-lang.org/issues/6592 +DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" +%endif + +%ifnarch ppc ppc64 +make check TESTS="-v $DISABLE_TESTS" +%endif %post libs -p /sbin/ldconfig From bf1a354efc305e34c359f224130d90a77eb98945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Jun 2012 16:54:05 +0200 Subject: [PATCH 11/87] Upgrade to Ruby 2.0.0 (r36169). --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 3304d64..b6edc06 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ # If revision is removed/commented out, the official release build is expected. # Keep the revision enabled for pre-releases from SVN. -%global revision 35922 +%global revision 36169 %global release 1 From a52793dda1b308acec811e34bdcb855aeb594959 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 25 Jun 2012 10:02:24 +0200 Subject: [PATCH 12/87] Upgrade to Ruby 2.0.0 (r36213). --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index b6edc06..d480f28 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ # If revision is removed/commented out, the official release build is expected. # Keep the revision enabled for pre-releases from SVN. -%global revision 36169 +%global revision 36213 %global release 1 From 54ef940f3cafc5479c06813e8937537be9973bbf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 1 Aug 2012 17:25:26 +0200 Subject: [PATCH 13/87] ruby-libs must require rubygems (rhbz#45011). --- ruby.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index d480f28..4bfe1eb 100644 --- a/ruby.spec +++ b/ruby.spec @@ -54,7 +54,7 @@ %global json_version 1.7.1 %global minitest_version 3.0.0 -%global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') +%global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') Summary: An interpreter of object-oriented scripting language Name: ruby @@ -91,7 +91,6 @@ Patch9: rubygems-1.8.11-binary-extensions.patch Patch12: ruby-1.9.3-mkmf-verbose.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} -Requires: ruby(rubygems) >= %{rubygems_version} # Make the bigdecimal gem a runtime dependency of Ruby to avoid problems # with user-installed gems, that don't require it in gemspec/Gemfile # See https://bugzilla.redhat.com/show_bug.cgi?id=829209 @@ -131,6 +130,7 @@ Ruby or an application embedding Ruby. Summary: Libraries necessary to run Ruby Group: Development/Libraries License: Ruby or BSD +Requires: ruby(rubygems) >= %{rubygems_version} Provides: ruby(abi) = %{ruby_abi} %description libs @@ -725,6 +725,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Wed Aug 01 2012 Vít Ondruch - 2.0.0.0-0.1.r35922 +- ruby-libs must require rubygems (rhbz#45011). + * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From 9634afbb69d287f50a1ee5faf77fc9d26e39ceec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 1 Aug 2012 17:26:55 +0200 Subject: [PATCH 14/87] Fixed changelog rhbz reference. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 4bfe1eb..1d4ad16 100644 --- a/ruby.spec +++ b/ruby.spec @@ -726,7 +726,7 @@ make check TESTS="-v $DISABLE_TESTS" %changelog * Wed Aug 01 2012 Vít Ondruch - 2.0.0.0-0.1.r35922 -- ruby-libs must require rubygems (rhbz#45011). +- ruby-libs must require rubygems (rhbz#845011). * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From 000d56dcb68774f8e350ffdad494a8a8baf70ec3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 14 Aug 2012 12:44:33 +0200 Subject: [PATCH 15/87] Revert the dependency of ruby-libs on rubygems (rhbz#845011, rhbz#847482). --- ruby.spec | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ruby.spec b/ruby.spec index 1d4ad16..4387a29 100644 --- a/ruby.spec +++ b/ruby.spec @@ -91,6 +91,7 @@ Patch9: rubygems-1.8.11-binary-extensions.patch Patch12: ruby-1.9.3-mkmf-verbose.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} +Requires: ruby(rubygems) >= %{rubygems_version} # Make the bigdecimal gem a runtime dependency of Ruby to avoid problems # with user-installed gems, that don't require it in gemspec/Gemfile # See https://bugzilla.redhat.com/show_bug.cgi?id=829209 @@ -130,7 +131,6 @@ Ruby or an application embedding Ruby. Summary: Libraries necessary to run Ruby Group: Development/Libraries License: Ruby or BSD -Requires: ruby(rubygems) >= %{rubygems_version} Provides: ruby(abi) = %{ruby_abi} %description libs @@ -725,9 +725,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Wed Aug 01 2012 Vít Ondruch - 2.0.0.0-0.1.r35922 -- ruby-libs must require rubygems (rhbz#845011). - * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From 7ef1432815c619d7cbcd0dc448d87fdd23306abb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 3 Sep 2012 14:44:25 +0200 Subject: [PATCH 16/87] Upgrade to Ruby 2.0.0 (r36887). --- ...0-r36832-rb_float_value-optimization.patch | 46 +++++++++++++++++++ ruby.spec | 15 ++++-- 2 files changed, 57 insertions(+), 4 deletions(-) create mode 100644 ruby-2.0-r36832-rb_float_value-optimization.patch diff --git a/ruby-2.0-r36832-rb_float_value-optimization.patch b/ruby-2.0-r36832-rb_float_value-optimization.patch new file mode 100644 index 0000000..97dc58b --- /dev/null +++ b/ruby-2.0-r36832-rb_float_value-optimization.patch @@ -0,0 +1,46 @@ +From 0b89d6d5f9f8c788f4391d8a0499f10aed624371 Mon Sep 17 00:00:00 2001 +From: ko1 +Date: Mon, 27 Aug 2012 09:22:21 +0000 +Subject: [PATCH] * include/ruby/ruby.h (rb_float_value): optimize it. This + technique was pointed by shinichiro.hamaji + . + +git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e +--- + ChangeLog | 6 ++++++ + include/ruby/ruby.h | 10 +++++----- + 2 files changed, 11 insertions(+), 5 deletions(-) + +diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h +index 3905b32..b8b2267 100644 +--- a/include/ruby/ruby.h ++++ b/include/ruby/ruby.h +@@ -733,10 +733,7 @@ struct RFloat { + rb_float_value(VALUE v) + { + if (FLONUM_P(v)) { +- if (v == (VALUE)0x8000000000000002) { +- return 0.0; +- } +- else { ++ if (v != (VALUE)0x8000000000000002) { /* LIKELY */ + union { + double d; + VALUE v; +@@ -746,9 +743,12 @@ struct RFloat { + /* e: xx1... -> 011... */ + /* xx0... -> 100... */ + /* ^b63 */ +- t.v = RUBY_BIT_ROTR(((b63 ^ 1) << 1) | b63 | (v & ~0x03), 3); ++ t.v = RUBY_BIT_ROTR(2 - b63 | (v & ~0x03), 3); + return t.d; + } ++ else { ++ return 0.0; ++ } + } + else { + return ((struct RFloat *)v)->float_value; +-- +1.7.10 + diff --git a/ruby.spec b/ruby.spec index 4387a29..5342056 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ # If revision is removed/commented out, the official release build is expected. # Keep the revision enabled for pre-releases from SVN. -%global revision 36213 +%global revision 36887 %global release 1 @@ -52,7 +52,7 @@ %global bigdecimal_version 1.1.0 %global io_console_version 0.3 %global json_version 1.7.1 -%global minitest_version 3.0.0 +%global minitest_version 3.3.0 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -90,6 +90,10 @@ Patch9: rubygems-1.8.11-binary-extensions.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch +# This patch breaks a test suite, so revert it for now. +# https://bugs.ruby-lang.org/issues/6971 +Patch100: ruby-2.0-r36832-rb_float_value-optimization.patch + Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} # Make the bigdecimal gem a runtime dependency of Ruby to avoid problems @@ -322,6 +326,8 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch9 -p1 %patch12 -p1 +%patch100 -p1 -R + %build autoconf @@ -536,7 +542,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/ripper %{ruby_libdir}/rss %{ruby_libdir}/shell -%{ruby_libdir}/syck %{ruby_libdir}/syslog %{ruby_libdir}/test %exclude %{ruby_libdir}/tk @@ -645,7 +650,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libarchdir}/socket.so %{ruby_libarchdir}/stringio.so %{ruby_libarchdir}/strscan.so -%{ruby_libarchdir}/syck.so %{ruby_libarchdir}/syslog.so %exclude %{ruby_libarchdir}/tcltklib.so %exclude %{ruby_libarchdir}/tkutil.so @@ -725,6 +729,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Mon Sep 03 2012 Vít Ondruch - 2.0.0.0-0.2.r36887 +- Upgrade to Ruby 2.0.0 (r36887). + * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From a1b8ff803d4f6cecc3cae7121dee81552862ab7c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 6 Sep 2012 09:28:09 +0200 Subject: [PATCH 17/87] Update TODO about rubygems-filesystem. --- ruby.spec | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 5342056..7e0c9f5 100644 --- a/ruby.spec +++ b/ruby.spec @@ -41,7 +41,9 @@ # Specify custom RubyGems root. %global gem_dir %{_datadir}/gems -# TODO: Should we create arch specific rubygems-filesystem? +# TODO: These folders should go into rubygem-filesystem but how to achieve it, +# since noarch package cannot provide arch dependent subpackages? +# http://rpm.org/ticket/78 %global gem_extdir %{_exec_prefix}/lib{,64}/gems %global rake_version 0.9.2.2 From 8fbe4def8e85727c7f76ec5e8852a1ae2a6100ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 6 Sep 2012 14:20:29 +0200 Subject: [PATCH 18/87] Split documentation into -doc subpackage. --- ruby.spec | 35 ++++++++++++++++++++++++----------- 1 file changed, 24 insertions(+), 11 deletions(-) diff --git a/ruby.spec b/ruby.spec index 7e0c9f5..369e537 100644 --- a/ruby.spec +++ b/ruby.spec @@ -215,16 +215,26 @@ Provides: ri = %{version}-%{release} Provides: rubygem(rdoc) = %{version}-%{release} Obsoletes: ruby-rdoc < %{version} Obsoletes: ruby-ri < %{version} +BuildArch: noarch + +%description -n rubygem-rdoc +RDoc produces HTML and command-line documentation for Ruby projects. RDoc +includes the 'rdoc' and 'ri' tools for generating and displaying online +documentation. + + +%package doc +Summary: Documentation for %{name} +Group: Documentation +Requires: %{_bindir}/ri # TODO: It seems that ri documentation differs from platform to platform due to # some encoding bugs, therefore the documentation should be split out of this gem # or kept platform specific. # https://github.com/rdoc/rdoc/issues/71 # BuildArch: noarch -%description -n rubygem-rdoc -RDoc produces HTML and command-line documentation for Ruby projects. RDoc -includes the 'rdoc' and 'ri' tools for generating and displaying online -documentation. +%description doc +This package contains documentation for %{name}. %package -n rubygem-bigdecimal @@ -468,14 +478,8 @@ make check TESTS="-v $DISABLE_TESTS" %files %doc COPYING %lang(ja) %doc COPYING.ja -%doc ChangeLog %doc GPL %doc LEGAL -%doc NEWS -%doc README -%lang(ja) %doc README.ja -%doc doc/ChangeLog-* -%doc doc/NEWS-* %{_bindir}/erb %{_bindir}/ruby %{_bindir}/testrb @@ -696,6 +700,14 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir}/gems/rdoc-%{rdoc_version} %{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec %{_mandir}/man1/ri* + +%files doc +%doc NEWS +%doc README +%lang(ja) %doc README.ja +%doc ChangeLog +%doc doc/ChangeLog-* +%doc doc/NEWS-* %{_datadir}/ri %files -n rubygem-bigdecimal @@ -731,8 +743,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Mon Sep 03 2012 Vít Ondruch - 2.0.0.0-0.2.r36887 +* Thu Sep 06 2012 Vít Ondruch - 2.0.0.0-0.2.r36887 - Upgrade to Ruby 2.0.0 (r36887). +- Split documentation into -doc subpackage. * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From d5f9a821134a70d07c92b83c46f972e4dc50877c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 7 Sep 2012 09:31:41 +0200 Subject: [PATCH 19/87] Added bugzilla issue number. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 369e537..d0bd7ab 100644 --- a/ruby.spec +++ b/ruby.spec @@ -745,7 +745,7 @@ make check TESTS="-v $DISABLE_TESTS" %changelog * Thu Sep 06 2012 Vít Ondruch - 2.0.0.0-0.2.r36887 - Upgrade to Ruby 2.0.0 (r36887). -- Split documentation into -doc subpackage. +- Split documentation into -doc subpackage (rhbz#854418). * Mon Jun 11 2012 Bohuslav Kabrda - 2.0.0.0-0.1.r35922 - Make the bigdecimal gem a runtime dependency of Ruby. From 205d789f2ef02756d60432467b56490815f456e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 18 Oct 2012 07:28:23 +0200 Subject: [PATCH 20/87] Move NEWS to the main package. --- ruby.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index d0bd7ab..8638d03 100644 --- a/ruby.spec +++ b/ruby.spec @@ -513,6 +513,8 @@ make check TESTS="-v $DISABLE_TESTS" %doc LEGAL %doc README %lang(ja) %doc README.ja +%doc NEWS +%doc doc/NEWS-* # Exclude /usr/local directory since it is supposed to be managed by # local system administrator. %exclude %{ruby_sitelibdir} @@ -702,12 +704,10 @@ make check TESTS="-v $DISABLE_TESTS" %{_mandir}/man1/ri* %files doc -%doc NEWS %doc README %lang(ja) %doc README.ja %doc ChangeLog %doc doc/ChangeLog-* -%doc doc/NEWS-* %{_datadir}/ri %files -n rubygem-bigdecimal From 51eee225227a7c82f99af851578eec1edf9ddd83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 5 Nov 2012 16:38:52 +0100 Subject: [PATCH 21/87] Upgrade to Ruby 2.0.0 (r37421). --- ...9.3-added-site-and-vendor-arch-flags.patch | 10 ++++---- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 10 ++++---- ruby-1.9.3-custom-rubygems-location.patch | 8 +++---- ruby-1.9.3-disable-versioned-paths.patch | 4 ++-- ruby-1.9.3-mkmf-verbose.patch | 2 +- ruby.spec | 19 ++++++++------- rubygems-1.8.11-binary-extensions.patch | 24 +++++++++---------- 8 files changed, 40 insertions(+), 39 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index cf91b02..add7b38 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -15,7 +15,7 @@ diff --git a/Makefile.in b/Makefile.in index bcdaf5f..f57e4c4 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -37,6 +37,9 @@ datadir = @datadir@ +@@ -38,6 +38,9 @@ datadir = @datadir@ archdir = @archdir@ sitearch = @sitearch@ sitedir = @sitedir@ @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..31532bd 100644 --- a/configure.in +++ b/configure.in -@@ -2866,6 +2866,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3028,6 +3028,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 83e5d76..31532bd 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -2875,19 +2884,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3037,19 +3046,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 83e5d76..31532bd 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -2905,12 +2927,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3067,12 +3089,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -105,7 +105,7 @@ index 83e5d76..31532bd 100644 ]) pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], -@@ -2933,19 +2969,23 @@ if test "x$SITE_DIR" = xno; then +@@ -3095,19 +3131,23 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index c7e3b75..5eecdbf 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -1,6 +1,6 @@ --- a/configure.in.orig 2011-10-18 08:56:21.587594685 +0200 +++ b/configure.in 2011-10-18 08:56:59.751593321 +0200 -@@ -2990,6 +2990,8 @@ +@@ -3152,6 +3152,8 @@ configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index c5017e3..3088602 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -14,7 +14,7 @@ diff --git a/Makefile.in b/Makefile.in index bcdaf5f..d61b2ee 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -34,6 +34,7 @@ libexecdir = @libexecdir@ +@@ -35,6 +35,7 @@ libexecdir = @libexecdir@ datarootdir = @datarootdir@ datadir = @datadir@ arch = @arch@ @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..e6dc38c 100644 --- a/configure.in +++ b/configure.in -@@ -2848,6 +2848,15 @@ else +@@ -3010,6 +3010,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index 83e5d76..e6dc38c 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -2870,16 +2879,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3032,16 +3041,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index 83e5d76..e6dc38c 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -2910,6 +2928,7 @@ +@@ -3072,6 +3090,7 @@ fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index 83e5d76..e6dc38c 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -2924,6 +2943,7 @@ fi +@@ -3086,6 +3105,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 24195c7..d79d54c 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index b1bc951..91c5d0d 100644 --- a/configure.in +++ b/configure.in -@@ -2893,6 +2893,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3055,6 +3055,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index b1bc951..91c5d0d 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -2986,6 +2993,7 @@ AC_SUBST(sitearch)dnl +@@ -3148,6 +3155,7 @@ AC_SUBST(sitearch)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl @@ -53,7 +53,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index 6bfc73e..31dc446 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -311,6 +311,7 @@ sitelibdir = CONFIG["sitelibdir"] +@@ -313,6 +313,7 @@ sitelibdir = CONFIG["sitelibdir"] sitearchlibdir = CONFIG["sitearchdir"] vendorlibdir = CONFIG["vendorlibdir"] vendorarchlibdir = CONFIG["vendorarchdir"] @@ -61,7 +61,7 @@ index 6bfc73e..31dc446 100755 mandir = CONFIG["mandir", true] docdir = CONFIG["docdir", true] configure_args = Shellwords.shellwords(CONFIG["configure_args"]) -@@ -498,7 +499,15 @@ end +@@ -500,7 +501,15 @@ end install?(:local, :comm, :lib) do prepare "library scripts", rubylibdir noinst = %w[README* *.txt *.rdoc] diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 2b7f6fb..648f4c3 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -13,7 +13,7 @@ diff --git a/configure.in b/configure.in index e742e74..86cb68f 100644 --- a/configure.in +++ b/configure.in -@@ -3018,6 +3018,17 @@ else +@@ -3177,6 +3177,17 @@ else fi AC_SUBST(USE_RUBYGEMS) @@ -135,7 +135,7 @@ diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index cec8c9f..fed14d2 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb -@@ -390,7 +390,7 @@ end +@@ -392,7 +392,7 @@ end install?(:doc, :rdoc) do if $rdocdir diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 69e61bd..729ee80 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -1,6 +1,6 @@ --- ruby-1.9.3-p0/lib/mkmf.rb.debug 2011-08-11 15:07:37.000000000 +0900 +++ ruby-1.9.3-p0/lib/mkmf.rb 2012-01-29 21:34:17.000000000 +0900 -@@ -1725,7 +1725,7 @@ +@@ -1746,7 +1746,7 @@ SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. diff --git a/ruby.spec b/ruby.spec index 8638d03..c88c8d7 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ # If revision is removed/commented out, the official release build is expected. # Keep the revision enabled for pre-releases from SVN. -%global revision 36887 +%global revision 37421 %global release 1 @@ -54,7 +54,7 @@ %global bigdecimal_version 1.1.0 %global io_console_version 0.3 %global json_version 1.7.1 -%global minitest_version 3.3.0 +%global minitest_version 3.4.0 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -92,10 +92,6 @@ Patch9: rubygems-1.8.11-binary-extensions.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch -# This patch breaks a test suite, so revert it for now. -# https://bugs.ruby-lang.org/issues/6971 -Patch100: ruby-2.0-r36832-rb_float_value-optimization.patch - Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} # Make the bigdecimal gem a runtime dependency of Ruby to avoid problems @@ -316,6 +312,10 @@ output. # TODO: # %%pacakge -n rubygem-psych +# TODO: +# %%pacakge -n rubygem-test-unit + + %package tcltk Summary: Tcl/Tk interface for scripting language Ruby Group: Development/Languages @@ -338,8 +338,6 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch9 -p1 %patch12 -p1 -%patch100 -p1 -R - %build autoconf @@ -743,7 +741,10 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Thu Sep 06 2012 Vít Ondruch - 2.0.0.0-0.2.r36887 +* Mon Nov 05 2012 Vít Ondruch - 2.0.0.0-0.1.r37421 +- Upgrade to Ruby 2.0.0 (r37421). + +* Thu Sep 06 2012 Vít Ondruch - 2.0.0.0-0.1.r36887 - Upgrade to Ruby 2.0.0 (r36887). - Split documentation into -doc subpackage (rhbz#854418). diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index 5a3bfb4..b3a5697 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -11,7 +11,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 97db19e..263e7d3 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -843,6 +843,12 @@ class Gem::Specification +@@ -859,6 +859,12 @@ class Gem::Specification File.join full_gem_path, path end @@ -24,7 +24,7 @@ index 97db19e..263e7d3 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -954,16 +960,16 @@ class Gem::Specification +@@ -970,16 +976,16 @@ class Gem::Specification def contains_requirable_file? file root = full_gem_path @@ -48,7 +48,7 @@ index 97db19e..263e7d3 100644 end ## -@@ -1273,6 +1279,23 @@ class Gem::Specification +@@ -1295,6 +1301,23 @@ class Gem::Specification end ## @@ -90,7 +90,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 74d803d..0063c7f 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -499,7 +499,7 @@ TEXT +@@ -509,7 +509,7 @@ TEXT def build_extensions return if spec.extensions.empty? say "Building native extensions. This could take a while..." @@ -103,7 +103,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 263e7d3..d31b93b 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1283,16 +1283,15 @@ class Gem::Specification +@@ -1305,16 +1305,15 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -140,7 +140,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index d31b93b..e65ea2d 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -843,11 +843,7 @@ class Gem::Specification +@@ -859,11 +859,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -153,7 +153,7 @@ index d31b93b..e65ea2d 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1291,7 +1287,10 @@ class Gem::Specification +@@ -1313,7 +1309,10 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir @@ -183,7 +183,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 0063c7f..83b8fd5 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -499,7 +499,7 @@ TEXT +@@ -509,7 +509,7 @@ TEXT def build_extensions return if spec.extensions.empty? say "Building native extensions. This could take a while..." @@ -196,7 +196,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index e65ea2d..8be2ade 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -843,7 +843,7 @@ class Gem::Specification +@@ -859,7 +859,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -205,7 +205,7 @@ index e65ea2d..8be2ade 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1279,7 +1279,7 @@ class Gem::Specification +@@ -1301,7 +1301,7 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -257,7 +257,7 @@ diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb index 20b4198..6d8711f 100644 --- a/lib/rubygems/defaults.rb +++ b/lib/rubygems/defaults.rb -@@ -87,6 +87,17 @@ module Gem +@@ -94,6 +94,17 @@ module Gem end ## @@ -279,7 +279,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 8be2ade..f54210a 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1287,10 +1287,7 @@ class Gem::Specification +@@ -1309,10 +1309,7 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir From 6fb463f87d6ad7a133e50c497897ccfa6e904fa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 5 Nov 2012 16:39:11 +0100 Subject: [PATCH 22/87] Update infrastructure to allow build of versioned releases. This will allow to build releases such as preview1 or rc1. --- ruby.spec | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/ruby.spec b/ruby.spec index c88c8d7..bd45f56 100644 --- a/ruby.spec +++ b/ruby.spec @@ -7,17 +7,28 @@ %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_version_patch_level %{major_minor_version}.%{teeny_version}.%{patch_level} -# Keep the ruby abi 1.9.1 for compatibility with gems. -# %global ruby_abi %{major_minor_version}.0 +# Ruby 2.0 keeps the abi Ruby 1.9.1 compatible. +# %%global ruby_abi %%{major_minor_version}.0 %global ruby_abi 1.9.1 -# If revision is removed/commented out, the official release build is expected. +# Specify the named version. It has precedense to revision. +#%%global milestone preview1 + # Keep the revision enabled for pre-releases from SVN. %global revision 37421 -%global release 1 +%global ruby_archive %{name}-%{ruby_version} -%global ruby_archive %{name}-%{ruby_version}-%{?revision:r%{revision}}%{!?revision:p%{patch_level}} +# If revision and milestone are removed/commented out, the official release build is expected. +%if 0%{?milestone:1}%{?revision:1} != 0 +%global development_release %{?milestone}%{?!milestone:%{?revision:r%{revision}}} +%global ruby_archive %{ruby_archive}-%{?milestone}%{?!milestone:%{?revision:r%{revision}}} +%else +%global ruby_archive %{ruby_archive}-p%{patch_level} +%endif + + +%global release 1 %global ruby_libdir %{_datadir}/%{name} %global ruby_libarchdir %{_libdir}/%{name} @@ -61,7 +72,7 @@ Summary: An interpreter of object-oriented scripting language Name: ruby Version: %{ruby_version_patch_level} -Release: %{?revision:0.}%{release}%{?revision:.r%{revision}}%{?dist} +Release: %{?development_release:0.}%{release}%{?development_release:.%{development_release}}%{?dist} Group: Development/Languages # Public Domain for example for: include/ruby/st.h, strftime.c, ... License: (Ruby or BSD) and Public Domain From 22208df0f54a64cb56f6aa55cab86bd743008401 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 6 Nov 2012 13:22:34 +0100 Subject: [PATCH 23/87] Remove useless dot from Summary. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index bd45f56..ccd04a0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -296,7 +296,7 @@ markup language. %package -n rubygem-minitest -Summary: Minitest provides a complete suite of testing facilities. +Summary: Minitest provides a complete suite of testing facilities Version: %{minitest_version} Group: Development/Libraries License: MIT From 3b7600597c2d35364c3d6725a36926965217f8f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 6 Nov 2012 13:25:16 +0100 Subject: [PATCH 24/87] Split Psych into rubygem-psych subpackage. --- ruby.spec | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/ruby.spec b/ruby.spec index ccd04a0..e956ef1 100644 --- a/ruby.spec +++ b/ruby.spec @@ -66,6 +66,7 @@ %global io_console_version 0.3 %global json_version 1.7.1 %global minitest_version 3.4.0 +%global psych_version 1.3.4 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -320,8 +321,20 @@ minitest/pride shows pride in testing and adds coloring to your test output. -# TODO: -# %%pacakge -n rubygem-psych +%package -n rubygem-psych +Summary: A libyaml wrapper for Ruby +Version: %{psych_version} +Group: Development/Libraries +License: MIT +Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(rubygems) >= %{rubygems_version} +Provides: rubygem(psych) = %{version}-%{release} + +%description -n rubygem-psych +Psych is a YAML parser and emitter. Psych leverages +libyaml[http://pyyaml.org/wiki/LibYAML] for its YAML parsing and emitting +capabilities. In addition to wrapping libyaml, Psych also knows how to +serialize and de-serialize most Ruby objects to and from the YAML format. # TODO: # %%pacakge -n rubygem-test-unit @@ -445,6 +458,11 @@ mv %{buildroot}%{ruby_libarchdir}/json/ %{buildroot}%{_libdir}/gems/exts/json-%{ mkdir -p %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib mv %{buildroot}%{ruby_libdir}/minitest %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib +mkdir -p %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib +mkdir -p %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib +mv %{buildroot}%{ruby_libdir}/psych* %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib +mv %{buildroot}%{ruby_libarchdir}/psych.so %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib/ + # Adjust the gemspec files so that the gems will load properly sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rake-%{rake_version}.gemspec @@ -551,7 +569,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/net %{ruby_libdir}/openssl %{ruby_libdir}/optparse -%{ruby_libdir}/psych %{ruby_libdir}/racc %{ruby_libdir}/rbconfig %{ruby_libdir}/rexml @@ -656,7 +673,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libarchdir}/objspace.so %{ruby_libarchdir}/openssl.so %{ruby_libarchdir}/pathname.so -%{ruby_libarchdir}/psych.so %{ruby_libarchdir}/pty.so %dir %{ruby_libarchdir}/racc %{ruby_libarchdir}/racc/cparse.so @@ -681,6 +697,7 @@ make check TESTS="-v $DISABLE_TESTS" %exclude %{_exec_prefix}/lib*/gems/exts/bigdecimal-%{bigdecimal_version} %exclude %{_exec_prefix}/lib*/gems/exts/io-console-%{io_console_version} %exclude %{_exec_prefix}/lib*/gems/exts/json-%{json_version} +%exclude %{_exec_prefix}/lib*/gems/exts/psych-%{psych_version} %exclude %{gem_dir}/gems/rake-%{rake_version} %exclude %{gem_dir}/gems/rdoc-%{rdoc_version} %exclude %{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec @@ -689,6 +706,7 @@ make check TESTS="-v $DISABLE_TESTS" %exclude %{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %exclude %{gem_dir}/specifications/rake-%{rake_version}.gemspec %exclude %{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec +%exclude %{gem_dir}/specifications/psych-%{psych_version}.gemspec %files -n rubygems-devel %config(noreplace) %{_sysconfdir}/rpm/macros.rubygems @@ -742,6 +760,11 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir}/gems/minitest-%{minitest_version} %{gem_dir}/specifications/minitest-%{minitest_version}.gemspec +%files -n rubygem-psych +%{_libdir}/gems/exts/psych-%{psych_version} +%{gem_dir}/gems/psych-%{psych_version} +%{gem_dir}/specifications/psych-%{psych_version}.gemspec + %files tcltk %{ruby_libdir}/*-tk.rb %{ruby_libdir}/tcltk.rb @@ -754,6 +777,7 @@ make check TESTS="-v $DISABLE_TESTS" %changelog * Mon Nov 05 2012 Vít Ondruch - 2.0.0.0-0.1.r37421 - Upgrade to Ruby 2.0.0 (r37421). +- Split Psych into rubygem-psych subpackage. * Thu Sep 06 2012 Vít Ondruch - 2.0.0.0-0.1.r36887 - Upgrade to Ruby 2.0.0 (r36887). From e1246b9377ff32111e630e9f21c3978c7f1945be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 7 Nov 2012 10:17:44 +0100 Subject: [PATCH 25/87] RubyGems needs psych for proper functionality. It is not 100% clear, if RubyGems are the best place to require psych, but lets see how it will work. In the future, it might get moved into ruby-libs if needed, but it doesn't look like it should be there ATM, since it would be unnecessary payload. --- ruby.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/ruby.spec b/ruby.spec index e956ef1..a896002 100644 --- a/ruby.spec +++ b/ruby.spec @@ -159,6 +159,7 @@ License: Ruby or MIT Requires: ruby(abi) = %{ruby_abi} Requires: rubygem(rdoc) >= %{rdoc_version} Requires: rubygem(io-console) >= %{io_console_version} +Requires: rubygem(psych) >= %{psych_version} Provides: gem = %{version}-%{release} Provides: ruby(rubygems) = %{version}-%{release} BuildArch: noarch From 25904a94467425d4423e8783179c432880e53945 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 16 Nov 2012 11:54:32 +0100 Subject: [PATCH 26/87] Upgrade to Ruby 2.0.0 (r37589). --- ruby-1.9.3-added-site-and-vendor-arch-flags.patch | 8 ++++---- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 8 ++++---- ruby-1.9.3-custom-rubygems-location.patch | 4 ++-- ruby-1.9.3-disable-versioned-paths.patch | 2 +- ruby.spec | 9 +++++++-- 6 files changed, 19 insertions(+), 14 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index add7b38..cbed3a6 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..31532bd 100644 --- a/configure.in +++ b/configure.in -@@ -3028,6 +3028,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3029,6 +3029,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 83e5d76..31532bd 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3037,19 +3046,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3038,19 +3047,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 83e5d76..31532bd 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3067,12 +3089,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3068,12 +3090,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -105,7 +105,7 @@ index 83e5d76..31532bd 100644 ]) pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], -@@ -3095,19 +3131,23 @@ if test "x$SITE_DIR" = xno; then +@@ -3096,19 +3132,23 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index 5eecdbf..2c9ca1e 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -1,6 +1,6 @@ --- a/configure.in.orig 2011-10-18 08:56:21.587594685 +0200 +++ b/configure.in 2011-10-18 08:56:59.751593321 +0200 -@@ -3152,6 +3152,8 @@ +@@ -3153,6 +3153,8 @@ configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 3088602..ab18fdd 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index 83e5d76..e6dc38c 100644 --- a/configure.in +++ b/configure.in -@@ -3010,6 +3010,15 @@ else +@@ -3011,6 +3011,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index 83e5d76..e6dc38c 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3032,16 +3041,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3033,16 +3042,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index 83e5d76..e6dc38c 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3072,6 +3090,7 @@ +@@ -3073,6 +3091,7 @@ fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index 83e5d76..e6dc38c 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3086,6 +3105,7 @@ fi +@@ -3087,6 +3106,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index d79d54c..c13ca34 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index b1bc951..91c5d0d 100644 --- a/configure.in +++ b/configure.in -@@ -3055,6 +3055,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3056,6 +3056,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index b1bc951..91c5d0d 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3148,6 +3155,7 @@ AC_SUBST(sitearch)dnl +@@ -3149,6 +3156,7 @@ AC_SUBST(sitearch)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 648f4c3..b8ac37a 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -13,7 +13,7 @@ diff --git a/configure.in b/configure.in index e742e74..86cb68f 100644 --- a/configure.in +++ b/configure.in -@@ -3177,6 +3177,17 @@ else +@@ -3178,6 +3178,17 @@ else fi AC_SUBST(USE_RUBYGEMS) diff --git a/ruby.spec b/ruby.spec index a896002..4fa5f96 100644 --- a/ruby.spec +++ b/ruby.spec @@ -15,7 +15,7 @@ #%%global milestone preview1 # Keep the revision enabled for pre-releases from SVN. -%global revision 37421 +%global revision 37589 %global ruby_archive %{name}-%{ruby_version} @@ -487,7 +487,9 @@ sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check -DISABLE_TESTS="" +# http://bugs.ruby-lang.org/issues/7298 +# http://bugs.ruby-lang.org/issues/7312 +DISABLE_TESTS="-x test_enumerator.rb -x test_m17n_comb.rb" %ifarch armv7l armv7hl armv7hnl # test_call_double(DL::TestDL) fails on ARM HardFP @@ -776,6 +778,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Fri Nov 09 2012 Vít Ondruch - 2.0.0.0-0.2.r37589 +- Upgrade to Ruby 2.0.0 (r37589). + * Mon Nov 05 2012 Vít Ondruch - 2.0.0.0-0.1.r37421 - Upgrade to Ruby 2.0.0 (r37421). - Split Psych into rubygem-psych subpackage. From bd4a3ae0e597a0ffd02517cc2f653fa1c80f732e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 19 Nov 2012 12:49:46 +0100 Subject: [PATCH 27/87] Add references to upstream commits of RubyGems's uninstaller patch. --- ruby.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ruby.spec b/ruby.spec index 4fa5f96..d9ce484 100644 --- a/ruby.spec +++ b/ruby.spec @@ -94,6 +94,8 @@ Patch3: ruby-1.9.3-always-use-i386.patch Patch4: ruby-1.9.3-fix-s390x-build.patch # Fix the uninstaller, so that it doesn't say that gem doesn't exist # when it exists outside of the GEM_HOME (already fixed in the upstream) +# This consist of several RubyGems upstream patches: +# 2786a40b, 8e2a9889, 1755effe, 70963846, 21c78318, 88e1e1cc, 415c0ec4 Patch5: ruby-1.9.3-rubygems-1.8.11-uninstaller.patch # Allows to install RubyGems into custom directory, outside of Ruby's tree. # http://redmine.ruby-lang.org/issues/5617 From 6d28b09327c26aa257b024e2344e6732469523f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 19 Nov 2012 14:32:58 +0100 Subject: [PATCH 28/87] Rebase patches. --- ...9.3-added-site-and-vendor-arch-flags.patch | 41 +++++----- ruby-1.9.3-arch-specific-dir.patch | 34 ++++---- ruby-1.9.3-disable-versioned-paths.patch | 82 +++++++++---------- 3 files changed, 79 insertions(+), 78 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index cbed3a6..d7601c6 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -1,21 +1,21 @@ -From b0a875862d14244ca41cd1e1e9090f87757aaeb9 Mon Sep 17 00:00:00 2001 +From be687364922657501e861e9f53f8ec647a73fe00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 5 Sep 2011 13:10:47 +0200 Subject: [PATCH] Added configuration flags for site and vendor architecture specific directories. --- - Makefile.in | 3 +++ - configure.in | 40 ++++++++++++++++++++++++++++++++++++++++ - tool/mkconfig.rb | 8 ++++++-- - version.c | 4 ++++ + Makefile.in | 3 +++ + configure.in | 40 ++++++++++++++++++++++++++++++++++++++++ + tool/mkconfig.rb | 8 ++++++-- + version.c | 4 ++++ 4 files changed, 53 insertions(+), 2 deletions(-) diff --git a/Makefile.in b/Makefile.in -index bcdaf5f..f57e4c4 100644 +index 690ff8e..8c7dd98 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -38,6 +38,9 @@ datadir = @datadir@ +@@ -39,6 +39,9 @@ arch = @arch@ archdir = @archdir@ sitearch = @sitearch@ sitedir = @sitedir@ @@ -26,10 +26,10 @@ index bcdaf5f..f57e4c4 100644 TESTUI = console diff --git a/configure.in b/configure.in -index 83e5d76..31532bd 100644 +index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3029,6 +3029,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3169,6 +3169,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 83e5d76..31532bd 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3038,19 +3047,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3178,19 +3187,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 83e5d76..31532bd 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3068,12 +3090,26 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3208,6 +3230,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,20 +92,21 @@ index 83e5d76..31532bd 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' - ], +@@ -3215,6 +3244,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" -+ ]) + ]) +AS_CASE(["$RUBY_VENDOR_ARCHLIB_PATH"], + ["$RUBY_LIB_PREFIX/"*], [ + RUBY_VENDOR_ARCHLIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_ARCHLIB_PATH\" : \"$pat\"`"'"' + ], + [ + RUBY_VENDOR_ARCHLIB_PATH="\"${RUBY_VENDOR_ARCHLIB_PATH}\"" - ]) ++ ]) pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], -@@ -3096,19 +3132,23 @@ if test "x$SITE_DIR" = xno; then + ["$RUBY_EXEC_PREFIX/"*], [ +@@ -3236,11 +3272,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -119,7 +120,7 @@ index 83e5d76..31532bd 100644 fi AC_SUBST(arch)dnl - AC_SUBST(sitearch)dnl +@@ -3248,7 +3286,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl @@ -130,10 +131,10 @@ index 83e5d76..31532bd 100644 configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index b707c4b..6230720 100755 +index 03c3332..79b8e44 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb -@@ -44,6 +44,8 @@ v_others = [] +@@ -44,6 +44,8 @@ continued_name = nil continued_line = nil path_version = "/$(ruby_version)" archdir_override = "$(vendorlibdir)/$(sitearch)" @@ -166,7 +167,7 @@ index b707c4b..6230720 100755 print < Date: Thu, 8 Sep 2011 15:30:05 +0200 Subject: [PATCH] Add configuration arch specific dir flag. --- - Makefile.in | 1 + - configure.in | 20 ++++++++++++++++++++ - tool/mkconfig.rb | 4 +++- - version.c | 2 ++ - 4 files changed, 26 insertions(+), 1 deletions(-) + Makefile.in | 1 + + configure.in | 20 ++++++++++++++++++++ + tool/mkconfig.rb | 4 +++- + version.c | 2 ++ + 4 files changed, 26 insertions(+), 1 deletion(-) diff --git a/Makefile.in b/Makefile.in -index bcdaf5f..d61b2ee 100644 +index 78d7139..690ff8e 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -35,6 +35,7 @@ libexecdir = @libexecdir@ +@@ -36,6 +36,7 @@ libexecdir = @libexecdir@ datarootdir = @datarootdir@ datadir = @datadir@ arch = @arch@ @@ -23,10 +23,10 @@ index bcdaf5f..d61b2ee 100644 sitedir = @sitedir@ ruby_version = @ruby_version@ diff --git a/configure.in b/configure.in -index 83e5d76..e6dc38c 100644 +index db3641b..8e4aaec 100644 --- a/configure.in +++ b/configure.in -@@ -3011,6 +3011,15 @@ else +@@ -3151,6 +3151,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index 83e5d76..e6dc38c 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3033,16 +3042,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3173,16 +3182,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index 83e5d76..e6dc38c 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3073,6 +3091,7 @@ +@@ -3213,6 +3231,7 @@ else fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index 83e5d76..e6dc38c 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3087,6 +3106,7 @@ fi +@@ -3227,6 +3246,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl @@ -85,10 +85,10 @@ index 83e5d76..e6dc38c 100644 AC_SUBST(vendordir)dnl diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index b707c4b..9780ef2 100755 +index d9e26c1..03c3332 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb -@@ -43,6 +43,7 @@ v_others = [] +@@ -43,6 +43,7 @@ vars = {} continued_name = nil continued_line = nil path_version = "/$(ruby_version)" @@ -114,7 +114,7 @@ index b707c4b..9780ef2 100755 print < Date: Thu, 25 Aug 2011 14:33:51 +0200 Subject: [PATCH] Allow to disable versioned paths. --- - configure.in | 11 +++++++++++ - tool/mkconfig.rb | 9 ++++++--- - version.c | 10 ++++++++++ - 3 files changed, 27 insertions(+), 3 deletions(-) + configure.in | 11 +++++++++++ + lib/rdoc/ri/paths.rb | 4 ++-- + tool/mkconfig.rb | 9 ++++++--- + tool/rbinstall.rb | 2 +- + version.c | 10 ++++++++++ + 5 files changed, 30 insertions(+), 6 deletions(-) diff --git a/configure.in b/configure.in -index e742e74..86cb68f 100644 +index f2d22ef..db3641b 100644 --- a/configure.in +++ b/configure.in -@@ -3178,6 +3178,17 @@ else +@@ -3318,6 +3318,17 @@ else fi AC_SUBST(USE_RUBYGEMS) @@ -31,8 +33,24 @@ index e742e74..86cb68f 100644 arch_hdrdir="${EXTOUT}/include/${arch}/ruby" AS_MKDIR_P("${arch_hdrdir}") config_h="${arch_hdrdir}/config.h" +diff --git a/lib/rdoc/ri/paths.rb b/lib/rdoc/ri/paths.rb +index a3c65bf..a4e8559 100644 +--- a/lib/rdoc/ri/paths.rb ++++ b/lib/rdoc/ri/paths.rb +@@ -11,9 +11,9 @@ module RDoc::RI::Paths + version = RbConfig::CONFIG['ruby_version'] + + base = if RbConfig::CONFIG.key? 'ridir' then +- File.join RbConfig::CONFIG['ridir'], version ++ File.join [RbConfig::CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact + else +- File.join RbConfig::CONFIG['datadir'], 'ri', version ++ File.join [RbConfig::CONFIG['datadir'], 'ri', RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact + end + + SYSDIR = File.join base, "system" diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index a2221f0..47d8c8f 100755 +index f9d97d3..d9e26c1 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb @@ -42,6 +42,7 @@ v_others = [] @@ -71,8 +89,21 @@ index a2221f0..47d8c8f 100755 CONFIG["vendorarchdir"] = "$(vendorlibdir)/$(sitearch)" EOS print < $data_mode) + end diff --git a/version.c b/version.c -index 59d4e5e..641dc33 100644 +index 26e275a..05e5069 100644 --- a/version.c +++ b/version.c @@ -39,9 +39,15 @@ @@ -114,36 +145,5 @@ index 59d4e5e..641dc33 100644 RUBY_LIB "\0" #ifdef RUBY_THIN_ARCHLIB -- -1.7.7.3 -diff --git a/lib/rdoc/ri/paths.rb b/lib/rdoc/ri/paths.rb -index a3c65bf..0575730 100644 ---- a/lib/rdoc/ri/paths.rb -+++ b/lib/rdoc/ri/paths.rb -@@ -11,9 +11,9 @@ module RDoc::RI::Paths - version = RbConfig::CONFIG['ruby_version'] - - base = if RbConfig::CONFIG.key? 'ridir' then -- File.join RbConfig::CONFIG['ridir'], version -+ File.join [RbConfig::CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact - else -- File.join RbConfig::CONFIG['datadir'], 'ri', version -+ File.join [RbConfig::CONFIG['datadir'], 'ri', RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact - end - - SYSDIR = File.join base, "system" -diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb -index cec8c9f..fed14d2 100755 ---- a/tool/rbinstall.rb -+++ b/tool/rbinstall.rb -@@ -392,7 +392,7 @@ end - - install?(:doc, :rdoc) do - if $rdocdir -- ridatadir = File.join(CONFIG['ridir'], CONFIG['ruby_version'], "system") -+ ridatadir = File.join([CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil, "system"].compact) - prepare "rdoc", ridatadir - install_recursive($rdocdir, ridatadir, :mode => $data_mode) - end --- -1.7.6 +1.8.0 From 701f20251fe4c007a1a68dd1a566e3aa73defd0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 19 Nov 2012 14:38:30 +0100 Subject: [PATCH 29/87] Convert to git formated patch. --- ruby-1.9.3-always-use-i386.patch | 20 +++++++++-- ruby-1.9.3-custom-rubygems-location.patch | 28 ++++++++-------- ruby-1.9.3-fix-s390x-build.patch | 19 +++++++++-- ruby-1.9.3-mkmf-verbose.patch | 20 +++++++++-- ruby-1.9.3-rubygems-1.8.11-uninstaller.patch | 35 +++++++++++++++----- 5 files changed, 90 insertions(+), 32 deletions(-) diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index 2c9ca1e..d2c1bc0 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -1,6 +1,17 @@ ---- a/configure.in.orig 2011-10-18 08:56:21.587594685 +0200 -+++ b/configure.in 2011-10-18 08:56:59.751593321 +0200 -@@ -3153,6 +3153,8 @@ +From 1f061d350d01fc55272872d6f7932986dba4011d Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Mon, 19 Nov 2012 14:37:28 +0100 +Subject: [PATCH] Always use i386. + +--- + configure.in | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/configure.in b/configure.in +index c65e0c7..748edc9 100644 +--- a/configure.in ++++ b/configure.in +@@ -3293,6 +3293,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl @@ -9,3 +20,6 @@ if test "${universal_binary-no}" = yes ; then arch="universal-${target_os}" AC_CACHE_CHECK(whether __ARCHITECTURE__ is available, rb_cv_architecture_available, +-- +1.8.0 + diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index c13ca34..3f13e59 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -1,21 +1,21 @@ -From 279a693ce4ef3a887ce8d4fa59e0f2616a14d91a Mon Sep 17 00:00:00 2001 +From 643a3d3af2a3847e730c79515bc586768053119a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 11 Nov 2011 13:14:45 +0100 Subject: [PATCH] Allow to install RubyGems into custom location, outside of Ruby tree. --- - configure.in | 8 ++++++++ - tool/mkconfig.rb | 1 + - tool/rbinstall.rb | 9 +++++++++ - version.c | 4 ++++ - 4 files changed, 22 insertions(+), 0 deletions(-) + configure.in | 8 ++++++++ + tool/mkconfig.rb | 1 + + tool/rbinstall.rb | 9 +++++++++ + version.c | 4 ++++ + 4 files changed, 22 insertions(+) diff --git a/configure.in b/configure.in -index b1bc951..91c5d0d 100644 +index 748edc9..6a16745 100644 --- a/configure.in +++ b/configure.in -@@ -3056,6 +3056,13 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3196,6 +3196,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index b1bc951..91c5d0d 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3149,6 +3156,7 @@ AC_SUBST(sitearch)dnl +@@ -3289,6 +3296,7 @@ AC_SUBST(sitedir)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl @@ -38,7 +38,7 @@ index b1bc951..91c5d0d 100644 configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index b707c4b..9fecbfb 100755 +index 79b8e44..9cef0c6 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb @@ -84,6 +84,7 @@ File.foreach "config.status" do |line| @@ -50,7 +50,7 @@ index b707c4b..9fecbfb 100755 case val when /^\$\(ac_\w+\)$/; next diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb -index 6bfc73e..31dc446 100755 +index 17294a2..2757a73 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -313,6 +313,7 @@ sitelibdir = CONFIG["sitelibdir"] @@ -64,7 +64,7 @@ index 6bfc73e..31dc446 100755 @@ -500,7 +501,15 @@ end install?(:local, :comm, :lib) do prepare "library scripts", rubylibdir - noinst = %w[README* *.txt *.rdoc] + noinst = %w[README* *.txt *.rdoc *.gemspec] + noinst += %w[*ubygems.rb rubygems/ datadir.rb] if rubygemsdir install_recursive(File.join(srcdir, "lib"), rubylibdir, :no_install => noinst, :mode => $data_mode) + if rubygemsdir @@ -78,7 +78,7 @@ index 6bfc73e..31dc446 100755 install?(:local, :arch, :lib) do diff --git a/version.c b/version.c -index 59d4e5e..12ba7e9 100644 +index 962f39f..979701d 100644 --- a/version.c +++ b/version.c @@ -104,6 +104,10 @@ const char ruby_initial_load_paths[] = @@ -93,5 +93,5 @@ index 59d4e5e..12ba7e9 100644 #ifdef RUBY_THIN_ARCHLIB RUBY_THIN_ARCHLIB "\0" -- -1.7.7 +1.8.0 diff --git a/ruby-1.9.3-fix-s390x-build.patch b/ruby-1.9.3-fix-s390x-build.patch index d0ade91..5f91aae 100644 --- a/ruby-1.9.3-fix-s390x-build.patch +++ b/ruby-1.9.3-fix-s390x-build.patch @@ -1,6 +1,16 @@ -diff -up ruby-1.9.3-p0/ext/tk/extconf.rb.orig ruby-1.9.3-p0/ext/tk/extconf.rb ---- ruby-1.9.3-p0/ext/tk/extconf.rb.orig 2011-06-29 16:11:19.000000000 +0200 -+++ ruby-1.9.3-p0/ext/tk/extconf.rb 2011-10-18 16:15:59.406299659 +0200 +From d710179fcc088a201339a28fa6a5779da8e6ab62 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Mon, 19 Nov 2012 14:39:19 +0100 +Subject: [PATCH] Fix s390x build. + +--- + ext/tk/extconf.rb | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ext/tk/extconf.rb b/ext/tk/extconf.rb +index 72dd6cf..5c6081e 100644 +--- a/ext/tk/extconf.rb ++++ b/ext/tk/extconf.rb @@ -114,7 +114,7 @@ def is_macosx? end @@ -10,3 +20,6 @@ diff -up ruby-1.9.3-p0/ext/tk/extconf.rb.orig ruby-1.9.3-p0/ext/tk/extconf.rb end def check_tcltk_version(version) +-- +1.8.0 + diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 729ee80..77be75a 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -1,6 +1,17 @@ ---- ruby-1.9.3-p0/lib/mkmf.rb.debug 2011-08-11 15:07:37.000000000 +0900 -+++ ruby-1.9.3-p0/lib/mkmf.rb 2012-01-29 21:34:17.000000000 +0900 -@@ -1746,7 +1746,7 @@ +From b6f6f0b8cd750e97c15f1b739b1c95d6c1989294 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Mon, 19 Nov 2012 15:14:51 +0100 +Subject: [PATCH] Verbose mkmf. + +--- + lib/mkmf.rb | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/mkmf.rb b/lib/mkmf.rb +index ded4e89..0870f22 100644 +--- a/lib/mkmf.rb ++++ b/lib/mkmf.rb +@@ -1746,7 +1746,7 @@ SRC SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. @@ -9,3 +20,6 @@ Q1 = $(V:1=) Q = $(Q1:0=@) ECHO1 = $(V:1=@#{CONFIG['NULLCMD']}) +-- +1.8.0 + diff --git a/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch b/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch index af1cff2..f8eb63d 100644 --- a/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch +++ b/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch @@ -1,6 +1,18 @@ ---- ruby-1.9.3-p0/lib/rubygems/uninstaller.rb.orig 2011-10-31 10:22:36.321579483 +0100 -+++ ruby-1.9.3-p0/lib/rubygems/uninstaller.rb 2011-10-31 10:34:25.563626119 +0100 -@@ -51,15 +51,14 @@ +From 6a07398a3aac0793d1a62f6f4778d90baf86ab7e Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Mon, 19 Nov 2012 14:41:06 +0100 +Subject: [PATCH] RubyGems uninstaller upstream fixes. + +--- + lib/rubygems/uninstaller.rb | 35 +++++++++++++++++++++++------------ + test/rubygems/test_gem_uninstaller.rb | 2 +- + 2 files changed, 24 insertions(+), 13 deletions(-) + +diff --git a/lib/rubygems/uninstaller.rb b/lib/rubygems/uninstaller.rb +index cc32ea4..c0e8b4b 100644 +--- a/lib/rubygems/uninstaller.rb ++++ b/lib/rubygems/uninstaller.rb +@@ -51,15 +51,14 @@ class Gem::Uninstaller @bin_dir = options[:bin_dir] @format_executable = options[:format_executable] @@ -21,7 +33,7 @@ end ## -@@ -69,10 +68,24 @@ +@@ -69,10 +68,24 @@ class Gem::Uninstaller def uninstall list = Gem::Specification.find_all_by_name(@gem, @version) @@ -48,7 +60,7 @@ remove_all list elsif list.size > 1 then -@@ -250,12 +263,10 @@ +@@ -250,12 +263,10 @@ class Gem::Uninstaller msg << "\t#{spec.full_name}" spec.dependent_gems.each do |dep_spec, dep, satlist| @@ -63,10 +75,11 @@ msg << 'Continue with Uninstall?' return ask_yes_no(msg.join("\n"), true) end - ---- ruby-1.9.3-p0/test/rubygems/test_gem_uninstaller.rb.orig 2011-11-03 08:58:31.411272176 +0100 -+++ ruby-1.9.3-p0/test/rubygems/test_gem_uninstaller.rb 2011-11-03 08:58:43.010272351 +0100 -@@ -225,7 +225,7 @@ +diff --git a/test/rubygems/test_gem_uninstaller.rb b/test/rubygems/test_gem_uninstaller.rb +index a65b992..1cd186f 100644 +--- a/test/rubygems/test_gem_uninstaller.rb ++++ b/test/rubygems/test_gem_uninstaller.rb +@@ -225,7 +225,7 @@ class TestGemUninstaller < Gem::InstallerTestCase uninstaller = Gem::Uninstaller.new('a') @@ -74,3 +87,7 @@ + use_ui Gem::MockGemUi.new("2\ny\n") do uninstaller.uninstall end + +-- +1.8.0 + From 3d38c645eebc5c61a03589bb7bb8d77a4359641a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 20 Nov 2012 17:22:00 +0100 Subject: [PATCH 30/87] Upgrade to Ruby 2.0.0 (r37773). --- ruby-1.9.3-added-site-and-vendor-arch-flags.patch | 12 ++++++------ ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 8 ++++---- ruby-1.9.3-custom-rubygems-location.patch | 4 ++-- ruby-1.9.3-disable-versioned-paths.patch | 2 +- ruby.spec | 12 +++++++----- 6 files changed, 21 insertions(+), 19 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index d7601c6..d595118 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3169,6 +3169,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3153,6 +3153,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 8e4aaec..c65e0c7 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3178,19 +3187,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3162,19 +3171,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 8e4aaec..c65e0c7 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3208,6 +3230,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3192,6 +3214,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,7 +92,7 @@ index 8e4aaec..c65e0c7 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3215,6 +3244,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], +@@ -3199,6 +3228,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" ]) @@ -106,7 +106,7 @@ index 8e4aaec..c65e0c7 100644 pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3236,11 +3272,13 @@ if test "x$SITE_DIR" = xno; then +@@ -3220,11 +3256,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -120,7 +120,7 @@ index 8e4aaec..c65e0c7 100644 fi AC_SUBST(arch)dnl -@@ -3248,7 +3286,9 @@ AC_SUBST(sitearch)dnl +@@ -3232,7 +3270,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index d2c1bc0..00165dc 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index c65e0c7..748edc9 100644 --- a/configure.in +++ b/configure.in -@@ -3293,6 +3293,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3277,6 +3277,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index f96dff8..eb57196 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index db3641b..8e4aaec 100644 --- a/configure.in +++ b/configure.in -@@ -3151,6 +3151,15 @@ else +@@ -3135,6 +3135,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index db3641b..8e4aaec 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3173,16 +3182,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3157,16 +3166,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index db3641b..8e4aaec 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3213,6 +3231,7 @@ else +@@ -3197,6 +3215,7 @@ else fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index db3641b..8e4aaec 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3227,6 +3246,7 @@ fi +@@ -3211,6 +3230,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 3f13e59..47cd946 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index 748edc9..6a16745 100644 --- a/configure.in +++ b/configure.in -@@ -3196,6 +3196,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D +@@ -3180,6 +3180,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index 748edc9..6a16745 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3289,6 +3296,7 @@ AC_SUBST(sitedir)dnl +@@ -3273,6 +3280,7 @@ AC_SUBST(sitedir)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 77cfd32..be671a9 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index f2d22ef..db3641b 100644 --- a/configure.in +++ b/configure.in -@@ -3318,6 +3318,17 @@ else +@@ -3302,6 +3302,17 @@ else fi AC_SUBST(USE_RUBYGEMS) diff --git a/ruby.spec b/ruby.spec index d9ce484..574c016 100644 --- a/ruby.spec +++ b/ruby.spec @@ -15,7 +15,7 @@ #%%global milestone preview1 # Keep the revision enabled for pre-releases from SVN. -%global revision 37589 +%global revision 37773 %global ruby_archive %{name}-%{ruby_version} @@ -57,7 +57,7 @@ # http://rpm.org/ticket/78 %global gem_extdir %{_exec_prefix}/lib{,64}/gems -%global rake_version 0.9.2.2 +%global rake_version 0.9.4 # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} @@ -489,9 +489,8 @@ sed -i '8 a\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check -# http://bugs.ruby-lang.org/issues/7298 -# http://bugs.ruby-lang.org/issues/7312 -DISABLE_TESTS="-x test_enumerator.rb -x test_m17n_comb.rb" +# https://bugs.ruby-lang.org/issues/7386 +DISABLE_TESTS="-x test_rake_functional.rb" %ifarch armv7l armv7hl armv7hnl # test_call_double(DL::TestDL) fails on ARM HardFP @@ -780,6 +779,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 +- Upgrade to Ruby 2.0.0 (r37773). + * Fri Nov 09 2012 Vít Ondruch - 2.0.0.0-0.2.r37589 - Upgrade to Ruby 2.0.0 (r37589). From 2f76408f178b54dab4ee8e825d5613ec1b2278da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 22 Nov 2012 16:02:09 +0100 Subject: [PATCH 31/87] Update to Ruby 2.0.0 (r37807). --- ruby.spec | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index 574c016..c9d64c0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -15,7 +15,7 @@ #%%global milestone preview1 # Keep the revision enabled for pre-releases from SVN. -%global revision 37773 +%global revision 37807 %global ruby_archive %{name}-%{ruby_version} @@ -490,7 +490,8 @@ sed -i '8 a\ %check # https://bugs.ruby-lang.org/issues/7386 -DISABLE_TESTS="-x test_rake_functional.rb" +# http://bugs.ruby-lang.org/issues/7422 +DISABLE_TESTS="-x test_rake_functional.rb -x test_rubyoptions.rb" %ifarch armv7l armv7hl armv7hnl # test_call_double(DL::TestDL) fails on ARM HardFP From 991b8dedbf54b244be95fd3f9c81f603dc6c214f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 4 Dec 2012 12:51:34 +0100 Subject: [PATCH 32/87] Upgrade to Ruby 2.0.0 (r38184). --- ...9.3-added-site-and-vendor-arch-flags.patch | 12 +- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 8 +- ruby-1.9.3-custom-rubygems-location.patch | 4 +- ruby-1.9.3-disable-versioned-paths.patch | 8 +- ruby-1.9.3-mkmf-verbose.patch | 2 +- ruby-1.9.3-rubygems-1.8.11-uninstaller.patch | 93 ---------------- ruby.spec | 25 +++-- rubygems-1.8.11-binary-extensions.patch | 103 +++++++++--------- 9 files changed, 80 insertions(+), 177 deletions(-) delete mode 100644 ruby-1.9.3-rubygems-1.8.11-uninstaller.patch diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index d595118..5f72381 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3153,6 +3153,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3170,6 +3170,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 8e4aaec..c65e0c7 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3162,19 +3171,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3179,19 +3188,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 8e4aaec..c65e0c7 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3192,6 +3214,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3209,6 +3231,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,7 +92,7 @@ index 8e4aaec..c65e0c7 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3199,6 +3228,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], +@@ -3216,6 +3245,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" ]) @@ -106,7 +106,7 @@ index 8e4aaec..c65e0c7 100644 pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3220,11 +3256,13 @@ if test "x$SITE_DIR" = xno; then +@@ -3237,11 +3273,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -120,7 +120,7 @@ index 8e4aaec..c65e0c7 100644 fi AC_SUBST(arch)dnl -@@ -3232,7 +3270,9 @@ AC_SUBST(sitearch)dnl +@@ -3249,7 +3287,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index 00165dc..74e41d7 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index c65e0c7..748edc9 100644 --- a/configure.in +++ b/configure.in -@@ -3277,6 +3277,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3294,6 +3294,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index eb57196..d8970cf 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index db3641b..8e4aaec 100644 --- a/configure.in +++ b/configure.in -@@ -3135,6 +3135,15 @@ else +@@ -3152,6 +3152,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index db3641b..8e4aaec 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3157,16 +3166,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3174,16 +3183,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index db3641b..8e4aaec 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3197,6 +3215,7 @@ else +@@ -3214,6 +3232,7 @@ else fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index db3641b..8e4aaec 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3211,6 +3230,7 @@ fi +@@ -3228,6 +3247,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 47cd946..397d760 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index 748edc9..6a16745 100644 --- a/configure.in +++ b/configure.in -@@ -3180,6 +3180,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D +@@ -3197,6 +3197,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index 748edc9..6a16745 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3273,6 +3280,7 @@ AC_SUBST(sitedir)dnl +@@ -3290,6 +3297,7 @@ AC_SUBST(sitedir)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index be671a9..79f7bd6 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index f2d22ef..db3641b 100644 --- a/configure.in +++ b/configure.in -@@ -3302,6 +3302,17 @@ else +@@ -3319,6 +3319,17 @@ else fi AC_SUBST(USE_RUBYGEMS) @@ -37,10 +37,10 @@ diff --git a/lib/rdoc/ri/paths.rb b/lib/rdoc/ri/paths.rb index a3c65bf..a4e8559 100644 --- a/lib/rdoc/ri/paths.rb +++ b/lib/rdoc/ri/paths.rb -@@ -11,9 +11,9 @@ module RDoc::RI::Paths +@@ -12,9 +12,9 @@ module RDoc::RI::Paths version = RbConfig::CONFIG['ruby_version'] - base = if RbConfig::CONFIG.key? 'ridir' then + BASE = if RbConfig::CONFIG.key? 'ridir' then - File.join RbConfig::CONFIG['ridir'], version + File.join [RbConfig::CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact else @@ -48,7 +48,7 @@ index a3c65bf..a4e8559 100644 + File.join [RbConfig::CONFIG['datadir'], 'ri', RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact end - SYSDIR = File.join base, "system" + homedir = begin diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb index f9d97d3..d9e26c1 100755 --- a/tool/mkconfig.rb diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 77be75a..df88a50 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -11,7 +11,7 @@ diff --git a/lib/mkmf.rb b/lib/mkmf.rb index ded4e89..0870f22 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb -@@ -1746,7 +1746,7 @@ SRC +@@ -1747,7 +1747,7 @@ SRC SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. diff --git a/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch b/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch deleted file mode 100644 index f8eb63d..0000000 --- a/ruby-1.9.3-rubygems-1.8.11-uninstaller.patch +++ /dev/null @@ -1,93 +0,0 @@ -From 6a07398a3aac0793d1a62f6f4778d90baf86ab7e Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?V=C3=ADt=20Ondruch?= -Date: Mon, 19 Nov 2012 14:41:06 +0100 -Subject: [PATCH] RubyGems uninstaller upstream fixes. - ---- - lib/rubygems/uninstaller.rb | 35 +++++++++++++++++++++++------------ - test/rubygems/test_gem_uninstaller.rb | 2 +- - 2 files changed, 24 insertions(+), 13 deletions(-) - -diff --git a/lib/rubygems/uninstaller.rb b/lib/rubygems/uninstaller.rb -index cc32ea4..c0e8b4b 100644 ---- a/lib/rubygems/uninstaller.rb -+++ b/lib/rubygems/uninstaller.rb -@@ -51,15 +51,14 @@ class Gem::Uninstaller - @bin_dir = options[:bin_dir] - @format_executable = options[:format_executable] - -+ if options[:force] -+ @force_all = true -+ @force_ignore = true -+ end -+ - # only add user directory if install_dir is not set - @user_install = false - @user_install = options[:user_install] unless options[:install_dir] -- -- if @user_install then -- Gem.use_paths Gem.user_dir, @gem_home -- else -- Gem.use_paths @gem_home -- end - end - - ## -@@ -69,10 +68,24 @@ class Gem::Uninstaller - def uninstall - list = Gem::Specification.find_all_by_name(@gem, @version) - -+ list, other_repo_specs = list.partition do |spec| -+ @gem_home == spec.base_dir or -+ (@user_install and spec.base_dir == Gem.user_dir) -+ end -+ - if list.empty? then -- raise Gem::InstallError, "gem #{@gem.inspect} is not installed" -+ raise Gem::InstallError, "gem #{@gem.inspect} is not installed" if -+ other_repo_specs.empty? -+ -+ other_repos = other_repo_specs.map { |spec| spec.base_dir }.uniq -+ -+ message = ["#{@gem} is not installed in GEM_HOME, try:"] -+ message.concat other_repos.map { |repo| -+ "\tgem uninstall -i #{repo} #{@gem}" -+ } - -- elsif list.size > 1 and @force_all then -+ raise Gem::InstallError, message.join("\n") -+ elsif @force_all then - remove_all list - - elsif list.size > 1 then -@@ -250,12 +263,10 @@ class Gem::Uninstaller - msg << "\t#{spec.full_name}" - - spec.dependent_gems.each do |dep_spec, dep, satlist| -- msg << -- ("#{dep_spec.name}-#{dep_spec.version} depends on " + -- "[#{dep.name} (#{dep.requirement})]") -+ msg << "#{dep_spec.name}-#{dep_spec.version} depends on #{dep}" - end - -- msg << 'If you remove this gems, one or more dependencies will not be met.' -+ msg << 'If you remove this gem, one or more dependencies will not be met.' - msg << 'Continue with Uninstall?' - return ask_yes_no(msg.join("\n"), true) - end -diff --git a/test/rubygems/test_gem_uninstaller.rb b/test/rubygems/test_gem_uninstaller.rb -index a65b992..1cd186f 100644 ---- a/test/rubygems/test_gem_uninstaller.rb -+++ b/test/rubygems/test_gem_uninstaller.rb -@@ -225,7 +225,7 @@ class TestGemUninstaller < Gem::InstallerTestCase - - uninstaller = Gem::Uninstaller.new('a') - -- use_ui Gem::MockGemUi.new("2\n") do -+ use_ui Gem::MockGemUi.new("2\ny\n") do - uninstaller.uninstall - end - --- -1.8.0 - diff --git a/ruby.spec b/ruby.spec index c9d64c0..129df7a 100644 --- a/ruby.spec +++ b/ruby.spec @@ -15,7 +15,7 @@ #%%global milestone preview1 # Keep the revision enabled for pre-releases from SVN. -%global revision 37807 +%global revision 38184 %global ruby_archive %{name}-%{ruby_version} @@ -44,7 +44,7 @@ %global ruby_vendorlibdir %{_datadir}/ruby/%{ruby_vendordir} %global ruby_vendorarchdir %{_libdir}/ruby/%{ruby_vendordir} -%global rubygems_version 1.8.11 +%global rubygems_version 2.0.0.preview2 # The RubyGems library has to stay out of Ruby directory three, since the # RubyGems should be share by all Ruby implementations. @@ -57,16 +57,16 @@ # http://rpm.org/ticket/78 %global gem_extdir %{_exec_prefix}/lib{,64}/gems -%global rake_version 0.9.4 +%global rake_version 0.9.5 # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} -%global rdoc_version 3.9.4 +%global rdoc_version 4.0.0.preview2 %global bigdecimal_version 1.1.0 %global io_console_version 0.3 %global json_version 1.7.1 -%global minitest_version 3.4.0 -%global psych_version 1.3.4 +%global minitest_version 4.3.2 +%global psych_version 2.0.0 %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -92,11 +92,6 @@ Patch2: ruby-1.9.3-added-site-and-vendor-arch-flags.patch Patch3: ruby-1.9.3-always-use-i386.patch # http://redmine.ruby-lang.org/issues/5465 Patch4: ruby-1.9.3-fix-s390x-build.patch -# Fix the uninstaller, so that it doesn't say that gem doesn't exist -# when it exists outside of the GEM_HOME (already fixed in the upstream) -# This consist of several RubyGems upstream patches: -# 2786a40b, 8e2a9889, 1755effe, 70963846, 21c78318, 88e1e1cc, 415c0ec4 -Patch5: ruby-1.9.3-rubygems-1.8.11-uninstaller.patch # Allows to install RubyGems into custom directory, outside of Ruby's tree. # http://redmine.ruby-lang.org/issues/5617 Patch8: ruby-1.9.3-custom-rubygems-location.patch @@ -360,7 +355,6 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch2 -p1 %patch3 -p1 %patch4 -p1 -%patch5 -p1 %patch8 -p1 %patch9 -p1 %patch12 -p1 @@ -435,14 +429,17 @@ mkdir -p %{buildroot}%{gem_extdir}/exts # make symlinks for io-console and bigdecimal, which are considered to be part of stdlib by other Gems mkdir -p %{buildroot}%{gem_dir}/gems/rake-%{rake_version}/lib mv %{buildroot}%{ruby_libdir}/rake* %{buildroot}%{gem_dir}/gems/rake-%{rake_version}/lib +mv %{buildroot}%{gem_dir}/specifications/default/rake-%{rake_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/rdoc-%{rdoc_version}/lib mv %{buildroot}%{ruby_libdir}/rdoc* %{buildroot}%{gem_dir}/gems/rdoc-%{rdoc_version}/lib +mv %{buildroot}%{gem_dir}/specifications/default/rdoc-%{rdoc_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{ruby_libdir}/bigdecimal %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{ruby_libarchdir}/bigdecimal.so %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib +mv %{buildroot}%{gem_dir}/specifications/default/bigdecimal-%{bigdecimal_version}.gemspec %{buildroot}%{gem_dir}/specifications ln -s %{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib/bigdecimal %{buildroot}%{ruby_libdir}/bigdecimal ln -s %{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib/bigdecimal.so %{buildroot}%{ruby_libarchdir}/bigdecimal.so @@ -450,6 +447,7 @@ mkdir -p %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io mv %{buildroot}%{ruby_libdir}/io %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib mv %{buildroot}%{ruby_libarchdir}/io/console.so %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io +mv %{buildroot}%{gem_dir}/specifications/default/io-console-%{io_console_version}.gemspec %{buildroot}%{gem_dir}/specifications ln -s %{gem_dir}/gems/io-console-%{io_console_version}/lib/io %{buildroot}%{ruby_libdir}/io ln -s %{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io/console.so %{buildroot}%{ruby_libarchdir}/io/console.so @@ -457,14 +455,17 @@ mkdir -p %{buildroot}%{gem_dir}/gems/json-%{json_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/json-%{json_version}/lib mv %{buildroot}%{ruby_libdir}/json* %{buildroot}%{gem_dir}/gems/json-%{json_version}/lib mv %{buildroot}%{ruby_libarchdir}/json/ %{buildroot}%{_libdir}/gems/exts/json-%{json_version}/lib/ +mv %{buildroot}%{gem_dir}/specifications/default/json-%{json_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib mv %{buildroot}%{ruby_libdir}/minitest %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib +mv %{buildroot}%{gem_dir}/specifications/default/minitest-%{minitest_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib mkdir -p %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib mv %{buildroot}%{ruby_libdir}/psych* %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib mv %{buildroot}%{ruby_libarchdir}/psych.so %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib/ +mv %{buildroot}%{gem_dir}/specifications/default/psych-%{psych_version}.gemspec %{buildroot}%{gem_dir}/specifications # Adjust the gemspec files so that the gems will load properly sed -i '8 a\ diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index b3a5697..d44f9cf 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -4,14 +4,14 @@ Date: Thu, 3 Nov 2011 16:43:05 +0100 Subject: [PATCH 1/6] Add dedicate extensions folder into $LOAD_PATH. --- - lib/rubygems/specification.rb | 37 ++++++++++++++++++++++++++++++------- - 1 files changed, 30 insertions(+), 7 deletions(-) + lib/rubygems/specification.rb | 32 ++++++++++++++++++++++++++++++-- + 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 97db19e..263e7d3 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -859,6 +859,12 @@ class Gem::Specification +@@ -1250,6 +1250,12 @@ class Gem::Specification File.join full_gem_path, path end @@ -24,31 +24,26 @@ index 97db19e..263e7d3 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -970,16 +976,16 @@ class Gem::Specification +@@ -1364,11 +1370,16 @@ class Gem::Specification def contains_requirable_file? file - root = full_gem_path -+ ext = ext_dir -+ -+ require_paths.any? do |lib| + root = full_gem_path ++ ext = ext_dir + suffixes = Gem.suffixes + + require_paths.any? do |lib| +- base = "#{root}/#{lib}/#{file}" +- suffixes.any? { |suf| File.file? "#{base}#{suf}" } + base = ["#{root}/#{lib}/#{file}"] + base << "#{ext}/#{lib}/#{file}" unless extensions.empty? - -- require_paths.each do |lib| -- base = "#{root}/#{lib}/#{file}" -- Gem.suffixes.each do |suf| -- path = "#{base}#{suf}" -- return true if File.file? path ++ + base.any? do |path| -+ Gem.suffixes.any? { |suf| File.file? "#{path}#{suf}" } - end ++ suffixes.any? { |suf| File.file? "#{path}#{suf}" } ++ end end -- -- return false end - ## -@@ -1295,6 +1301,23 @@ class Gem::Specification +@@ -1664,6 +1675,23 @@ class Gem::Specification end ## @@ -73,7 +68,7 @@ index 97db19e..263e7d3 100644 # # Formerly used to indicate this gem was RDoc-capable. -- -1.7.7.3 +1.8.0 From 671e4285bf9db948bc5f054d7d3d931cdd7a17f8 Mon Sep 17 00:00:00 2001 @@ -82,18 +77,18 @@ Date: Wed, 16 Nov 2011 13:26:48 +0100 Subject: [PATCH 2/6] Use spec's ext dir for extension installation. --- - lib/rubygems/installer.rb | 2 +- - lib/rubygems/specification.rb | 7 +++---- + lib/rubygems/installer.rb | 2 +- + lib/rubygems/specification.rb | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 74d803d..0063c7f 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -509,7 +509,7 @@ TEXT - def build_extensions - return if spec.extensions.empty? - say "Building native extensions. This could take a while..." +@@ -649,7 +649,7 @@ TEXT + say "This could take a while..." + end + - dest_path = File.join gem_dir, spec.require_paths.first + dest_path = spec.ext_dir ran_rake = false # only run rake once @@ -103,7 +98,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 263e7d3..d31b93b 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1305,16 +1305,15 @@ class Gem::Specification +@@ -1679,16 +1679,15 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -124,7 +119,7 @@ index 263e7d3..d31b93b 100644 ## -- -1.7.7.3 +1.8.0 From 11b4a0cbadd8b1d3320f838881aa60feb6f848e7 Mon Sep 17 00:00:00 2001 @@ -133,14 +128,14 @@ Date: Wed, 16 Nov 2011 14:52:16 +0100 Subject: [PATCH 3/6] Simplify the extending of $LOAD_PATH for binary gems. --- - lib/rubygems/specification.rb | 11 +++++------ - 1 files changed, 5 insertions(+), 6 deletions(-) + lib/rubygems/specification.rb | 11 +++++------ + 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index d31b93b..e65ea2d 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -859,11 +859,7 @@ class Gem::Specification +@@ -1250,11 +1250,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -153,7 +148,7 @@ index d31b93b..e65ea2d 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1313,7 +1309,10 @@ class Gem::Specification +@@ -1687,7 +1683,10 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir @@ -166,7 +161,7 @@ index d31b93b..e65ea2d 100644 ## -- -1.7.7.3 +1.8.0 From 5d46cd2b1ac9517a9cbcfa430261e62bb3a376b8 Mon Sep 17 00:00:00 2001 @@ -175,18 +170,18 @@ Date: Fri, 9 Dec 2011 16:31:04 +0100 Subject: [PATCH 4/6] Fix the binary extension search path construction. --- - lib/rubygems/installer.rb | 2 +- - lib/rubygems/specification.rb | 4 ++-- + lib/rubygems/installer.rb | 2 +- + lib/rubygems/specification.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 0063c7f..83b8fd5 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -509,7 +509,7 @@ TEXT - def build_extensions - return if spec.extensions.empty? - say "Building native extensions. This could take a while..." +@@ -649,7 +649,7 @@ TEXT + say "This could take a while..." + end + - dest_path = spec.ext_dir + dest_path = File.join spec.ext_dir, spec.require_paths.first ran_rake = false # only run rake once @@ -196,7 +191,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index e65ea2d..8be2ade 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -859,7 +859,7 @@ class Gem::Specification +@@ -1250,7 +1250,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -205,7 +200,7 @@ index e65ea2d..8be2ade 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1301,7 +1301,7 @@ class Gem::Specification +@@ -1675,7 +1675,7 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -215,7 +210,7 @@ index e65ea2d..8be2ade 100644 ## -- -1.7.7.3 +1.8.0 From 6229583633802b45e5a3e5689ab9077347cd9ef7 Mon Sep 17 00:00:00 2001 @@ -224,14 +219,14 @@ Date: Tue, 13 Dec 2011 12:14:54 +0100 Subject: [PATCH 5/6] Remove binary extensions during uninstall. --- - lib/rubygems/uninstaller.rb | 1 + - 1 files changed, 1 insertions(+), 0 deletions(-) + lib/rubygems/uninstaller.rb | 1 + + 1 file changed, 1 insertion(+) diff --git a/lib/rubygems/uninstaller.rb b/lib/rubygems/uninstaller.rb index cc32ea4..94d78e0 100644 --- a/lib/rubygems/uninstaller.rb +++ b/lib/rubygems/uninstaller.rb -@@ -213,6 +213,7 @@ class Gem::Uninstaller +@@ -234,6 +234,7 @@ class Gem::Uninstaller File.writable?(spec.base_dir) FileUtils.rm_rf spec.full_gem_path @@ -240,7 +235,7 @@ index cc32ea4..94d78e0 100644 # TODO: should this be moved to spec?... I vote eww (also exists in docmgr) old_platform_name = [spec.name, -- -1.7.7.3 +1.8.0 From bc40e1b9f60a9a04456e3504ffe6ee600b6da269 Mon Sep 17 00:00:00 2001 @@ -249,15 +244,15 @@ Date: Tue, 13 Dec 2011 14:27:14 +0100 Subject: [PATCH 6/6] Avoid dependency on customized operating_system.rb. --- - lib/rubygems/defaults.rb | 11 +++++++++++ - lib/rubygems/specification.rb | 5 +---- + lib/rubygems/defaults.rb | 11 +++++++++++ + lib/rubygems/specification.rb | 5 +---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb index 20b4198..6d8711f 100644 --- a/lib/rubygems/defaults.rb +++ b/lib/rubygems/defaults.rb -@@ -94,6 +94,17 @@ module Gem +@@ -101,6 +101,17 @@ module Gem end ## @@ -272,14 +267,14 @@ index 20b4198..6d8711f 100644 + end + + ## - # The default system-wide source info cache directory + # A wrapper around RUBY_ENGINE const that may not be defined - def self.default_system_source_cache_dir + def self.ruby_engine diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 8be2ade..f54210a 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1309,10 +1309,7 @@ class Gem::Specification +@@ -1683,10 +1683,7 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir @@ -292,5 +287,5 @@ index 8be2ade..f54210a 100644 ## -- -1.7.7.3 +1.8.0 From 2c975d30bf58911d5df797afd7337b3b9d9400b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 5 Dec 2012 16:42:40 +0100 Subject: [PATCH 33/87] Update release name to preview2, which is the most actual. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 129df7a..eaaebb3 100644 --- a/ruby.spec +++ b/ruby.spec @@ -12,7 +12,7 @@ %global ruby_abi 1.9.1 # Specify the named version. It has precedense to revision. -#%%global milestone preview1 +#%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. %global revision 38184 From 4569d76cb7f943a701ecf3938758acc27cf64c08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 5 Dec 2012 16:46:30 +0100 Subject: [PATCH 34/87] Add TODO to fix ruby_abi for official release. --- ruby.spec | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index eaaebb3..7a8fec4 100644 --- a/ruby.spec +++ b/ruby.spec @@ -7,7 +7,9 @@ %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_version_patch_level %{major_minor_version}.%{teeny_version}.%{patch_level} -# Ruby 2.0 keeps the abi Ruby 1.9.1 compatible. +# TODO: Fix ruby_api for official release according to +# http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/48984 +# It is kept at 1.9.1 just for testing. All dependent libraries need rebuild. # %%global ruby_abi %%{major_minor_version}.0 %global ruby_abi 1.9.1 From 6443d60ed651f3c4bba8146ec31a0577fdd5cb03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 6 Dec 2012 13:42:40 +0100 Subject: [PATCH 35/87] Fix bogus dates in %changelog reported by rpm-4.11. --- ruby.spec | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ruby.spec b/ruby.spec index 7a8fec4..25b74d8 100644 --- a/ruby.spec +++ b/ruby.spec @@ -832,18 +832,18 @@ make check TESTS="-v $DISABLE_TESTS" - Create and own RubyGems directories for binary extensions. - Fix build with GCC 4.7. -* Wed Jan 16 2012 Vít Ondruch - 1.9.3.0-3 +* Mon Jan 16 2012 Vít Ondruch - 1.9.3.0-3 - Fix RHEL build. - Fixed directory ownership. - Verose build output. -* Wed Jan 15 2012 Vít Ondruch - 1.9.3.0-2 +* Sun Jan 15 2012 Vít Ondruch - 1.9.3.0-2 - Install RubyGems outside of Ruby directory structure. - RubyGems has not its own -devel subpackage. - Enhanced macros.ruby and macros.rubygems. - All tests are green now (bkabrda). -* Tue Jan 14 2012 Vít Ondruch - 1.9.3.0-1 +* Sat Jan 14 2012 Vít Ondruch - 1.9.3.0-1 - Initial package * Sat Jan 14 2012 Fedora Release Engineering - 1.8.7.357-2 @@ -857,7 +857,7 @@ make check TESTS="-v $DISABLE_TESTS" - dont normalise arm cpus to arm - there is something weird about how ruby choses where to put bits -* Thu Nov 16 2011 Mamoru Tasaka - 1.8.7.352-3 +* Thu Nov 17 2011 Mamoru Tasaka - 1.8.7.352-3 - F-17: kill gdbm support for now due to licensing compatibility issue * Sat Oct 1 2011 Mamoru Tasaka - 1.8.7.352-2 @@ -1142,11 +1142,11 @@ make check TESTS="-v $DISABLE_TESTS" * Fri Aug 10 2007 Akira TAGOH - Update License tag. -* Mon Jul 25 2007 Akira TAGOH - 1.8.6.36-3 +* Mon Jun 25 2007 Akira TAGOH - 1.8.6.36-3 - ruby-r12567.patch: backport patch from upstream svn to get rid of the unnecessary declarations. (#245446) -* Wed Jul 20 2007 Akira TAGOH - 1.8.6.36-2 +* Wed Jun 20 2007 Akira TAGOH - 1.8.6.36-2 - New upstream release. - Fix Etc::getgrgid to get the correct gid as requested. (#236647) @@ -1610,7 +1610,7 @@ make check TESTS="-v $DISABLE_TESTS" - Removed ruby_cvs.2000092718.patch and added ruby_cvs.2000100218.patch (upgraded ruby to latest cvs version). -* Thu Sep 27 2000 akira yamada +* Wed Sep 27 2000 akira yamada - Updated to upstream version 1.6.1. - Removed ruby_cvs.2000082901.patch and added ruby_cvs.2000092718.patch (upgraded ruby to latest cvs version). @@ -1642,7 +1642,7 @@ make check TESTS="-v $DISABLE_TESTS" - Removed ruby-list.23190.patch(included into ruby_cvs.patch). - Added ruby-dev.10054.patch. -* Tue Jun 15 2000 akira yamada +* Thu Jun 15 2000 akira yamada - Updated to version 1.4.4(06/12/2000 CVS). - Added manuals and FAQs. - Split into ruby, ruby-devel, ruby-tcltk, ruby-docs, irb. @@ -1688,7 +1688,7 @@ make check TESTS="-v $DISABLE_TESTS" * Fri Nov 13 1998 Toru Hoshina - Version up. -* Mon Sep 22 1998 Toru Hoshina +* Tue Sep 22 1998 Toru Hoshina - To make a libruby.so. * Mon Sep 21 1998 Toru Hoshina From f20e944d8aa7cfde8927a567eb93062ab193fda1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 7 Dec 2012 13:51:54 +0100 Subject: [PATCH 36/87] Update to Ruby 2.0.0 (r38260). --- ruby.spec | 3 ++- rubygems-1.8.11-binary-extensions.patch | 12 ++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/ruby.spec b/ruby.spec index 25b74d8..520c55a 100644 --- a/ruby.spec +++ b/ruby.spec @@ -17,7 +17,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38184 +%global revision 38260 %global ruby_archive %{name}-%{ruby_version} @@ -686,6 +686,7 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libarchdir}/racc/cparse.so %{ruby_libarchdir}/rbconfig.rb %{ruby_libarchdir}/readline.so +%{ruby_libarchdir}/refinement.so %{ruby_libarchdir}/ripper.so %{ruby_libarchdir}/sdbm.so %{ruby_libarchdir}/socket.so diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index d44f9cf..dc6f85a 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -24,7 +24,7 @@ index 97db19e..263e7d3 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1364,11 +1370,16 @@ class Gem::Specification +@@ -1368,11 +1374,16 @@ class Gem::Specification def contains_requirable_file? file root = full_gem_path @@ -43,7 +43,7 @@ index 97db19e..263e7d3 100644 end end -@@ -1664,6 +1675,23 @@ class Gem::Specification +@@ -1668,6 +1679,23 @@ class Gem::Specification end ## @@ -98,7 +98,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 263e7d3..d31b93b 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1679,16 +1679,15 @@ class Gem::Specification +@@ -1683,16 +1683,15 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -148,7 +148,7 @@ index d31b93b..e65ea2d 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1687,7 +1683,10 @@ class Gem::Specification +@@ -1691,7 +1687,10 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir @@ -200,7 +200,7 @@ index e65ea2d..8be2ade 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1675,7 +1675,7 @@ class Gem::Specification +@@ -1679,7 +1679,7 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -274,7 +274,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 8be2ade..f54210a 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1683,10 +1683,7 @@ class Gem::Specification +@@ -1687,10 +1687,7 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir From 2bb26f50946623446fb99f0ecd826b4c06a04877 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 7 Dec 2012 16:45:39 +0100 Subject: [PATCH 37/87] RDoc now depends on JSON. --- ruby.spec | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 520c55a..fe10e15 100644 --- a/ruby.spec +++ b/ruby.spec @@ -218,6 +218,7 @@ License: GPLv2 and Ruby and MIT Requires: ruby(abi) = %{ruby_abi} Requires: ruby(rubygems) >= %{rubygems_version} Requires: ruby(irb) = %{irb_version} +Requires: rubygem(json) >= %{json_version} Provides: rdoc = %{version}-%{release} Provides: ri = %{version}-%{release} Provides: rubygem(rdoc) = %{version}-%{release} @@ -784,10 +785,14 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Fri Dec 07 2012 Vít Ondruch - 2.0.0.0-0.1.r38260 +- Upgrade to Ruby 2.0.0 (r38260). +- RDoc now depends on JSON. + * Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 - Upgrade to Ruby 2.0.0 (r37773). -* Fri Nov 09 2012 Vít Ondruch - 2.0.0.0-0.2.r37589 +* Fri Nov 09 2012 Vít Ondruch - 2.0.0.0-0.1.r37589 - Upgrade to Ruby 2.0.0 (r37589). * Mon Nov 05 2012 Vít Ondruch - 2.0.0.0-0.1.r37421 From 8cf00989c44095296c29acc4f1636f7a8b977653 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 7 Dec 2012 17:12:51 +0100 Subject: [PATCH 38/87] Always add the .gemspec lines before end of block. --- ruby.spec | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ruby.spec b/ruby.spec index fe10e15..8dfcc9e 100644 --- a/ruby.spec +++ b/ruby.spec @@ -471,25 +471,25 @@ mv %{buildroot}%{ruby_libarchdir}/psych.so %{buildroot}%{_libdir}/gems/exts/psyc mv %{buildroot}%{gem_dir}/specifications/default/psych-%{psych_version}.gemspec %{buildroot}%{gem_dir}/specifications # Adjust the gemspec files so that the gems will load properly -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rake-%{rake_version}.gemspec -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]\ s.extensions = ["bigdecimal.so"]' %{buildroot}%{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]\ s.extensions = ["io/console.so"]' %{buildroot}%{gem_dir}/specifications/io-console-%{io_console_version}.gemspec -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]\ s.extensions = ["json/ext/parser.so", "json/ext/generator.so"]' %{buildroot}%{gem_dir}/specifications/json-%{json_version}.gemspec -sed -i '8 a\ +sed -i '/^end$/ i\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check From fd6e7d558a0ba56d25419c47066ae03bf44d32b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 10 Dec 2012 16:22:43 +0100 Subject: [PATCH 39/87] Upgrade to Ruby 2.0.0 (r38297). --- ...-1.9.3-added-site-and-vendor-arch-flags.patch | 16 ++++++++-------- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 12 ++++++------ ruby-1.9.3-custom-rubygems-location.patch | 6 +++--- ruby-1.9.3-disable-versioned-paths.patch | 6 +++--- ruby.spec | 6 +++--- rubygems-1.8.11-binary-extensions.patch | 2 +- 7 files changed, 25 insertions(+), 25 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 5f72381..4ec996a 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3170,6 +3170,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3172,6 +3172,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 8e4aaec..c65e0c7 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3179,19 +3188,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3181,19 +3190,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 8e4aaec..c65e0c7 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3209,6 +3231,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3211,6 +3233,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,7 +92,7 @@ index 8e4aaec..c65e0c7 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3216,6 +3245,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], +@@ -3218,6 +3247,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" ]) @@ -106,7 +106,7 @@ index 8e4aaec..c65e0c7 100644 pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3237,11 +3273,13 @@ if test "x$SITE_DIR" = xno; then +@@ -3239,11 +3275,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -120,7 +120,7 @@ index 8e4aaec..c65e0c7 100644 fi AC_SUBST(arch)dnl -@@ -3249,7 +3287,9 @@ AC_SUBST(sitearch)dnl +@@ -3251,7 +3289,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl @@ -143,7 +143,7 @@ index 03c3332..79b8e44 100755 File.foreach "config.status" do |line| next if /^#/ =~ line name = nil -@@ -79,6 +81,8 @@ File.foreach "config.status" do |line| +@@ -80,6 +82,8 @@ File.foreach "config.status" do |line| when /^RUBY_SO_NAME$/; next if $so_name when /^arch$/; if val.empty? then val = arch else arch = val end when /^archdir$/; archdir_override = val; next @@ -152,7 +152,7 @@ index 03c3332..79b8e44 100755 when /^sitearch/; val = '$(arch)' if val.empty? end case val -@@ -213,11 +217,11 @@ print <!) @@ -76,7 +76,7 @@ index db3641b..8e4aaec 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3228,6 +3247,7 @@ fi +@@ -3230,6 +3249,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl @@ -96,7 +96,7 @@ index d9e26c1..03c3332 100755 File.foreach "config.status" do |line| next if /^#/ =~ line name = nil -@@ -77,6 +78,7 @@ File.foreach "config.status" do |line| +@@ -78,6 +79,7 @@ File.foreach "config.status" do |line| when /^RUBY_INSTALL_NAME$/; next if $install_name when /^RUBY_SO_NAME$/; next if $so_name when /^arch$/; if val.empty? then val = arch else arch = val end @@ -104,7 +104,7 @@ index d9e26c1..03c3332 100755 when /^sitearch/; val = '$(arch)' if val.empty? end case val -@@ -207,7 +209,7 @@ print(*v_fast) +@@ -208,7 +210,7 @@ print(*v_fast) print(*v_others) print < - 2.0.0.0-0.1.r38260 -- Upgrade to Ruby 2.0.0 (r38260). +* Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38297 +- Upgrade to Ruby 2.0.0 (r38297). - RDoc now depends on JSON. * Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index dc6f85a..0377271 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -252,7 +252,7 @@ diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb index 20b4198..6d8711f 100644 --- a/lib/rubygems/defaults.rb +++ b/lib/rubygems/defaults.rb -@@ -101,6 +101,17 @@ module Gem +@@ -104,6 +104,17 @@ module Gem end ## From 746b720ed4acb478dfa34de63fd29087210e06c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 11 Dec 2012 10:53:48 +0100 Subject: [PATCH 40/87] Try to make -doc subpackage noarch again The new RDoc should resolve the arch dependent issues (https://github.com/rdoc/rdoc/issues/71). --- ruby.spec | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/ruby.spec b/ruby.spec index 8be4801..530618e 100644 --- a/ruby.spec +++ b/ruby.spec @@ -236,11 +236,7 @@ documentation. Summary: Documentation for %{name} Group: Documentation Requires: %{_bindir}/ri -# TODO: It seems that ri documentation differs from platform to platform due to -# some encoding bugs, therefore the documentation should be split out of this gem -# or kept platform specific. -# https://github.com/rdoc/rdoc/issues/71 -# BuildArch: noarch +BuildArch: noarch %description doc This package contains documentation for %{name}. @@ -788,6 +784,9 @@ make check TESTS="-v $DISABLE_TESTS" * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38297 - Upgrade to Ruby 2.0.0 (r38297). - RDoc now depends on JSON. +- Try to make -doc subpackage noarch again, since the new RDoc should resolve + the arch dependent issues (https://github.com/rdoc/rdoc/issues/71). + * Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 - Upgrade to Ruby 2.0.0 (r37773). From 6fe6b00adfb706c19ab3d3542fa71680d5e22743 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 17 Dec 2012 10:52:59 +0100 Subject: [PATCH 41/87] Update to Ruby 2.0.0 (r38422). --- ruby-1.9.3-added-site-and-vendor-arch-flags.patch | 12 ++++++------ ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 8 ++++---- ruby-1.9.3-custom-rubygems-location.patch | 4 ++-- ruby-1.9.3-disable-versioned-paths.patch | 2 +- ruby.spec | 10 +++++----- rubygems-1.8.11-binary-extensions.patch | 2 +- 7 files changed, 20 insertions(+), 20 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 4ec996a..4900fee 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3172,6 +3172,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3178,6 +3178,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 8e4aaec..c65e0c7 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3181,19 +3190,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3187,19 +3196,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 8e4aaec..c65e0c7 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3211,6 +3233,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3217,6 +3239,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,7 +92,7 @@ index 8e4aaec..c65e0c7 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3218,6 +3247,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], +@@ -3224,6 +3253,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" ]) @@ -106,7 +106,7 @@ index 8e4aaec..c65e0c7 100644 pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3239,11 +3275,13 @@ if test "x$SITE_DIR" = xno; then +@@ -3245,11 +3281,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -120,7 +120,7 @@ index 8e4aaec..c65e0c7 100644 fi AC_SUBST(arch)dnl -@@ -3251,7 +3289,9 @@ AC_SUBST(sitearch)dnl +@@ -3257,7 +3295,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index ae98ef5..3c4eff8 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index c65e0c7..748edc9 100644 --- a/configure.in +++ b/configure.in -@@ -3296,6 +3296,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3302,6 +3302,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index e1f025d..1e5bc06 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index db3641b..8e4aaec 100644 --- a/configure.in +++ b/configure.in -@@ -3154,6 +3154,15 @@ else +@@ -3160,6 +3160,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index db3641b..8e4aaec 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3176,16 +3185,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3182,16 +3191,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index db3641b..8e4aaec 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3216,6 +3234,7 @@ else +@@ -3222,6 +3240,7 @@ else fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index db3641b..8e4aaec 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3230,6 +3249,7 @@ fi +@@ -3236,6 +3255,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index ced4897..054b31f 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index 748edc9..6a16745 100644 --- a/configure.in +++ b/configure.in -@@ -3199,6 +3199,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D +@@ -3205,6 +3205,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index 748edc9..6a16745 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3292,6 +3299,7 @@ AC_SUBST(sitedir)dnl +@@ -3298,6 +3305,7 @@ AC_SUBST(sitedir)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 1b77ef4..32f7e99 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index f2d22ef..db3641b 100644 --- a/configure.in +++ b/configure.in -@@ -3321,6 +3321,17 @@ else +@@ -3327,6 +3327,17 @@ else fi AC_SUBST(USE_RUBYGEMS) diff --git a/ruby.spec b/ruby.spec index 530618e..f741626 100644 --- a/ruby.spec +++ b/ruby.spec @@ -17,7 +17,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38297 +%global revision 38422 %global ruby_archive %{name}-%{ruby_version} @@ -63,10 +63,10 @@ # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} -%global rdoc_version 4.0.0.preview2 +%global rdoc_version 4.0.0.preview2.1 %global bigdecimal_version 1.1.0 %global io_console_version 0.3 -%global json_version 1.7.1 +%global json_version 1.7.5 %global minitest_version 4.3.2 %global psych_version 2.0.0 @@ -781,8 +781,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38297 -- Upgrade to Ruby 2.0.0 (r38297). +* Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 +- Upgrade to Ruby 2.0.0 (r38422). - RDoc now depends on JSON. - Try to make -doc subpackage noarch again, since the new RDoc should resolve the arch dependent issues (https://github.com/rdoc/rdoc/issues/71). diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index 0377271..dc6f85a 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -252,7 +252,7 @@ diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb index 20b4198..6d8711f 100644 --- a/lib/rubygems/defaults.rb +++ b/lib/rubygems/defaults.rb -@@ -104,6 +104,17 @@ module Gem +@@ -101,6 +101,17 @@ module Gem end ## From bbb0b61b11ffcc7240b0b472ebd04f23a691b7f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 17 Dec 2012 15:43:07 +0100 Subject: [PATCH 42/87] Enable SystemTap support. --- ruby.spec | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index f741626..a8d7893 100644 --- a/ruby.spec +++ b/ruby.spec @@ -122,6 +122,7 @@ BuildRequires: readline-devel BuildRequires: tk-devel # Needed to pass test_set_program_name(TestRubyOptions) BuildRequires: procps +BuildRequires: %{_bindir}/dtrace %description Ruby is the interpreted scripting language for quick and easy @@ -786,7 +787,7 @@ make check TESTS="-v $DISABLE_TESTS" - RDoc now depends on JSON. - Try to make -doc subpackage noarch again, since the new RDoc should resolve the arch dependent issues (https://github.com/rdoc/rdoc/issues/71). - +- Enable SystemTap support. * Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 - Upgrade to Ruby 2.0.0 (r37773). From 27c051a6949492bcf95c0715273a5912cbd0ec3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 18 Dec 2012 14:43:23 +0100 Subject: [PATCH 43/87] Re-enable tests previously disabled due to bugs. --- ruby.spec | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index a8d7893..8929d7f 100644 --- a/ruby.spec +++ b/ruby.spec @@ -490,9 +490,7 @@ sed -i '/^end$/ i\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %check -# https://bugs.ruby-lang.org/issues/7386 -# http://bugs.ruby-lang.org/issues/7422 -DISABLE_TESTS="-x test_rake_functional.rb -x test_rubyoptions.rb" +DISABLE_TESTS="" %ifarch armv7l armv7hl armv7hnl # test_call_double(DL::TestDL) fails on ARM HardFP From 037d81c06ad1da948cc738ccc7d7691fa22c4dc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 19 Dec 2012 15:19:59 +0100 Subject: [PATCH 44/87] Add TapSet for Ruby. --- libruby.stp | 303 ++++++++++++++++++++++++++++++++++++++++++++++++++++ ruby.spec | 22 ++++ 2 files changed, 325 insertions(+) create mode 100644 libruby.stp diff --git a/libruby.stp b/libruby.stp new file mode 100644 index 0000000..098b39d --- /dev/null +++ b/libruby.stp @@ -0,0 +1,303 @@ +/* SystemTap tapset to make it easier to trace Ruby 2.0 + * + * All probes provided by Ruby can be listed using following command + * (the path to the library must be adjuste appropriately): + * + * stap -L 'process("@LIBRARY_PATH@").mark("*")' + */ + +/** + * probe ruby.array.create - Allocation of new array. + * + * @size: Number of elements (an int) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.array.create = + process("@LIBRARY_PATH@").mark("array__create") +{ + size = $arg1 + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.cmethod.entry - Fired just before a method implemented in C is entered. + * + * @classname: Name of the class (string) + * @methodname: The method about bo be executed (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.cmethod.entry = + process("@LIBRARY_PATH@").mark("cmethod__entry") +{ + classname = user_string($arg1) + methodname = user_string($arg2) + file = user_string($arg3) + line = $arg4 +} + +/** + * probe ruby.cmethod.return - Fired just after a method implemented in C has returned. + * + * @classname: Name of the class (string) + * @methodname: The executed method (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.cmethod.return = + process("@LIBRARY_PATH@").mark("cmethod__return") +{ + classname = user_string($arg1) + methodname = user_string($arg2) + file = user_string($arg3) + line = $arg4 +} + +/** + * probe ruby.find.require.entry - Fired when require starts to search load + * path for suitable file to require. + * + * @requiredfile: The name of the file to be required (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.find.require.entry = + process("@LIBRARY_PATH@").mark("find__require__entry") +{ + requiredfile = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.find.require.return - Fired just after require has finished + * search of load path for suitable file to require. + * + * @requiredfile: The name of the file to be required (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.find.require.return = + process("@LIBRARY_PATH@").mark("find__require__return") +{ + requiredfile = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.gc.mark.begin - Fired when a GC mark phase is about to start. + * + * It takes no arguments. + */ +probe ruby.gc.mark.begin = + process("@LIBRARY_PATH@").mark("gc__mark__begin") +{ +} + +/** + * probe ruby.gc.mark.end - Fired when a GC mark phase has ended. + * + * It takes no arguments. + */ +probe ruby.gc.mark.end = + process("@LIBRARY_PATH@").mark("gc__mark__end") +{ +} + +/** + * probe ruby.gc.sweep.begin - Fired when a GC sweep phase is about to start. + * + * It takes no arguments. + */ +probe ruby.gc.sweep.begin = + process("@LIBRARY_PATH@").mark("gc__sweep__begin") +{ +} + +/** + * probe ruby.gc.sweep.end - Fired when a GC sweep phase has ended. + * + * It takes no arguments. + */ +probe ruby.gc.sweep.end = + process("@LIBRARY_PATH@").mark("gc__sweep__end") +{ +} + +/** + * probe ruby.hash.create - Allocation of new hash. + * + * @size: Number of elements (int) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.hash.create = + process("@LIBRARY_PATH@").mark("hash__create") +{ + size = $arg1 + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.load.entry - Fired when calls to "load" are made. + * + * @loadedfile: The name of the file to be loaded (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.load.entry = + process("@LIBRARY_PATH@").mark("load__entry") +{ + loadedfile = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.load.return - Fired just after require has finished + * search of load path for suitable file to require. + * + * @loadedfile: The name of the file that was loaded (string) + */ +probe ruby.load.return = + process("@LIBRARY_PATH@").mark("load__return") +{ + loadedfile = user_string($arg1) +} + +/** + * probe ruby.method.entry - Fired just before a method implemented in Ruby is entered. + * + * @classname: Name of the class (string) + * @methodname: The method about bo be executed (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.method.entry = + process("@LIBRARY_PATH@").mark("method__entry") +{ + classname = user_string($arg1) + methodname = user_string($arg2) + file = user_string($arg3) + line = $arg4 +} + +/** + * probe ruby.method.return - Fired just after a method implemented in Ruby has returned. + * + * @classname: Name of the class (string) + * @methodname: The executed method (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.method.return = + process("@LIBRARY_PATH@").mark("method__return") +{ + classname = user_string($arg1) + methodname = user_string($arg2) + file = user_string($arg3) + line = $arg4 +} + +/** + * probe ruby.object.create - Allocation of new object. + * + * @classname: Name of the class (string) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.object.create = + process("@LIBRARY_PATH@").mark("object__create") +{ + classname = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.parse.begin - Fired just before a Ruby source file is parsed. + * + * @parsedfile: The name of the file to be parsed (string) + * @parsedline: The line number of beginning of parsing (int) + */ +probe ruby.parse.begin = + process("@LIBRARY_PATH@").mark("parse__begin") +{ + parsedfile = user_string($arg1) + parsedline = $arg2 +} + +/** + * probe ruby.parse.end - Fired just after a Ruby source file was parsed. + * + * @parsedfile: The name of parsed the file (string) + * @parsedline: The line number of beginning of parsing (int) + */ +probe ruby.parse.end = + process("@LIBRARY_PATH@").mark("parse__end") +{ + parsedfile = user_string($arg1) + parsedline = $arg2 +} + +/** + * probe ruby.raise - Fired when an exception is raised. + * + * @classname: The class name of the raised exception (string) + * @file: The name of the file where the exception was raised (string) + * @line: The line number in the file where the exception was raised (int) + */ +probe ruby.raise = + process("@LIBRARY_PATH@").mark("raise") +{ + classname = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.require.entry - Fired on calls to rb_require_safe (when a file + * is required). + * + * @requiredfile: The name of the file to be required (string) + * @file: The file that called "require" (string) + * @line: The line number where the call to require was made(int) + */ +probe ruby.require.entry = + process("@LIBRARY_PATH@").mark("require__entry") +{ + requiredfile = user_string($arg1) + file = user_string($arg2) + line = $arg3 +} + +/** + * probe ruby.require.return - Fired just after require has finished + * search of load path for suitable file to require. + * + * @requiredfile: The file that was required (string) + */ +probe ruby.require.return = + process("@LIBRARY_PATH@").mark("require__return") +{ + requiredfile = user_string($arg1) +} + +/** + * probe ruby.string.create - Allocation of new string. + * + * @size: Number of elements (an int) + * @file: The file name where the method is being called (string) + * @line: The line number where the method is being called (int) + */ +probe ruby.string.create = + process("@LIBRARY_PATH@").mark("string__create") +{ + size = $arg1 + file = user_string($arg2) + line = $arg3 +} diff --git a/ruby.spec b/ruby.spec index 8929d7f..1cbc178 100644 --- a/ruby.spec +++ b/ruby.spec @@ -70,6 +70,19 @@ %global minitest_version 4.3.2 %global psych_version 2.0.0 +# Might not be needed in the future, if we are lucky enough. +# https://bugzilla.redhat.com/show_bug.cgi?id=888262 +%global tapset_dir %{_datadir}/systemtap/tapset + +# The distinction between 32 and 64 bit file locations might be done better in +# the future. +# http://sourceware.org/bugzilla/show_bug.cgi?id=10485 +%ifarch ppc64 s390x x86_64 ia64 alpha sparc64 +%global libruby_stp libruby.so.%{ruby_version}-64.stp +%else +%global libruby_stp libruby.so.%{ruby_version}-32.stp +%endif + %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') Summary: An interpreter of object-oriented scripting language @@ -82,6 +95,7 @@ License: (Ruby or BSD) and Public Domain URL: http://ruby-lang.org/ Source0: ftp://ftp.ruby-lang.org/pub/%{name}/%{major_minor_version}/%{ruby_archive}.tar.gz Source1: operating_system.rb +Source2: libruby.stp # http://redmine.ruby-lang.org/issues/5231 Patch0: ruby-1.9.3-disable-versioned-paths.patch @@ -489,6 +503,11 @@ sed -i '/^end$/ i\ sed -i '/^end$/ i\ s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/minitest-%{minitest_version}.gemspec +# Install a tapset and fix up the path to the library. +mkdir -p %{buildroot}%{tapset_dir} +sed -e "s|LIBRARY_PATH|%{_libdir}/libruby.so.%{ruby_version}|" \ + %{SOURCE2} > %{buildroot}%{tapset_dir}/%{libruby_stp} + %check DISABLE_TESTS="" @@ -693,6 +712,8 @@ make check TESTS="-v $DISABLE_TESTS" %exclude %{ruby_libarchdir}/tkutil.so %{ruby_libarchdir}/zlib.so +%{tapset_dir}/.. + %files -n rubygems %{_bindir}/gem %{rubygems_dir} @@ -786,6 +807,7 @@ make check TESTS="-v $DISABLE_TESTS" - Try to make -doc subpackage noarch again, since the new RDoc should resolve the arch dependent issues (https://github.com/rdoc/rdoc/issues/71). - Enable SystemTap support. +- Add TapSet for Ruby. * Tue Nov 20 2012 Vít Ondruch - 2.0.0.0-0.1.r37773 - Upgrade to Ruby 2.0.0 (r37773). From cc8acc38097c9277706d2154d2ecc9879c2979cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 20 Dec 2012 14:58:38 +0100 Subject: [PATCH 45/87] Make Tapset platform independent. --- ruby.spec | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/ruby.spec b/ruby.spec index 1cbc178..b801a94 100644 --- a/ruby.spec +++ b/ruby.spec @@ -72,16 +72,9 @@ # Might not be needed in the future, if we are lucky enough. # https://bugzilla.redhat.com/show_bug.cgi?id=888262 -%global tapset_dir %{_datadir}/systemtap/tapset - -# The distinction between 32 and 64 bit file locations might be done better in -# the future. -# http://sourceware.org/bugzilla/show_bug.cgi?id=10485 -%ifarch ppc64 s390x x86_64 ia64 alpha sparc64 -%global libruby_stp libruby.so.%{ruby_version}-64.stp -%else -%global libruby_stp libruby.so.%{ruby_version}-32.stp -%endif +%global tapset_root %{_datadir}/systemtap +%global tapset_dir %{tapset_root}/tapset/ +%global tapset_libdir %(echo %{_libdir} | sed 's/64//')* %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -505,8 +498,8 @@ sed -i '/^end$/ i\ # Install a tapset and fix up the path to the library. mkdir -p %{buildroot}%{tapset_dir} -sed -e "s|LIBRARY_PATH|%{_libdir}/libruby.so.%{ruby_version}|" \ - %{SOURCE2} > %{buildroot}%{tapset_dir}/%{libruby_stp} +sed -e "s|@LIBRARY_PATH@|%{tapset_libdir}/libruby.so.%{ruby_version}|" \ + %{SOURCE2} > %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp %check DISABLE_TESTS="" @@ -712,7 +705,7 @@ make check TESTS="-v $DISABLE_TESTS" %exclude %{ruby_libarchdir}/tkutil.so %{ruby_libarchdir}/zlib.so -%{tapset_dir}/.. +%{tapset_root} %files -n rubygems %{_bindir}/gem From 0267112d9cf011e0f6ffd8994ee3f78ab4d09e60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 20 Dec 2012 15:32:50 +0100 Subject: [PATCH 46/87] Add small TODO. --- ruby.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/ruby.spec b/ruby.spec index b801a94..5049b75 100644 --- a/ruby.spec +++ b/ruby.spec @@ -88,6 +88,7 @@ License: (Ruby or BSD) and Public Domain URL: http://ruby-lang.org/ Source0: ftp://ftp.ruby-lang.org/pub/%{name}/%{major_minor_version}/%{ruby_archive}.tar.gz Source1: operating_system.rb +# TODO: Try to push SystemTap support upstream. Source2: libruby.stp # http://redmine.ruby-lang.org/issues/5231 From 289d94d1b98e592c0a57f6275a2fe3ea1cfedaff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 20 Dec 2012 16:46:57 +0100 Subject: [PATCH 47/87] Upgrade to Ruby 2.0.0 (r38732). --- ruby-1.9.3-added-site-and-vendor-arch-flags.patch | 14 +++++++------- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 10 +++++----- ruby-1.9.3-custom-rubygems-location.patch | 4 ++-- ruby-1.9.3-disable-versioned-paths.patch | 2 +- ruby.spec | 12 +++++++----- rubygems-1.8.11-binary-extensions.patch | 6 +++--- 7 files changed, 26 insertions(+), 24 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 4900fee..45dbc08 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -15,7 +15,7 @@ diff --git a/Makefile.in b/Makefile.in index 690ff8e..8c7dd98 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -39,6 +39,9 @@ arch = @arch@ +@@ -41,6 +41,9 @@ arch = @arch@ archdir = @archdir@ sitearch = @sitearch@ sitedir = @sitedir@ @@ -29,7 +29,7 @@ diff --git a/configure.in b/configure.in index 8e4aaec..c65e0c7 100644 --- a/configure.in +++ b/configure.in -@@ -3178,6 +3178,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do +@@ -3197,6 +3197,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do dir="${SITE_DIR}" done @@ -45,7 +45,7 @@ index 8e4aaec..c65e0c7 100644 AC_ARG_WITH(vendordir, AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), [vendordir=$withval], -@@ -3187,19 +3196,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do +@@ -3206,19 +3215,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do dir="${VENDOR_DIR}" done @@ -78,7 +78,7 @@ index 8e4aaec..c65e0c7 100644 fi pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3217,6 +3239,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], +@@ -3236,6 +3258,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], [ RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" ]) @@ -92,7 +92,7 @@ index 8e4aaec..c65e0c7 100644 AS_CASE(["$RUBY_VENDOR_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3224,6 +3253,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], +@@ -3243,6 +3272,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], [ RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" ]) @@ -106,7 +106,7 @@ index 8e4aaec..c65e0c7 100644 pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' AS_CASE(["$RUBY_LIB_PREFIX"], ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3245,11 +3281,13 @@ if test "x$SITE_DIR" = xno; then +@@ -3264,11 +3300,13 @@ if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) @@ -120,7 +120,7 @@ index 8e4aaec..c65e0c7 100644 fi AC_SUBST(arch)dnl -@@ -3257,7 +3295,9 @@ AC_SUBST(sitearch)dnl +@@ -3276,7 +3314,9 @@ AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl AC_SUBST(archdir)dnl AC_SUBST(sitedir)dnl diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index 3c4eff8..3cf148e 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index c65e0c7..748edc9 100644 --- a/configure.in +++ b/configure.in -@@ -3302,6 +3302,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3321,6 +3321,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 1e5bc06..5906b4c 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -14,7 +14,7 @@ diff --git a/Makefile.in b/Makefile.in index 78d7139..690ff8e 100644 --- a/Makefile.in +++ b/Makefile.in -@@ -36,6 +36,7 @@ libexecdir = @libexecdir@ +@@ -38,6 +38,7 @@ libexecdir = @libexecdir@ datarootdir = @datarootdir@ datadir = @datadir@ arch = @arch@ @@ -26,7 +26,7 @@ diff --git a/configure.in b/configure.in index db3641b..8e4aaec 100644 --- a/configure.in +++ b/configure.in -@@ -3160,6 +3160,15 @@ else +@@ -3179,6 +3179,15 @@ else RUBY_LIB_VERSION="\"${ruby_version}\"" fi @@ -42,7 +42,7 @@ index db3641b..8e4aaec 100644 AC_ARG_WITH(sitedir, AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), [sitedir=$withval], -@@ -3182,16 +3191,25 @@ if test "${LOAD_RELATIVE+set}"; then +@@ -3201,16 +3210,25 @@ if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" @@ -68,7 +68,7 @@ index db3641b..8e4aaec 100644 AS_CASE(["$RUBY_SITE_LIB_PATH"], ["$RUBY_LIB_PREFIX/"*], [ RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3222,6 +3240,7 @@ else +@@ -3241,6 +3259,7 @@ else fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) @@ -76,7 +76,7 @@ index db3641b..8e4aaec 100644 if test "x$SITE_DIR" = xno; then AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) else -@@ -3236,6 +3255,7 @@ fi +@@ -3255,6 +3274,7 @@ fi AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 054b31f..b4d95a6 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index 748edc9..6a16745 100644 --- a/configure.in +++ b/configure.in -@@ -3205,6 +3205,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D +@@ -3224,6 +3224,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D dir="${VENDORARCH_DIR}" done @@ -29,7 +29,7 @@ index 748edc9..6a16745 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX="" -@@ -3298,6 +3305,7 @@ AC_SUBST(sitedir)dnl +@@ -3317,6 +3324,7 @@ AC_SUBST(sitedir)dnl AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch index 32f7e99..be13c08 100644 --- a/ruby-1.9.3-disable-versioned-paths.patch +++ b/ruby-1.9.3-disable-versioned-paths.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index f2d22ef..db3641b 100644 --- a/configure.in +++ b/configure.in -@@ -3327,6 +3327,17 @@ else +@@ -3346,6 +3346,17 @@ else fi AC_SUBST(USE_RUBYGEMS) diff --git a/ruby.spec b/ruby.spec index 5049b75..af0eba9 100644 --- a/ruby.spec +++ b/ruby.spec @@ -17,7 +17,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38422 +%global revision 38732 %global ruby_archive %{name}-%{ruby_version} @@ -46,7 +46,7 @@ %global ruby_vendorlibdir %{_datadir}/ruby/%{ruby_vendordir} %global ruby_vendorarchdir %{_libdir}/ruby/%{ruby_vendordir} -%global rubygems_version 2.0.0.preview2 +%global rubygems_version 2.0.0.preview3.1 # The RubyGems library has to stay out of Ruby directory three, since the # RubyGems should be share by all Ruby implementations. @@ -59,11 +59,11 @@ # http://rpm.org/ticket/78 %global gem_extdir %{_exec_prefix}/lib{,64}/gems -%global rake_version 0.9.5 +%global rake_version 0.9.6 # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} -%global rdoc_version 4.0.0.preview2.1 +%global rdoc_version 4.0.0.preview3.1 %global bigdecimal_version 1.1.0 %global io_console_version 0.3 %global json_version 1.7.5 @@ -695,7 +695,6 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libarchdir}/racc/cparse.so %{ruby_libarchdir}/rbconfig.rb %{ruby_libarchdir}/readline.so -%{ruby_libarchdir}/refinement.so %{ruby_libarchdir}/ripper.so %{ruby_libarchdir}/sdbm.so %{ruby_libarchdir}/socket.so @@ -795,6 +794,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Mon Jan 07 2013 Vít Ondruch - 2.0.0.0-0.1.r38732 +- Upgrade to Ruby 2.0.0 (r38732). + * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). - RDoc now depends on JSON. diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index dc6f85a..4517e0a 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -85,7 +85,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 74d803d..0063c7f 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -649,7 +649,7 @@ TEXT +@@ -641,7 +641,7 @@ TEXT say "This could take a while..." end @@ -178,7 +178,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 0063c7f..83b8fd5 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -649,7 +649,7 @@ TEXT +@@ -641,7 +641,7 @@ TEXT say "This could take a while..." end @@ -226,7 +226,7 @@ diff --git a/lib/rubygems/uninstaller.rb b/lib/rubygems/uninstaller.rb index cc32ea4..94d78e0 100644 --- a/lib/rubygems/uninstaller.rb +++ b/lib/rubygems/uninstaller.rb -@@ -234,6 +234,7 @@ class Gem::Uninstaller +@@ -246,6 +246,7 @@ class Gem::Uninstaller File.writable?(spec.base_dir) FileUtils.rm_rf spec.full_gem_path From 19c6a9831cfb8169ad6835ea11836b5efeec1244 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 8 Jan 2013 11:59:38 +0100 Subject: [PATCH 48/87] Escape example command in tapset comment. --- ruby.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ruby.spec b/ruby.spec index af0eba9..5b532dc 100644 --- a/ruby.spec +++ b/ruby.spec @@ -501,6 +501,8 @@ sed -i '/^end$/ i\ mkdir -p %{buildroot}%{tapset_dir} sed -e "s|@LIBRARY_PATH@|%{tapset_libdir}/libruby.so.%{ruby_version}|" \ %{SOURCE2} > %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp +# Escape '*/' in comment. +sed -r "s|( \*.*\*)\/(.*)|\1\\\/\2|" %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp %check DISABLE_TESTS="" From 4ba3f2a2d6dc19179fd3302997f5b31998e287ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 8 Jan 2013 12:00:25 +0100 Subject: [PATCH 49/87] Add example tapset file. --- ruby.spec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ruby.spec b/ruby.spec index 5b532dc..4f5cf79 100644 --- a/ruby.spec +++ b/ruby.spec @@ -90,6 +90,7 @@ Source0: ftp://ftp.ruby-lang.org/pub/%{name}/%{major_minor_version}/%{ruby_archi Source1: operating_system.rb # TODO: Try to push SystemTap support upstream. Source2: libruby.stp +Source3: ruby-exercise.stp # http://redmine.ruby-lang.org/issues/5231 Patch0: ruby-1.9.3-disable-versioned-paths.patch @@ -367,6 +368,9 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch9 -p1 %patch12 -p1 +# Provide an example of usage of the tapset: +cp -a %{SOURCE3} . + %build autoconf @@ -756,6 +760,7 @@ make check TESTS="-v $DISABLE_TESTS" %lang(ja) %doc README.ja %doc ChangeLog %doc doc/ChangeLog-* +%doc ruby-exercise.stp %{_datadir}/ri %files -n rubygem-bigdecimal From e653c0ad8349d30398a38e996f0a7215b69e804f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 8 Jan 2013 13:12:11 +0100 Subject: [PATCH 50/87] Add missing ruby-exercise.stp file. --- ruby-exercise.stp | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 ruby-exercise.stp diff --git a/ruby-exercise.stp b/ruby-exercise.stp new file mode 100644 index 0000000..df9df41 --- /dev/null +++ b/ruby-exercise.stp @@ -0,0 +1,39 @@ +/* Example tapset file. + * + * You can execute the tapset using following command (please adjust the path + * prior running the command, if needed): + * + * stap /usr/share/doc/ruby-2.0.0.0/ruby-exercise.stp -c "ruby -e \"puts 'test'\"" + */ + +probe ruby.cmethod.entry { + printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} + +probe ruby.cmethod.return { + printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} + +probe ruby.method.entry { + printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} + +probe ruby.method.return { + printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line); +} + +probe ruby.gc.mark.begin { printf("%d gc.mark.begin\n", tid()); } + +probe ruby.gc.mark.end { printf("%d gc.mark.end\n", tid()); } + +probe ruby.gc.sweep.begin { printf("%d gc.sweep.begin\n", tid()); } + +probe ruby.gc.sweep.end { printf("%d gc.sweep.end\n", tid()); } + +probe ruby.object.create{ + printf("%d obj.create %s %s:%d\n", tid(), classname, file, line); +} + +probe ruby.raise { + printf("%d raise %s %s:%d\n", tid(), classname, file, line); +} From 66fbf7e626de126dd91925ef50b966d8b947c319 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 8 Jan 2013 16:23:30 +0100 Subject: [PATCH 51/87] Move rubygems native extension from gems/exts into gems/%{name}. This allows to provide native extensions for alternative implementations. --- operating_system.rb | 22 +++++++++++----------- ruby.spec | 43 ++++++++++++++++++++++--------------------- 2 files changed, 33 insertions(+), 32 deletions(-) diff --git a/operating_system.rb b/operating_system.rb index b81425f..7b3930e 100644 --- a/operating_system.rb +++ b/operating_system.rb @@ -2,15 +2,14 @@ module Gem class << self ## - # Returns a string representing that part or the directory tree that is - # common to all specified directories. + # Returns full path of previous but one directory of dir in path + # E.g. for '/usr/share/ruby', 'ruby', it returns '/usr' - def common_path(dirs) - paths = dirs.collect {|dir| dir.split(File::SEPARATOR)} - uncommon_idx = paths.transpose.each_with_index.find {|dirnames, idx| dirnames.uniq.length > 1}.last - paths[0][0 ... uncommon_idx].join(File::SEPARATOR) + def previous_but_one_dir_to(path, dir) + split_path = path.split(File::SEPARATOR) + File.join(split_path.take_while { |one_dir| one_dir !~ /^#{dir}$/ }[0..-2]) end - private :common_path + private :previous_but_one_dir_to ## # Default gems locations allowed on FHS system (/usr, /usr/share). @@ -19,8 +18,8 @@ module Gem def default_locations @default_locations ||= { - :system => common_path([ConfigMap[:vendorlibdir], ConfigMap[:vendorarchdir]]), - :local => common_path([ConfigMap[:sitelibdir], ConfigMap[:sitearchdir]]) + :system => previous_but_one_dir_to(ConfigMap[:vendordir], ConfigMap[:RUBY_INSTALL_NAME]), + :local => previous_but_one_dir_to(ConfigMap[:sitedir], ConfigMap[:RUBY_INSTALL_NAME]) } end @@ -29,11 +28,12 @@ module Gem # platform independent (:gem_dir) and dependent (:ext_dir) files. def default_dirs + @libdir ||= ConfigMap[:sitelibdir] == ConfigMap[:sitearchdir] ? ConfigMap[:datadir] : ConfigMap[:libdir] @default_dirs ||= Hash[default_locations.collect do |destination, path| [destination, { :bin_dir => File.join(path, ConfigMap[:bindir].split(File::SEPARATOR).last), :gem_dir => File.join(path, ConfigMap[:datadir].split(File::SEPARATOR).last, 'gems'), - :ext_dir => File.join(path, ConfigMap[:libdir].split(File::SEPARATOR).last, 'gems') + :ext_dir => File.join(path, @libdir.split(File::SEPARATOR).last, 'gems') }] end] end @@ -64,7 +64,7 @@ module Gem def default_ext_dir_for base_dir dirs = Gem.default_dirs.detect {|location, paths| paths[:gem_dir] == base_dir} - dirs && File.join(dirs.last[:ext_dir], 'exts') + dirs && File.join(dirs.last[:ext_dir], RbConfig::CONFIG['RUBY_INSTALL_NAME']) end end end diff --git a/ruby.spec b/ruby.spec index 4f5cf79..a2c06a2 100644 --- a/ruby.spec +++ b/ruby.spec @@ -420,7 +420,7 @@ cat >> %{buildroot}%{_sysconfdir}/rpm/macros.rubygems << \EOF # Common gem locations and files. %%gem_instdir %%{gem_dir}/gems/%%{gem_name}-%%{version} -%%gem_extdir %%{_libdir}/gems/exts/%%{gem_name}-%%{version} +%%gem_extdir %%{_libdir}/gems/%{name}/%%{gem_name}-%%{version} %%gem_libdir %%{gem_instdir}/lib %%gem_cache %%{gem_dir}/cache/%%{gem_name}-%%{version}.gem %%gem_spec %%{gem_dir}/specifications/%%{gem_name}-%%{version}.gemspec @@ -435,7 +435,7 @@ cp %{SOURCE1} %{buildroot}%{rubygems_dir}/rubygems/defaults mv %{buildroot}%{ruby_libdir}/gems/2.0.0 %{buildroot}%{gem_dir} # Create folders for gem binary extensions. -mkdir -p %{buildroot}%{gem_extdir}/exts +mkdir -p %{buildroot}%{gem_extdir}/%{name} # Move bundled rubygems to %%gem_dir and %%gem_extdir # make symlinks for io-console and bigdecimal, which are considered to be part of stdlib by other Gems @@ -448,25 +448,25 @@ mv %{buildroot}%{ruby_libdir}/rdoc* %{buildroot}%{gem_dir}/gems/rdoc-%{rdoc_vers mv %{buildroot}%{gem_dir}/specifications/default/rdoc-%{rdoc_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib -mkdir -p %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib +mkdir -p %{buildroot}%{_libdir}/gems/%{name}/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{ruby_libdir}/bigdecimal %{buildroot}%{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib -mv %{buildroot}%{ruby_libarchdir}/bigdecimal.so %{buildroot}%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib +mv %{buildroot}%{ruby_libarchdir}/bigdecimal.so %{buildroot}%{_libdir}/gems/%{name}/bigdecimal-%{bigdecimal_version}/lib mv %{buildroot}%{gem_dir}/specifications/default/bigdecimal-%{bigdecimal_version}.gemspec %{buildroot}%{gem_dir}/specifications ln -s %{gem_dir}/gems/bigdecimal-%{bigdecimal_version}/lib/bigdecimal %{buildroot}%{ruby_libdir}/bigdecimal -ln -s %{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version}/lib/bigdecimal.so %{buildroot}%{ruby_libarchdir}/bigdecimal.so +ln -s %{_libdir}/gems/%{name}/bigdecimal-%{bigdecimal_version}/lib/bigdecimal.so %{buildroot}%{ruby_libarchdir}/bigdecimal.so mkdir -p %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib -mkdir -p %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io +mkdir -p %{buildroot}%{_libdir}/gems/%{name}/io-console-%{io_console_version}/lib/io mv %{buildroot}%{ruby_libdir}/io %{buildroot}%{gem_dir}/gems/io-console-%{io_console_version}/lib -mv %{buildroot}%{ruby_libarchdir}/io/console.so %{buildroot}%{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io +mv %{buildroot}%{ruby_libarchdir}/io/console.so %{buildroot}%{_libdir}/gems/%{name}/io-console-%{io_console_version}/lib/io mv %{buildroot}%{gem_dir}/specifications/default/io-console-%{io_console_version}.gemspec %{buildroot}%{gem_dir}/specifications ln -s %{gem_dir}/gems/io-console-%{io_console_version}/lib/io %{buildroot}%{ruby_libdir}/io -ln -s %{_libdir}/gems/exts/io-console-%{io_console_version}/lib/io/console.so %{buildroot}%{ruby_libarchdir}/io/console.so +ln -s %{_libdir}/gems/%{name}/io-console-%{io_console_version}/lib/io/console.so %{buildroot}%{ruby_libarchdir}/io/console.so mkdir -p %{buildroot}%{gem_dir}/gems/json-%{json_version}/lib -mkdir -p %{buildroot}%{_libdir}/gems/exts/json-%{json_version}/lib +mkdir -p %{buildroot}%{_libdir}/gems/%{name}/json-%{json_version}/lib mv %{buildroot}%{ruby_libdir}/json* %{buildroot}%{gem_dir}/gems/json-%{json_version}/lib -mv %{buildroot}%{ruby_libarchdir}/json/ %{buildroot}%{_libdir}/gems/exts/json-%{json_version}/lib/ +mv %{buildroot}%{ruby_libarchdir}/json/ %{buildroot}%{_libdir}/gems/%{name}/json-%{json_version}/lib/ mv %{buildroot}%{gem_dir}/specifications/default/json-%{json_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/minitest-%{minitest_version}/lib @@ -474,9 +474,9 @@ mv %{buildroot}%{ruby_libdir}/minitest %{buildroot}%{gem_dir}/gems/minitest-%{mi mv %{buildroot}%{gem_dir}/specifications/default/minitest-%{minitest_version}.gemspec %{buildroot}%{gem_dir}/specifications mkdir -p %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib -mkdir -p %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib +mkdir -p %{buildroot}%{_libdir}/gems/%{name}/psych-%{psych_version}/lib mv %{buildroot}%{ruby_libdir}/psych* %{buildroot}%{gem_dir}/gems/psych-%{psych_version}/lib -mv %{buildroot}%{ruby_libarchdir}/psych.so %{buildroot}%{_libdir}/gems/exts/psych-%{psych_version}/lib/ +mv %{buildroot}%{ruby_libarchdir}/psych.so %{buildroot}%{_libdir}/gems/%{name}/psych-%{psych_version}/lib/ mv %{buildroot}%{gem_dir}/specifications/default/psych-%{psych_version}.gemspec %{buildroot}%{gem_dir}/specifications # Adjust the gemspec files so that the gems will load properly @@ -504,7 +504,7 @@ sed -i '/^end$/ i\ # Install a tapset and fix up the path to the library. mkdir -p %{buildroot}%{tapset_dir} sed -e "s|@LIBRARY_PATH@|%{tapset_libdir}/libruby.so.%{ruby_version}|" \ - %{SOURCE2} > %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp + %{SOURCE2} > %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp # Escape '*/' in comment. sed -r "s|( \*.*\*)\/(.*)|\1\\\/\2|" %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp @@ -719,10 +719,10 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir} %exclude %{gem_dir}/gems/* %{_exec_prefix}/lib*/gems -%exclude %{_exec_prefix}/lib*/gems/exts/bigdecimal-%{bigdecimal_version} -%exclude %{_exec_prefix}/lib*/gems/exts/io-console-%{io_console_version} -%exclude %{_exec_prefix}/lib*/gems/exts/json-%{json_version} -%exclude %{_exec_prefix}/lib*/gems/exts/psych-%{psych_version} +%exclude %{_exec_prefix}/lib*/gems/%{name}/bigdecimal-%{bigdecimal_version} +%exclude %{_exec_prefix}/lib*/gems/%{name}/io-console-%{io_console_version} +%exclude %{_exec_prefix}/lib*/gems/%{name}/json-%{json_version} +%exclude %{_exec_prefix}/lib*/gems/%{name}/psych-%{psych_version} %exclude %{gem_dir}/gems/rake-%{rake_version} %exclude %{gem_dir}/gems/rdoc-%{rdoc_version} %exclude %{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec @@ -766,19 +766,19 @@ make check TESTS="-v $DISABLE_TESTS" %files -n rubygem-bigdecimal %{ruby_libdir}/bigdecimal %{ruby_libarchdir}/bigdecimal.so -%{_libdir}/gems/exts/bigdecimal-%{bigdecimal_version} +%{_libdir}/gems/%{name}/bigdecimal-%{bigdecimal_version} %{gem_dir}/gems/bigdecimal-%{bigdecimal_version} %{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec %files -n rubygem-io-console %{ruby_libdir}/io %{ruby_libarchdir}/io/console.so -%{_libdir}/gems/exts/io-console-%{io_console_version} +%{_libdir}/gems/%{name}/io-console-%{io_console_version} %{gem_dir}/gems/io-console-%{io_console_version} %{gem_dir}/specifications/io-console-%{io_console_version}.gemspec %files -n rubygem-json -%{_libdir}/gems/exts/json-%{json_version} +%{_libdir}/gems/%{name}/json-%{json_version} %{gem_dir}/gems/json-%{json_version} %{gem_dir}/specifications/json-%{json_version}.gemspec @@ -787,7 +787,7 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir}/specifications/minitest-%{minitest_version}.gemspec %files -n rubygem-psych -%{_libdir}/gems/exts/psych-%{psych_version} +%{_libdir}/gems/%{name}/psych-%{psych_version} %{gem_dir}/gems/psych-%{psych_version} %{gem_dir}/specifications/psych-%{psych_version}.gemspec @@ -803,6 +803,7 @@ make check TESTS="-v $DISABLE_TESTS" %changelog * Mon Jan 07 2013 Vít Ondruch - 2.0.0.0-0.1.r38732 - Upgrade to Ruby 2.0.0 (r38732). +- Move native extensions from exts to ruby directory. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). From 7981fb51bbef73bd7421baba6ba94513c02bdc8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 8 Jan 2013 16:28:55 +0100 Subject: [PATCH 52/87] Bump ruby(abi), since rubygems layout is now incompatible anyway. --- ruby.spec | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/ruby.spec b/ruby.spec index a2c06a2..3e61297 100644 --- a/ruby.spec +++ b/ruby.spec @@ -7,11 +7,7 @@ %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_version_patch_level %{major_minor_version}.%{teeny_version}.%{patch_level} -# TODO: Fix ruby_api for official release according to -# http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/48984 -# It is kept at 1.9.1 just for testing. All dependent libraries need rebuild. -# %%global ruby_abi %%{major_minor_version}.0 -%global ruby_abi 1.9.1 +%global ruby_abi %{ruby_version} # Specify the named version. It has precedense to revision. #%%global milestone preview2 From baf41b2211926ddb494008f5352d760ba5cc28ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 16 Jan 2013 16:17:47 +0100 Subject: [PATCH 53/87] Upgrade to Ruby 2.0.0 (r38848). --- ruby.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index 3e61297..2c5ca8f 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38732 +%global revision 38848 %global ruby_archive %{name}-%{ruby_version} @@ -797,8 +797,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Mon Jan 07 2013 Vít Ondruch - 2.0.0.0-0.1.r38732 -- Upgrade to Ruby 2.0.0 (r38732). +* Wed Jan 16 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 +- Upgrade to Ruby 2.0.0 (r38848). - Move native extensions from exts to ruby directory. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 From 3e8ccc1ce677ef739347417c3cfdb312b1b335b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 17 Jan 2013 15:10:39 +0100 Subject: [PATCH 54/87] Provide nonversioned packageconfig (rhbz#789532). --- ruby.spec | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index 2c5ca8f..a0dcac9 100644 --- a/ruby.spec +++ b/ruby.spec @@ -379,6 +379,7 @@ autoconf --with-vendorarchdir='%{ruby_vendorarchdir}' \ --with-rubyhdrdir='%{_includedir}' \ --with-rubygemsdir='%{rubygems_dir}' \ + --with-ruby-pc='%{name}.pc' \ --disable-rpath \ --enable-shared \ --disable-versioned-paths @@ -550,7 +551,7 @@ make check TESTS="-v $DISABLE_TESTS" %{_includedir}/%{_normalized_cpu}-%{_target_os}/ruby %{_libdir}/libruby.so -%{_libdir}/pkgconfig/ruby-%{major_minor_version}.pc +%{_libdir}/pkgconfig/%{name}.pc %files libs %doc COPYING @@ -797,8 +798,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Wed Jan 16 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 +* Thu Jan 17 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 - Upgrade to Ruby 2.0.0 (r38848). +- Provide nonversioned packageconfig (rhbz#789532). - Move native extensions from exts to ruby directory. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 From 155533e0ccbec690000d7ea9a9c49079da687c48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 18 Jan 2013 12:36:59 +0100 Subject: [PATCH 55/87] Remove unneeded patch. --- ...0-r36832-rb_float_value-optimization.patch | 46 ------------------- 1 file changed, 46 deletions(-) delete mode 100644 ruby-2.0-r36832-rb_float_value-optimization.patch diff --git a/ruby-2.0-r36832-rb_float_value-optimization.patch b/ruby-2.0-r36832-rb_float_value-optimization.patch deleted file mode 100644 index 97dc58b..0000000 --- a/ruby-2.0-r36832-rb_float_value-optimization.patch +++ /dev/null @@ -1,46 +0,0 @@ -From 0b89d6d5f9f8c788f4391d8a0499f10aed624371 Mon Sep 17 00:00:00 2001 -From: ko1 -Date: Mon, 27 Aug 2012 09:22:21 +0000 -Subject: [PATCH] * include/ruby/ruby.h (rb_float_value): optimize it. This - technique was pointed by shinichiro.hamaji - . - -git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e ---- - ChangeLog | 6 ++++++ - include/ruby/ruby.h | 10 +++++----- - 2 files changed, 11 insertions(+), 5 deletions(-) - -diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h -index 3905b32..b8b2267 100644 ---- a/include/ruby/ruby.h -+++ b/include/ruby/ruby.h -@@ -733,10 +733,7 @@ struct RFloat { - rb_float_value(VALUE v) - { - if (FLONUM_P(v)) { -- if (v == (VALUE)0x8000000000000002) { -- return 0.0; -- } -- else { -+ if (v != (VALUE)0x8000000000000002) { /* LIKELY */ - union { - double d; - VALUE v; -@@ -746,9 +743,12 @@ struct RFloat { - /* e: xx1... -> 011... */ - /* xx0... -> 100... */ - /* ^b63 */ -- t.v = RUBY_BIT_ROTR(((b63 ^ 1) << 1) | b63 | (v & ~0x03), 3); -+ t.v = RUBY_BIT_ROTR(2 - b63 | (v & ~0x03), 3); - return t.d; - } -+ else { -+ return 0.0; -+ } - } - else { - return ((struct RFloat *)v)->float_value; --- -1.7.10 - From a80c9ddd65ef0e8d223cd9e576600724087ab600 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 18 Jan 2013 12:37:26 +0100 Subject: [PATCH 56/87] Build against libdb instead of libdb4 (rhbz#894022). --- ruby.spec | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index a0dcac9..cdbb3af 100644 --- a/ruby.spec +++ b/ruby.spec @@ -119,7 +119,7 @@ Requires: rubygem(bigdecimal) >= %{bigdecimal_version} BuildRequires: autoconf BuildRequires: gdbm-devel BuildRequires: ncurses-devel -BuildRequires: db4-devel +BuildRequires: libdb-devel BuildRequires: libffi-devel BuildRequires: openssl-devel BuildRequires: libyaml-devel @@ -798,8 +798,9 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Thu Jan 17 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 +* Fri Jan 18 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 - Upgrade to Ruby 2.0.0 (r38848). +- Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532). - Move native extensions from exts to ruby directory. From fd812ccb12aff4611ee6b0617686802e1ee58661 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 18 Jan 2013 16:28:03 +0100 Subject: [PATCH 57/87] Fix variables provided by ruby.pc (rhbz#789532, comment 8). --- ...pc-variable-by-configuration-process.patch | 35 +++++++++++++++++++ ruby.spec | 6 +++- 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch diff --git a/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch b/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch new file mode 100644 index 0000000..20dd78d --- /dev/null +++ b/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch @@ -0,0 +1,35 @@ +From bf4959bc763167b2245a5f4c699fcb72afead5a5 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Fri, 18 Jan 2013 15:51:49 +0100 +Subject: [PATCH] Expand ruby.pc variable by configuration process. + +--- + template/ruby.pc.in | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/template/ruby.pc.in b/template/ruby.pc.in +index 2d6716c..25e42f3 100644 +--- a/template/ruby.pc.in ++++ b/template/ruby.pc.in +@@ -25,12 +25,12 @@ LIBS=@LIBS@ + DLDFLAGS=@DLDFLAGS@ + ruby=${bindir}/${RUBY_INSTALL_NAME}@EXEEXT@ + rubylibprefix=@rubylibprefix@ +-rubylibdir=${rubylibprefix}/${ruby_version} +-vendordir=${rubylibprefix}/vendor_ruby +-sitedir=${rubylibprefix}/site_ruby +-rubyarchdir=${rubylibdir}/${arch} +-vendorarchdir=${vendordir}/${sitearch} +-sitearchdir=${sitedir}/${sitearch} ++rubylibdir=@rubylibprefix@ ++vendordir=@vendordir@ ++sitedir=@sitedir@ ++rubyarchdir=@archdir@ ++vendorarchdir=@vendorarchdir@ ++sitearchdir=@sitearchdir@ + rubyhdrdir=@rubyhdrdir@ + vendorhdrdir=@vendorhdrdir@ + sitehdrdir=@sitehdrdir@ +-- +1.8.0.2 + diff --git a/ruby.spec b/ruby.spec index cdbb3af..37e3233 100644 --- a/ruby.spec +++ b/ruby.spec @@ -105,6 +105,9 @@ Patch8: ruby-1.9.3-custom-rubygems-location.patch # Add support for installing binary extensions according to FHS. # https://github.com/rubygems/rubygems/issues/210 Patch9: rubygems-1.8.11-binary-extensions.patch +# Fixes issues mentioned in rhbz#789532, comment 8. +# TODO: Should be probably upstreamed with #5281. +Patch10: ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch @@ -362,6 +365,7 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch4 -p1 %patch8 -p1 %patch9 -p1 +%patch10 -p1 %patch12 -p1 # Provide an example of usage of the tapset: @@ -801,7 +805,7 @@ make check TESTS="-v $DISABLE_TESTS" * Fri Jan 18 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 - Upgrade to Ruby 2.0.0 (r38848). - Build against libdb instead of libdb4 (rhbz#894022). -- Provide nonversioned packageconfig (rhbz#789532). +- Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 From 6bc04a3163355e155238f017b8b0ae4a466a6c4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 21 Jan 2013 18:00:52 +0100 Subject: [PATCH 58/87] Enable most of the PPC test suite. --- ruby.spec | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index 37e3233..30e8397 100644 --- a/ruby.spec +++ b/ruby.spec @@ -518,10 +518,20 @@ DISABLE_TESTS="" DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" %endif -%ifnarch ppc ppc64 -make check TESTS="-v $DISABLE_TESTS" +%ifarch ppc ppc64 +# test_ioctl_linux(TestIO) fails with #. +# https://bugs.ruby-lang.org/issues/7718 +DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" %endif +%ifarch ppc +# test_stack_size(TestFiber) fails. +# https://bugs.ruby-lang.org/issues/7719 +DISABLE_TESTS="-x test_fiber.rb $DISABLE_TESTS" +%endif + +make check TESTS="-v $DISABLE_TESTS" + %post libs -p /sbin/ldconfig %postun libs -p /sbin/ldconfig @@ -802,11 +812,12 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Fri Jan 18 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 +* Mon Jan 21 2013 Vít Ondruch - 2.0.0.0-0.1.r38848 - Upgrade to Ruby 2.0.0 (r38848). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. +- Enable most of the PPC test suite. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). From de0a9ae9f2b6b5259fa2c095d0229e333ab7e49f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 22 Jan 2013 15:52:00 +0100 Subject: [PATCH 59/87] Upgrade to Ruby 2.0.0 (r38894). Enable test_stack_size(TestFiber) on PPC, since it was fixed upstream. --- ...9.3-added-site-and-vendor-arch-flags.patch | 6 ++--- ruby-1.9.3-arch-specific-dir.patch | 6 ++--- ruby-1.9.3-custom-rubygems-location.patch | 2 +- ruby-1.9.3-disable-versioned-paths.patch | 6 ++--- ruby-1.9.3-mkmf-verbose.patch | 2 +- ruby.spec | 12 +++------- rubygems-1.8.11-binary-extensions.patch | 22 +++++++++---------- 7 files changed, 25 insertions(+), 31 deletions(-) diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch index 45dbc08..c3b007b 100644 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch @@ -134,7 +134,7 @@ diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb index 03c3332..79b8e44 100755 --- a/tool/mkconfig.rb +++ b/tool/mkconfig.rb -@@ -44,6 +44,8 @@ continued_name = nil +@@ -45,6 +45,8 @@ continued_name = nil continued_line = nil path_version = "/$(ruby_version)" archdir_override = "$(vendorlibdir)/$(sitearch)" @@ -143,7 +143,7 @@ index 03c3332..79b8e44 100755 File.foreach "config.status" do |line| next if /^#/ =~ line name = nil -@@ -80,6 +82,8 @@ File.foreach "config.status" do |line| +@@ -81,6 +83,8 @@ File.foreach "config.status" do |line| when /^RUBY_SO_NAME$/; next if $so_name when /^arch$/; if val.empty? then val = arch else arch = val end when /^archdir$/; archdir_override = val; next @@ -152,7 +152,7 @@ index 03c3332..79b8e44 100755 when /^sitearch/; val = '$(arch)' if val.empty? end case val -@@ -214,11 +218,11 @@ print < - 2.0.0.0-0.1.r38848 -- Upgrade to Ruby 2.0.0 (r38848). +* Mon Jan 21 2013 Vít Ondruch - 2.0.0.0-0.1.r38894 +- Upgrade to Ruby 2.0.0 (r38894). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index 4517e0a..e158896 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -11,7 +11,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 97db19e..263e7d3 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1250,6 +1250,12 @@ class Gem::Specification +@@ -1256,6 +1256,12 @@ class Gem::Specification File.join full_gem_path, path end @@ -24,7 +24,7 @@ index 97db19e..263e7d3 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1368,11 +1374,16 @@ class Gem::Specification +@@ -1374,11 +1380,16 @@ class Gem::Specification def contains_requirable_file? file root = full_gem_path @@ -43,7 +43,7 @@ index 97db19e..263e7d3 100644 end end -@@ -1668,6 +1679,23 @@ class Gem::Specification +@@ -1674,6 +1685,23 @@ class Gem::Specification end ## @@ -85,7 +85,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 74d803d..0063c7f 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -641,7 +641,7 @@ TEXT +@@ -642,7 +642,7 @@ TEXT say "This could take a while..." end @@ -98,7 +98,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 263e7d3..d31b93b 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1683,16 +1683,15 @@ class Gem::Specification +@@ -1689,16 +1689,15 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -135,7 +135,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index d31b93b..e65ea2d 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1250,11 +1250,7 @@ class Gem::Specification +@@ -1256,11 +1256,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -148,7 +148,7 @@ index d31b93b..e65ea2d 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1691,7 +1687,10 @@ class Gem::Specification +@@ -1697,7 +1693,10 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir @@ -178,7 +178,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 0063c7f..83b8fd5 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -641,7 +641,7 @@ TEXT +@@ -642,7 +642,7 @@ TEXT say "This could take a while..." end @@ -191,7 +191,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index e65ea2d..8be2ade 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1250,7 +1250,7 @@ class Gem::Specification +@@ -1256,7 +1256,7 @@ class Gem::Specification File.join full_gem_path, path end @@ -200,7 +200,7 @@ index e65ea2d..8be2ade 100644 # gem directories must come after -I and ENV['RUBYLIB'] insert_index = Gem.load_path_insert_index -@@ -1679,7 +1679,7 @@ class Gem::Specification +@@ -1685,7 +1685,7 @@ class Gem::Specification # eg: /usr/local/lib/ruby/1.8/exts/mygem-1.0 def ext_dir @@ -274,7 +274,7 @@ diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb index 8be2ade..f54210a 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb -@@ -1687,10 +1687,7 @@ class Gem::Specification +@@ -1693,10 +1693,7 @@ class Gem::Specification # gem directory. eg: /usr/local/lib/ruby/1.8/gems def exts_dir From badae78597409c822c63c41ef8784d70faf372c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 22 Jan 2013 17:06:43 +0100 Subject: [PATCH 60/87] Let Sed escape in original file. --- ruby.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ruby.spec b/ruby.spec index 6d5b5bc..8bbf490 100644 --- a/ruby.spec +++ b/ruby.spec @@ -69,7 +69,7 @@ # Might not be needed in the future, if we are lucky enough. # https://bugzilla.redhat.com/show_bug.cgi?id=888262 %global tapset_root %{_datadir}/systemtap -%global tapset_dir %{tapset_root}/tapset/ +%global tapset_dir %{tapset_root}/tapset %global tapset_libdir %(echo %{_libdir} | sed 's/64//')* %global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/') @@ -507,7 +507,7 @@ mkdir -p %{buildroot}%{tapset_dir} sed -e "s|@LIBRARY_PATH@|%{tapset_libdir}/libruby.so.%{ruby_version}|" \ %{SOURCE2} > %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp # Escape '*/' in comment. -sed -r "s|( \*.*\*)\/(.*)|\1\\\/\2|" %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp +sed -i -r "s|( \*.*\*)\/(.*)|\1\\\/\2|" %{buildroot}%{tapset_dir}/libruby.so.%{ruby_version}.stp %check DISABLE_TESTS="" From 541f694eeec7d343e5e85a94704520ae8a33ba54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 24 Jan 2013 15:42:10 +0100 Subject: [PATCH 61/87] Change ruby(abi) -> ruby(release). --- ruby.spec | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/ruby.spec b/ruby.spec index 8bbf490..5b2d0c9 100644 --- a/ruby.spec +++ b/ruby.spec @@ -7,7 +7,7 @@ %global ruby_version %{major_minor_version}.%{teeny_version} %global ruby_version_patch_level %{major_minor_version}.%{teeny_version}.%{patch_level} -%global ruby_abi %{ruby_version} +%global ruby_release %{ruby_version} # Specify the named version. It has precedense to revision. #%%global milestone preview2 @@ -153,7 +153,7 @@ Ruby or an application embedding Ruby. Summary: Libraries necessary to run Ruby Group: Development/Libraries License: Ruby or BSD -Provides: ruby(abi) = %{ruby_abi} +Provides: ruby(release) = %{ruby_release} %description libs This package includes the libruby, necessary to run Ruby. @@ -164,7 +164,7 @@ Summary: The Ruby standard for packaging ruby libraries Version: %{rubygems_version} Group: Development/Libraries License: Ruby or MIT -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: rubygem(rdoc) >= %{rdoc_version} Requires: rubygem(io-console) >= %{io_console_version} Requires: rubygem(psych) >= %{psych_version} @@ -194,7 +194,7 @@ Summary: Ruby based make-like utility Version: %{rake_version} Group: Development/Libraries License: Ruby or MIT -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rake = %{version}-%{release} Provides: rubygem(rake) = %{version}-%{release} @@ -224,7 +224,7 @@ Summary: A tool to generate HTML and command-line documentation for Ruby proj Version: %{rdoc_version} Group: Development/Libraries License: GPLv2 and Ruby and MIT -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Requires: ruby(irb) = %{irb_version} Requires: rubygem(json) >= %{json_version} @@ -256,7 +256,7 @@ Summary: BigDecimal provides arbitrary-precision floating point decimal arith Version: %{bigdecimal_version} Group: Development/Libraries License: GPL+ or Artistic -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(bigdecimal) = %{version}-%{release} @@ -277,7 +277,7 @@ conversion between base 10 and base 2. Summary: IO/Console is a simple console utilizing library Version: %{io_console_version} Group: Development/Libraries -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(io-console) = %{version}-%{release} @@ -291,7 +291,7 @@ Summary: This is a JSON implementation as a Ruby extension in C Version: %{json_version} Group: Development/Libraries License: Ruby or GPLv2 -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(json) = %{version}-%{release} @@ -307,7 +307,7 @@ Summary: Minitest provides a complete suite of testing facilities Version: %{minitest_version} Group: Development/Libraries License: MIT -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(minitest) = %{version}-%{release} BuildArch: noarch @@ -332,7 +332,7 @@ Summary: A libyaml wrapper for Ruby Version: %{psych_version} Group: Development/Libraries License: MIT -Requires: ruby(abi) = %{ruby_abi} +Requires: ruby(release) = %{ruby_release} Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(psych) = %{version}-%{release} @@ -806,12 +806,13 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Mon Jan 21 2013 Vít Ondruch - 2.0.0.0-0.1.r38894 +* Thu Jan 24 2013 Vít Ondruch - 2.0.0.0-0.1.r38894 - Upgrade to Ruby 2.0.0 (r38894). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. - Enable most of the PPC test suite. +- Change ruby(abi) -> ruby(release). * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). From d7fb70fa9f9c930041d87ac96fda9ffa1b481723 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 24 Jan 2013 16:08:55 +0100 Subject: [PATCH 62/87] Rename ruby executable to ruby-mri, to be prepared for RubyPick. --- ruby.spec | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 5b2d0c9..8a7e258 100644 --- a/ruby.spec +++ b/ruby.spec @@ -397,6 +397,9 @@ make %{?_smp_mflags} COPY="cp -p" Q= rm -rf %{buildroot} make install DESTDIR=%{buildroot} +# Rename the ruby executable. It is replaced by RubyPick. +mv %{buildroot}%{_bindir}/%{name}{,-mri} + # Dump the macros into macro.ruby to use them to build other Ruby libraries. mkdir -p %{buildroot}%{_sysconfdir}/rpm cat >> %{buildroot}%{_sysconfdir}/rpm/macros.ruby << \EOF @@ -536,7 +539,7 @@ make check TESTS="-v $DISABLE_TESTS" %doc GPL %doc LEGAL %{_bindir}/erb -%{_bindir}/ruby +%{_bindir}/%{name}-mri %{_bindir}/testrb %{_mandir}/man1/erb* %{_mandir}/man1/ruby* @@ -813,6 +816,7 @@ make check TESTS="-v $DISABLE_TESTS" - Move native extensions from exts to ruby directory. - Enable most of the PPC test suite. - Change ruby(abi) -> ruby(release). +- Rename ruby executable to ruby-mri, to be prepared for RubyPick. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). From eccebe4d3f8bcb984fe3f9f818c14bc1a15a0e18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 24 Jan 2013 16:58:41 +0100 Subject: [PATCH 63/87] Upgrade to Ruby 2.0.0 (r38929). --- ruby.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index 8a7e258..bf14c6f 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38894 +%global revision 38929 %global ruby_archive %{name}-%{ruby_version} @@ -809,8 +809,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Thu Jan 24 2013 Vít Ondruch - 2.0.0.0-0.1.r38894 -- Upgrade to Ruby 2.0.0 (r38894). +* Thu Jan 24 2013 Vít Ondruch - 2.0.0.0-0.1.r38929 +- Upgrade to Ruby 2.0.0 (r38929). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. From 6b249d044c40b06b29402286029ee0392a41a002 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 4 Feb 2013 17:23:28 +0100 Subject: [PATCH 64/87] Drop versioned ruby(release) dependencies. --- ruby.spec | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/ruby.spec b/ruby.spec index bf14c6f..02a8c03 100644 --- a/ruby.spec +++ b/ruby.spec @@ -164,7 +164,7 @@ Summary: The Ruby standard for packaging ruby libraries Version: %{rubygems_version} Group: Development/Libraries License: Ruby or MIT -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: rubygem(rdoc) >= %{rdoc_version} Requires: rubygem(io-console) >= %{io_console_version} Requires: rubygem(psych) >= %{psych_version} @@ -194,7 +194,7 @@ Summary: Ruby based make-like utility Version: %{rake_version} Group: Development/Libraries License: Ruby or MIT -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rake = %{version}-%{release} Provides: rubygem(rake) = %{version}-%{release} @@ -224,7 +224,7 @@ Summary: A tool to generate HTML and command-line documentation for Ruby proj Version: %{rdoc_version} Group: Development/Libraries License: GPLv2 and Ruby and MIT -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Requires: ruby(irb) = %{irb_version} Requires: rubygem(json) >= %{json_version} @@ -256,7 +256,7 @@ Summary: BigDecimal provides arbitrary-precision floating point decimal arith Version: %{bigdecimal_version} Group: Development/Libraries License: GPL+ or Artistic -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(bigdecimal) = %{version}-%{release} @@ -277,7 +277,7 @@ conversion between base 10 and base 2. Summary: IO/Console is a simple console utilizing library Version: %{io_console_version} Group: Development/Libraries -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(io-console) = %{version}-%{release} @@ -291,7 +291,7 @@ Summary: This is a JSON implementation as a Ruby extension in C Version: %{json_version} Group: Development/Libraries License: Ruby or GPLv2 -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(json) = %{version}-%{release} @@ -307,7 +307,7 @@ Summary: Minitest provides a complete suite of testing facilities Version: %{minitest_version} Group: Development/Libraries License: MIT -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(minitest) = %{version}-%{release} BuildArch: noarch @@ -332,7 +332,7 @@ Summary: A libyaml wrapper for Ruby Version: %{psych_version} Group: Development/Libraries License: MIT -Requires: ruby(release) = %{ruby_release} +Requires: ruby(release) Requires: ruby(rubygems) >= %{rubygems_version} Provides: rubygem(psych) = %{version}-%{release} From 0f8a636163755b34974e94eb77f3869362c9dd5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 6 Feb 2013 14:43:39 +0100 Subject: [PATCH 65/87] Upgrade to Ruby 2.0.0 (r39070). --- ruby.spec | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ruby.spec b/ruby.spec index 02a8c03..623f241 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 38929 +%global revision 39070 %global ruby_archive %{name}-%{ruby_version} @@ -42,7 +42,7 @@ %global ruby_vendorlibdir %{_datadir}/ruby/%{ruby_vendordir} %global ruby_vendorarchdir %{_libdir}/ruby/%{ruby_vendordir} -%global rubygems_version 2.0.0.preview3.1 +%global rubygems_version 2.0.0.rc.2 # The RubyGems library has to stay out of Ruby directory three, since the # RubyGems should be share by all Ruby implementations. @@ -61,7 +61,7 @@ %global irb_version %{ruby_version_patch_level} %global rdoc_version 4.0.0.preview3.1 %global bigdecimal_version 1.1.0 -%global io_console_version 0.3 +%global io_console_version 0.4.1 %global json_version 1.7.5 %global minitest_version 4.3.2 %global psych_version 2.0.0 @@ -809,8 +809,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Thu Jan 24 2013 Vít Ondruch - 2.0.0.0-0.1.r38929 -- Upgrade to Ruby 2.0.0 (r38929). +* Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.2.r39070 +- Upgrade to Ruby 2.0.0 (r39070). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. From f5ddaaacec8528bdaffb23150162744cc791b439 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 6 Feb 2013 14:45:54 +0100 Subject: [PATCH 66/87] Add ruby(runtime_executable) virtual provide, which is later used by RubyPick. --- ruby.spec | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ruby.spec b/ruby.spec index 623f241..8ebe63c 100644 --- a/ruby.spec +++ b/ruby.spec @@ -132,6 +132,10 @@ BuildRequires: tk-devel BuildRequires: procps BuildRequires: %{_bindir}/dtrace +# This package provides %%{_bindir}/ruby-mri therefore it is marked by this +# virtual provide. It can be installed as dependency of rubypick. +Provides: ruby(runtime_executable) = %{ruby_release} + %description Ruby is the interpreted scripting language for quick and easy object-oriented programming. It has many features to process text @@ -817,6 +821,8 @@ make check TESTS="-v $DISABLE_TESTS" - Enable most of the PPC test suite. - Change ruby(abi) -> ruby(release). - Rename ruby executable to ruby-mri, to be prepared for RubyPick. +- Add ruby(runtime_executable) virtual provide, which is later used + by RubyPick. * Mon Dec 10 2012 Vít Ondruch - 2.0.0.0-0.1.r38422 - Upgrade to Ruby 2.0.0 (r38422). From 6a5a970443c0d6a434f14926cde523bda7886705 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 6 Feb 2013 16:56:47 +0100 Subject: [PATCH 67/87] Fix "gem install --install-dir" behavior. --- ruby.spec | 7 ++ rubygems-1.8.11-binary-extensions.patch | 81 ++++++++++++------- ...obal-Specification.dirs-during-insta.patch | 33 ++++++++ 3 files changed, 94 insertions(+), 27 deletions(-) create mode 100644 rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch diff --git a/ruby.spec b/ruby.spec index 8ebe63c..ae3775a 100644 --- a/ruby.spec +++ b/ruby.spec @@ -110,6 +110,12 @@ Patch9: rubygems-1.8.11-binary-extensions.patch Patch10: ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch +# This slightly changes behavior of "gem install --install-dir" behavior. +# Without this patch, Specifications.dirs is modified and gems installed on +# the system cannot be required anymore. This causes later issues when RDoc +# documentation should be generated, since json gem is sudenly not accessible. +# https://github.com/rubygems/rubygems/pull/442 +Patch13: rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} @@ -371,6 +377,7 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch9 -p1 %patch10 -p1 %patch12 -p1 +%patch13 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-1.8.11-binary-extensions.patch index e158896..43f3599 100644 --- a/rubygems-1.8.11-binary-extensions.patch +++ b/rubygems-1.8.11-binary-extensions.patch @@ -1,14 +1,14 @@ -From 5a37a3489491a33f2e7011043fbbcd9a765e1777 Mon Sep 17 00:00:00 2001 +From ec90622235ae19b28a327cb50a10e0311e8f3d71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 3 Nov 2011 16:43:05 +0100 -Subject: [PATCH 1/6] Add dedicate extensions folder into $LOAD_PATH. +Subject: [PATCH 1/7] Add dedicate extensions folder into $LOAD_PATH. --- lib/rubygems/specification.rb | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb -index 97db19e..263e7d3 100644 +index cabdf8d..87b14d2 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb @@ -1256,6 +1256,12 @@ class Gem::Specification @@ -68,13 +68,13 @@ index 97db19e..263e7d3 100644 # # Formerly used to indicate this gem was RDoc-capable. -- -1.8.0 +1.8.1 -From 671e4285bf9db948bc5f054d7d3d931cdd7a17f8 Mon Sep 17 00:00:00 2001 +From e42819f32fc5d935f7e7189ec4be8bdab0a2cf3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 16 Nov 2011 13:26:48 +0100 -Subject: [PATCH 2/6] Use spec's ext dir for extension installation. +Subject: [PATCH 2/7] Use spec's ext dir for extension installation. --- lib/rubygems/installer.rb | 2 +- @@ -82,7 +82,7 @@ Subject: [PATCH 2/6] Use spec's ext dir for extension installation. 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb -index 74d803d..0063c7f 100644 +index 780a88b..854c177 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb @@ -642,7 +642,7 @@ TEXT @@ -95,7 +95,7 @@ index 74d803d..0063c7f 100644 spec.extensions.each do |extension| diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb -index 263e7d3..d31b93b 100644 +index 87b14d2..492ddbe 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb @@ -1689,16 +1689,15 @@ class Gem::Specification @@ -119,20 +119,20 @@ index 263e7d3..d31b93b 100644 ## -- -1.8.0 +1.8.1 -From 11b4a0cbadd8b1d3320f838881aa60feb6f848e7 Mon Sep 17 00:00:00 2001 +From 0e9dd0655111f7dda805233c79a3771459d9a66a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 16 Nov 2011 14:52:16 +0100 -Subject: [PATCH 3/6] Simplify the extending of $LOAD_PATH for binary gems. +Subject: [PATCH 3/7] Simplify the extending of $LOAD_PATH for binary gems. --- lib/rubygems/specification.rb | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb -index d31b93b..e65ea2d 100644 +index 492ddbe..c703827 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb @@ -1256,11 +1256,7 @@ class Gem::Specification @@ -161,13 +161,13 @@ index d31b93b..e65ea2d 100644 ## -- -1.8.0 +1.8.1 -From 5d46cd2b1ac9517a9cbcfa430261e62bb3a376b8 Mon Sep 17 00:00:00 2001 +From 9a8556c609e800d0dbd24af416d613f2e82f323c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 9 Dec 2011 16:31:04 +0100 -Subject: [PATCH 4/6] Fix the binary extension search path construction. +Subject: [PATCH 4/7] Fix the binary extension search path construction. --- lib/rubygems/installer.rb | 2 +- @@ -175,7 +175,7 @@ Subject: [PATCH 4/6] Fix the binary extension search path construction. 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb -index 0063c7f..83b8fd5 100644 +index 854c177..f1f2ad7 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb @@ -642,7 +642,7 @@ TEXT @@ -188,7 +188,7 @@ index 0063c7f..83b8fd5 100644 spec.extensions.each do |extension| diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb -index e65ea2d..8be2ade 100644 +index c703827..fa9ea6e 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb @@ -1256,7 +1256,7 @@ class Gem::Specification @@ -210,20 +210,20 @@ index e65ea2d..8be2ade 100644 ## -- -1.8.0 +1.8.1 -From 6229583633802b45e5a3e5689ab9077347cd9ef7 Mon Sep 17 00:00:00 2001 +From 476c2f90cc6f5f490858f253a9b23eb19d53d2fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 13 Dec 2011 12:14:54 +0100 -Subject: [PATCH 5/6] Remove binary extensions during uninstall. +Subject: [PATCH 5/7] Remove binary extensions during uninstall. --- lib/rubygems/uninstaller.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/rubygems/uninstaller.rb b/lib/rubygems/uninstaller.rb -index cc32ea4..94d78e0 100644 +index d672b9d..5c31a0c 100644 --- a/lib/rubygems/uninstaller.rb +++ b/lib/rubygems/uninstaller.rb @@ -246,6 +246,7 @@ class Gem::Uninstaller @@ -235,13 +235,13 @@ index cc32ea4..94d78e0 100644 # TODO: should this be moved to spec?... I vote eww (also exists in docmgr) old_platform_name = [spec.name, -- -1.8.0 +1.8.1 -From bc40e1b9f60a9a04456e3504ffe6ee600b6da269 Mon Sep 17 00:00:00 2001 +From 35dc17e86f701fe1be80d98ace79735c535fd570 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 13 Dec 2011 14:27:14 +0100 -Subject: [PATCH 6/6] Avoid dependency on customized operating_system.rb. +Subject: [PATCH 6/7] Avoid dependency on customized operating_system.rb. --- lib/rubygems/defaults.rb | 11 +++++++++++ @@ -249,7 +249,7 @@ Subject: [PATCH 6/6] Avoid dependency on customized operating_system.rb. 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb -index 20b4198..6d8711f 100644 +index ea84e5c..b221954 100644 --- a/lib/rubygems/defaults.rb +++ b/lib/rubygems/defaults.rb @@ -101,6 +101,17 @@ module Gem @@ -271,7 +271,7 @@ index 20b4198..6d8711f 100644 def self.ruby_engine diff --git a/lib/rubygems/specification.rb b/lib/rubygems/specification.rb -index 8be2ade..f54210a 100644 +index fa9ea6e..2b10499 100644 --- a/lib/rubygems/specification.rb +++ b/lib/rubygems/specification.rb @@ -1693,10 +1693,7 @@ class Gem::Specification @@ -287,5 +287,32 @@ index 8be2ade..f54210a 100644 ## -- -1.8.0 +1.8.1 + + +From 0937c0b0a3c2ed08ab5b0875f7f95e24157525c2 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Thu, 7 Feb 2013 13:07:34 +0100 +Subject: [PATCH 7/7] Fix binary extensions installation when --install-dir is + specified. + +--- + lib/rubygems/installer.rb | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb +index f1f2ad7..e1577fc 100644 +--- a/lib/rubygems/installer.rb ++++ b/lib/rubygems/installer.rb +@@ -642,7 +642,7 @@ TEXT + say "This could take a while..." + end + +- dest_path = File.join spec.ext_dir, spec.require_paths.first ++ dest_path = File.join(options[:install_dir] ? gem_dir : spec.ext_dir, spec.require_paths.first) + ran_rake = false # only run rake once + + spec.extensions.each do |extension| +-- +1.8.1 diff --git a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch new file mode 100644 index 0000000..8747b88 --- /dev/null +++ b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch @@ -0,0 +1,33 @@ +From 95ee154e3f3d324f5dcd47ed76f26194f727b5d3 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Wed, 6 Feb 2013 14:07:30 +0100 +Subject: [PATCH] Do not modify global Specification.dirs during installation. + +While gems are installed into --install-dir just fine even without +modifications of Specification.dirs, change in it makes inaccessible +gems already present on the system. +--- + lib/rubygems/dependency_installer.rb | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +diff --git a/lib/rubygems/dependency_installer.rb b/lib/rubygems/dependency_installer.rb +index ed90af0..8b6f93f 100644 +--- a/lib/rubygems/dependency_installer.rb ++++ b/lib/rubygems/dependency_installer.rb +@@ -58,12 +58,7 @@ class Gem::DependencyInstaller + + def initialize(options = {}) + if options[:install_dir] then +- @gem_home = options[:install_dir] +- +- # HACK shouldn't change the global settings +- Gem::Specification.dirs = @gem_home +- Gem.ensure_gem_subdirectories @gem_home +- options[:install_dir] = @gem_home # FIX: because we suck and reuse below ++ Gem.ensure_gem_subdirectories options[:install_dir] + end + + options = DEFAULT_OPTIONS.merge options +-- +1.8.1 + From 46a0c2b2c70d6127b13f22ff6bfa55cfcca2e964 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 7 Feb 2013 13:25:20 +0100 Subject: [PATCH 68/87] Rename the rubygems patch to follow rubygems version. --- ruby.spec | 2 +- ...y-extensions.patch => rubygems-2.0.0-binary-extensions.patch | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename rubygems-1.8.11-binary-extensions.patch => rubygems-2.0.0-binary-extensions.patch (100%) diff --git a/ruby.spec b/ruby.spec index ae3775a..1046fbe 100644 --- a/ruby.spec +++ b/ruby.spec @@ -104,7 +104,7 @@ Patch4: ruby-1.9.3-fix-s390x-build.patch Patch8: ruby-1.9.3-custom-rubygems-location.patch # Add support for installing binary extensions according to FHS. # https://github.com/rubygems/rubygems/issues/210 -Patch9: rubygems-1.8.11-binary-extensions.patch +Patch9: rubygems-2.0.0-binary-extensions.patch # Fixes issues mentioned in rhbz#789532, comment 8. # TODO: Should be probably upstreamed with #5281. Patch10: ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch diff --git a/rubygems-1.8.11-binary-extensions.patch b/rubygems-2.0.0-binary-extensions.patch similarity index 100% rename from rubygems-1.8.11-binary-extensions.patch rename to rubygems-2.0.0-binary-extensions.patch From d3938ffb0a8cf3e4917fd8a2ad8e491791ff23d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 7 Feb 2013 14:44:59 +0100 Subject: [PATCH 69/87] Add architecture dependency on ruby-libs to ruby-irb. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 1046fbe..2c17403 100644 --- a/ruby.spec +++ b/ruby.spec @@ -219,7 +219,7 @@ specified in standard Ruby syntax. Summary: The Interactive Ruby Version: %{irb_version} Group: Development/Libraries -Requires: %{name}-libs = %{ruby_version_patch_level} +Requires: %{name}-libs%{?_isa} = %{ruby_version_patch_level} Provides: irb = %{version}-%{release} Provides: ruby(irb) = %{version}-%{release} BuildArch: noarch From 9e99bbc4af7f8ac72ac9cbc8c38142a6875d11a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Sat, 9 Feb 2013 00:54:37 +0100 Subject: [PATCH 70/87] Upgrade to Ruby 2.0.0 (rc2). --- ...9.3-added-site-and-vendor-arch-flags.patch | 188 ------------------ ruby-1.9.3-always-use-i386.patch | 8 +- ruby-1.9.3-arch-specific-dir.patch | 133 ++----------- ruby-1.9.3-custom-rubygems-location.patch | 32 +-- ruby-1.9.3-disable-versioned-paths.patch | 149 -------------- ruby-1.9.3-fix-s390x-build.patch | 6 +- ...pc-variable-by-configuration-process.patch | 35 ---- ...ed-paths-when-empty-version-string-i.patch | 70 +++++++ ruby.spec | 32 +-- ...obal-Specification.dirs-during-insta.patch | 16 +- 10 files changed, 123 insertions(+), 546 deletions(-) delete mode 100644 ruby-1.9.3-added-site-and-vendor-arch-flags.patch delete mode 100644 ruby-1.9.3-disable-versioned-paths.patch delete mode 100644 ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch create mode 100644 ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch diff --git a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch b/ruby-1.9.3-added-site-and-vendor-arch-flags.patch deleted file mode 100644 index c3b007b..0000000 --- a/ruby-1.9.3-added-site-and-vendor-arch-flags.patch +++ /dev/null @@ -1,188 +0,0 @@ -From be687364922657501e861e9f53f8ec647a73fe00 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?V=C3=ADt=20Ondruch?= -Date: Mon, 5 Sep 2011 13:10:47 +0200 -Subject: [PATCH] Added configuration flags for site and vendor architecture - specific directories. - ---- - Makefile.in | 3 +++ - configure.in | 40 ++++++++++++++++++++++++++++++++++++++++ - tool/mkconfig.rb | 8 ++++++-- - version.c | 4 ++++ - 4 files changed, 53 insertions(+), 2 deletions(-) - -diff --git a/Makefile.in b/Makefile.in -index 690ff8e..8c7dd98 100644 ---- a/Makefile.in -+++ b/Makefile.in -@@ -41,6 +41,9 @@ arch = @arch@ - archdir = @archdir@ - sitearch = @sitearch@ - sitedir = @sitedir@ -+sitearchdir= @sitearchdir@ -+vendordir = @vendordir@ -+vendorarchdir = @vendorarchdir@ - ruby_version = @ruby_version@ - - TESTUI = console -diff --git a/configure.in b/configure.in -index 8e4aaec..c65e0c7 100644 ---- a/configure.in -+++ b/configure.in -@@ -3197,6 +3197,15 @@ until SITE_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITE_DIR}"; do - dir="${SITE_DIR}" - done - -+AC_ARG_WITH(sitearchdir, -+ AS_HELP_STRING([--with-sitearchdir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]]]), -+ [sitearchdir=$withval], -+ [sitearchdir='${rubylibprefix}/site_ruby/${arch}']) -+dir="${sitearchdir}" -+until SITEARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${SITEARCH_DIR}"; do -+ dir="${SITEARCH_DIR}" -+done -+ - AC_ARG_WITH(vendordir, - AS_HELP_STRING([--with-vendordir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]], "no" to disable vendor directory]), - [vendordir=$withval], -@@ -3206,19 +3215,32 @@ until VENDOR_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDOR_DIR}"; do - dir="${VENDOR_DIR}" - done - -+AC_ARG_WITH(vendorarchdir, -+ AS_HELP_STRING([--with-vendorarchdir=DIR], [vendor libraries in DIR [[RUBY_LIB_PREFIX/vendor_ruby]]]), -+ [vendorarchdir=$withval], -+ [vendorarchdir='${rubylibprefix}/vendor_ruby/${arch}']) -+dir="${vendorarchdir}" -+until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_DIR}"; do -+ dir="${VENDORARCH_DIR}" -+done -+ - if test "${LOAD_RELATIVE+set}"; then - AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) - RUBY_EXEC_PREFIX="" - RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_ARCH_LIB_PATH="`eval echo "$ARCH_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_SITE_LIB_PATH="`eval echo "$SITE_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" -+ RUBY_SITE_ARCHLIB_PATH="`eval echo "$SITEARCH_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_VENDOR_LIB_PATH="`eval echo "$VENDOR_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" -+ RUBY_VENDOR_ARCHLIB_PATH="`eval echo "$VENDORARCH_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - else - RUBY_EXEC_PREFIX="`eval echo \\"$exec_prefix/\\" | sed 's|^NONE/|'"$prefix"'/|;s|/$||'`" - RUBY_LIB_PREFIX="`eval echo \\"$RUBY_LIB_PREFIX\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_ARCH_LIB_PATH="`eval echo \\"$ARCH_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_SITE_LIB_PATH="`eval echo \\"$SITE_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" -+ RUBY_SITE_ARCHLIB_PATH="`eval echo \\"$SITEARCH_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_VENDOR_LIB_PATH="`eval echo \\"$VENDOR_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" -+ RUBY_VENDOR_ARCHLIB_PATH="`eval echo \\"$VENDORARCH_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - fi - - pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -@@ -3236,6 +3258,13 @@ AS_CASE(["$RUBY_SITE_LIB_PATH"], - [ - RUBY_SITE_LIB_PATH="\"${RUBY_SITE_LIB_PATH}\"" - ]) -+AS_CASE(["$RUBY_SITE_ARCHLIB_PATH"], -+ ["$RUBY_LIB_PREFIX/"*], [ -+ RUBY_SITE_ARCHLIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_ARCHLIB_PATH\" : \"$pat\"`"'"' -+ ], -+ [ -+ RUBY_SITE_ARCHLIB_PATH="\"${RUBY_SITE_ARCHLIB_PATH}\"" -+ ]) - AS_CASE(["$RUBY_VENDOR_LIB_PATH"], - ["$RUBY_LIB_PREFIX/"*], [ - RUBY_VENDOR_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_LIB_PATH\" : \"$pat\"`"'"' -@@ -3243,6 +3272,13 @@ AS_CASE(["$RUBY_VENDOR_LIB_PATH"], - [ - RUBY_VENDOR_LIB_PATH="\"${RUBY_VENDOR_LIB_PATH}\"" - ]) -+AS_CASE(["$RUBY_VENDOR_ARCHLIB_PATH"], -+ ["$RUBY_LIB_PREFIX/"*], [ -+ RUBY_VENDOR_ARCHLIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_VENDOR_ARCHLIB_PATH\" : \"$pat\"`"'"' -+ ], -+ [ -+ RUBY_VENDOR_ARCHLIB_PATH="\"${RUBY_VENDOR_ARCHLIB_PATH}\"" -+ ]) - pat=`echo "$RUBY_EXEC_PREFIX/" | tr -c '\012' .`'\(.*\)' - AS_CASE(["$RUBY_LIB_PREFIX"], - ["$RUBY_EXEC_PREFIX/"*], [ -@@ -3264,11 +3300,13 @@ if test "x$SITE_DIR" = xno; then - AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) - else - AC_DEFINE_UNQUOTED(RUBY_SITE_LIB, ${RUBY_SITE_LIB_PATH} !!) -+ AC_DEFINE_UNQUOTED(RUBY_SITE_ARCHLIB, ${RUBY_SITE_ARCHLIB_PATH} !!) - fi - if test "x$VENDOR_DIR" = xno; then - AC_DEFINE(NO_RUBY_VENDOR_LIB, [] !!) - else - AC_DEFINE_UNQUOTED(RUBY_VENDOR_LIB, ${RUBY_VENDOR_LIB_PATH} !!) -+ AC_DEFINE_UNQUOTED(RUBY_VENDOR_ARCHLIB, ${RUBY_VENDOR_ARCHLIB_PATH} !!) - fi - - AC_SUBST(arch)dnl -@@ -3276,7 +3314,9 @@ AC_SUBST(sitearch)dnl - AC_SUBST(ruby_version)dnl - AC_SUBST(archdir)dnl - AC_SUBST(sitedir)dnl -+AC_SUBST(sitearchdir)dnl - AC_SUBST(vendordir)dnl -+AC_SUBST(vendorarchdir)dnl - - configure_args=$ac_configure_args - AC_SUBST(configure_args)dnl -diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index 03c3332..79b8e44 100755 ---- a/tool/mkconfig.rb -+++ b/tool/mkconfig.rb -@@ -45,6 +45,8 @@ continued_name = nil - continued_line = nil - path_version = "/$(ruby_version)" - archdir_override = "$(vendorlibdir)/$(sitearch)" -+sitearchdir_override = "$(sitelibdir)/$(sitearch)" -+vendorarchdir_override = "$(vendorlibdir)/$(sitearch)" - File.foreach "config.status" do |line| - next if /^#/ =~ line - name = nil -@@ -81,6 +83,8 @@ File.foreach "config.status" do |line| - when /^RUBY_SO_NAME$/; next if $so_name - when /^arch$/; if val.empty? then val = arch else arch = val end - when /^archdir$/; archdir_override = val; next -+ when /^sitearchdir$/; sitearchdir_override = val; next -+ when /^vendorarchdir$/; vendorarchdir_override = val; next - when /^sitearch/; val = '$(arch)' if val.empty? - end - case val -@@ -217,11 +221,11 @@ print < Date: Mon, 19 Nov 2012 14:37:28 +0100 Subject: [PATCH] Always use i386. @@ -8,10 +8,10 @@ Subject: [PATCH] Always use i386. 1 file changed, 2 insertions(+) diff --git a/configure.in b/configure.in -index c65e0c7..748edc9 100644 +index 418b0cb..d26fe5b 100644 --- a/configure.in +++ b/configure.in -@@ -3321,6 +3321,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3320,6 +3320,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl @@ -21,5 +21,5 @@ index c65e0c7..748edc9 100644 arch="universal-${target_os}" AC_CACHE_CHECK(whether __ARCHITECTURE__ is available, rb_cv_architecture_available, -- -1.8.0 +1.8.1 diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 8bfce1f..5c24947 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -1,132 +1,27 @@ -From 50d6113cc3752d1810d58b78d9d009662e143041 Mon Sep 17 00:00:00 2001 +From 770799128d4cf0b2908f8cd15d935fc6cc24397a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= -Date: Thu, 8 Sep 2011 15:30:05 +0200 +Date: Fri, 8 Feb 2013 18:20:50 +0100 Subject: [PATCH] Add configuration arch specific dir flag. --- - Makefile.in | 1 + - configure.in | 20 ++++++++++++++++++++ - tool/mkconfig.rb | 4 +++- - version.c | 2 ++ - 4 files changed, 26 insertions(+), 1 deletion(-) + configure.in | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) -diff --git a/Makefile.in b/Makefile.in -index 78d7139..690ff8e 100644 ---- a/Makefile.in -+++ b/Makefile.in -@@ -38,6 +38,7 @@ libexecdir = @libexecdir@ - datarootdir = @datarootdir@ - datadir = @datadir@ - arch = @arch@ -+archdir = @archdir@ - sitearch = @sitearch@ - sitedir = @sitedir@ - ruby_version = @ruby_version@ diff --git a/configure.in b/configure.in -index db3641b..8e4aaec 100644 +index 7604bb8..418b0cb 100644 --- a/configure.in +++ b/configure.in -@@ -3179,6 +3179,15 @@ else - RUBY_LIB_VERSION="\"${ruby_version}\"" - fi +@@ -3186,6 +3191,10 @@ AC_ARG_WITH(rubylibprefix, + rubylibdir='${rubylibprefix}/${ruby_version}' + rubyarchdir=${multiarch+'${rubyarchprefix}/${ruby_version}'}${multiarch-'${rubylibdir}/${arch}'} +AC_ARG_WITH(archdir, -+ AS_HELP_STRING([--with-archdir=DIR], [architecture specific ruby libraries [[LIBDIR/RUBY_BASE_NAME/ARCH]]]), -+ [archdir=$withval], -+ [archdir='${rubylibprefix}/${arch}']) -+dir="${archdir}" -+until ARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${ARCH_DIR}"; do -+ dir="${ARCH_DIR}" -+done ++ AS_HELP_STRING([--with-archdir=DIR], [architecture specific ruby libraries [[LIBDIR/RUBY_BASE_NAME/ARCH]]]), ++ [rubyarchdir=$withval]) + - AC_ARG_WITH(sitedir, - AS_HELP_STRING([--with-sitedir=DIR], [site libraries in DIR [[RUBY_LIB_PREFIX/site_ruby]], "no" to disable site directory]), - [sitedir=$withval], -@@ -3201,16 +3210,25 @@ if test "${LOAD_RELATIVE+set}"; then - AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) - RUBY_EXEC_PREFIX="" - RUBY_LIB_PREFIX="`eval echo "$RUBY_LIB_PREFIX" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" -+ RUBY_ARCH_LIB_PATH="`eval echo "$ARCH_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_SITE_LIB_PATH="`eval echo "$SITE_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - RUBY_VENDOR_LIB_PATH="`eval echo "$VENDOR_DIR" | sed 's|^NONE/|/|;s|^'"$prefix"'/|/|'`" - else - RUBY_EXEC_PREFIX="`eval echo \\"$exec_prefix/\\" | sed 's|^NONE/|'"$prefix"'/|;s|/$||'`" - RUBY_LIB_PREFIX="`eval echo \\"$RUBY_LIB_PREFIX\\" | sed 's|^NONE/|'"$prefix"'/|'`" -+ RUBY_ARCH_LIB_PATH="`eval echo \\"$ARCH_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_SITE_LIB_PATH="`eval echo \\"$SITE_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - RUBY_VENDOR_LIB_PATH="`eval echo \\"$VENDOR_DIR\\" | sed 's|^NONE/|'"$prefix"'/|'`" - fi - - pat=`echo "$RUBY_LIB_PREFIX/" | tr -c '\012' .`'\(.*\)' -+AS_CASE(["$RUBY_ARCH_LIB_PATH"], -+ ["$RUBY_LIB_PREFIX/"*], [ -+ RUBY_ARCH_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_ARCH_LIB_PATH\" : \"$pat\"`"'"' -+ ], -+ [ -+ RUBY_ARCH_LIB_PATH="\"${RUBY_ARCH_LIB_PATH}\"" -+ ]) - AS_CASE(["$RUBY_SITE_LIB_PATH"], - ["$RUBY_LIB_PREFIX/"*], [ - RUBY_SITE_LIB_PATH='RUBY_LIB_PREFIX"/'"`expr \"$RUBY_SITE_LIB_PATH\" : \"$pat\"`"'"' -@@ -3241,6 +3259,7 @@ else - fi - AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, "${RUBY_EXEC_PREFIX}") - AC_DEFINE_UNQUOTED(RUBY_LIB_PREFIX, ${RUBY_LIB_PREFIX} !!) -+AC_DEFINE_UNQUOTED(RUBY_ARCHLIB, ${RUBY_ARCH_LIB_PATH} !!) - if test "x$SITE_DIR" = xno; then - AC_DEFINE(NO_RUBY_SITE_LIB, [] !!) - else -@@ -3255,6 +3274,7 @@ fi - AC_SUBST(arch)dnl - AC_SUBST(sitearch)dnl - AC_SUBST(ruby_version)dnl -+AC_SUBST(archdir)dnl - AC_SUBST(sitedir)dnl - AC_SUBST(vendordir)dnl - -diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index d9e26c1..03c3332 100755 ---- a/tool/mkconfig.rb -+++ b/tool/mkconfig.rb -@@ -44,6 +44,7 @@ vars = {} - continued_name = nil - continued_line = nil - path_version = "/$(ruby_version)" -+archdir_override = "$(vendorlibdir)/$(sitearch)" - File.foreach "config.status" do |line| - next if /^#/ =~ line - name = nil -@@ -79,6 +80,7 @@ File.foreach "config.status" do |line| - when /^RUBY_INSTALL_NAME$/; next if $install_name - when /^RUBY_SO_NAME$/; next if $so_name - when /^arch$/; if val.empty? then val = arch else arch = val end -+ when /^archdir$/; archdir_override = val; next - when /^sitearch/; val = '$(arch)' if val.empty? - end - case val -@@ -211,7 +213,7 @@ print(*v_fast) - print(*v_others) - print < -Date: Thu, 25 Aug 2011 14:33:51 +0200 -Subject: [PATCH] Allow to disable versioned paths. - ---- - configure.in | 11 +++++++++++ - lib/rdoc/ri/paths.rb | 4 ++-- - tool/mkconfig.rb | 9 ++++++--- - tool/rbinstall.rb | 2 +- - version.c | 10 ++++++++++ - 5 files changed, 30 insertions(+), 6 deletions(-) - -diff --git a/configure.in b/configure.in -index f2d22ef..db3641b 100644 ---- a/configure.in -+++ b/configure.in -@@ -3346,6 +3346,17 @@ else - fi - AC_SUBST(USE_RUBYGEMS) - -+AC_ARG_ENABLE(versioned-paths, -+ AS_HELP_STRING([--disable-versioned-paths], [disable paths with version number]), -+ [enable_versioned_paths="$enableval"], [enable_versioned_paths=yes]) -+if test x"$enable_versioned_paths" = xno; then -+ AC_DEFINE(DISABLE_VERSIONED_PATHS, 1) -+ USE_VERSIONED_PATHS=NO -+else -+ USE_VERSIONED_PATHS=YES -+fi -+AC_SUBST(USE_VERSIONED_PATHS) -+ - arch_hdrdir="${EXTOUT}/include/${arch}/ruby" - AS_MKDIR_P("${arch_hdrdir}") - config_h="${arch_hdrdir}/config.h" -diff --git a/lib/rdoc/ri/paths.rb b/lib/rdoc/ri/paths.rb -index a3c65bf..a4e8559 100644 ---- a/lib/rdoc/ri/paths.rb -+++ b/lib/rdoc/ri/paths.rb -@@ -12,9 +12,9 @@ module RDoc::RI::Paths - version = RbConfig::CONFIG['ruby_version'] - - BASE = if RbConfig::CONFIG.key? 'ridir' then -- File.join RbConfig::CONFIG['ridir'], version -+ File.join [RbConfig::CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact - else -- File.join RbConfig::CONFIG['datadir'], 'ri', version -+ File.join [RbConfig::CONFIG['datadir'], 'ri', RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact - end - - homedir = begin -diff --git a/tool/mkconfig.rb b/tool/mkconfig.rb -index f9d97d3..d9e26c1 100755 ---- a/tool/mkconfig.rb -+++ b/tool/mkconfig.rb -@@ -43,6 +43,7 @@ v_runtime = {} - vars = {} - continued_name = nil - continued_line = nil -+path_version = "/$(ruby_version)" - File.foreach "config.status" do |line| - next if /^#/ =~ line - name = nil -@@ -142,6 +143,8 @@ File.foreach "config.status" do |line| - case name - when "ruby_version" - version = val[/\A"(.*)"\z/, 1] -+ when /^USE_VERSIONED_PATHS$/ -+ path_version = nil if /NO/ =~ val - end - end - # break if /^CEOF/ -@@ -207,15 +210,15 @@ end - print(*v_fast) - print(*v_others) - print < $data_mode) - end -diff --git a/version.c b/version.c -index 26e275a..05e5069 100644 ---- a/version.c -+++ b/version.c -@@ -39,9 +39,15 @@ - #define RUBY_VENDOR_LIB RUBY_LIB_PREFIX"/vendor_ruby" - #endif - -+#ifdef DISABLE_VERSIONED_PATHS -+#define RUBY_LIB RUBY_LIB_PREFIX -+#define RUBY_SITE_LIB2 RUBY_SITE_LIB -+#define RUBY_VENDOR_LIB2 RUBY_VENDOR_LIB -+#else - #define RUBY_LIB RUBY_LIB_PREFIX "/"RUBY_LIB_VERSION - #define RUBY_SITE_LIB2 RUBY_SITE_LIB "/"RUBY_LIB_VERSION - #define RUBY_VENDOR_LIB2 RUBY_VENDOR_LIB "/"RUBY_LIB_VERSION -+#endif - #define RUBY_ARCHLIB RUBY_LIB "/"RUBY_ARCH - #define RUBY_SITE_ARCHLIB RUBY_SITE_LIB2 "/"RUBY_SITEARCH - #define RUBY_VENDOR_ARCHLIB RUBY_VENDOR_LIB2 "/"RUBY_SITEARCH -@@ -76,8 +82,10 @@ const char ruby_initial_load_paths[] = - RUBY_SITE_THIN_ARCHLIB "\0" - #endif - RUBY_SITE_ARCHLIB "\0" -+#ifndef DISABLE_VERSIONED_PATHS - RUBY_SITE_LIB "\0" - #endif -+#endif - - #ifndef NO_RUBY_VENDOR_LIB - RUBY_VENDOR_LIB2 "\0" -@@ -85,8 +93,10 @@ const char ruby_initial_load_paths[] = - RUBY_VENDOR_THIN_ARCHLIB "\0" - #endif - RUBY_VENDOR_ARCHLIB "\0" -+#ifndef DISABLE_VERSIONED_PATHS - RUBY_VENDOR_LIB "\0" - #endif -+#endif - - RUBY_LIB "\0" - #ifdef RUBY_THIN_ARCHLIB --- -1.8.0 - diff --git a/ruby-1.9.3-fix-s390x-build.patch b/ruby-1.9.3-fix-s390x-build.patch index 5f91aae..3e7056f 100644 --- a/ruby-1.9.3-fix-s390x-build.patch +++ b/ruby-1.9.3-fix-s390x-build.patch @@ -1,4 +1,4 @@ -From d710179fcc088a201339a28fa6a5779da8e6ab62 Mon Sep 17 00:00:00 2001 +From d006c4d04aecbe80469a26a6114b776e9de4e3c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 19 Nov 2012 14:39:19 +0100 Subject: [PATCH] Fix s390x build. @@ -8,7 +8,7 @@ Subject: [PATCH] Fix s390x build. 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/tk/extconf.rb b/ext/tk/extconf.rb -index 72dd6cf..5c6081e 100644 +index 8f3bff8..69e90a1 100644 --- a/ext/tk/extconf.rb +++ b/ext/tk/extconf.rb @@ -114,7 +114,7 @@ def is_macosx? @@ -21,5 +21,5 @@ index 72dd6cf..5c6081e 100644 def check_tcltk_version(version) -- -1.8.0 +1.8.1 diff --git a/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch b/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch deleted file mode 100644 index 20dd78d..0000000 --- a/ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch +++ /dev/null @@ -1,35 +0,0 @@ -From bf4959bc763167b2245a5f4c699fcb72afead5a5 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?V=C3=ADt=20Ondruch?= -Date: Fri, 18 Jan 2013 15:51:49 +0100 -Subject: [PATCH] Expand ruby.pc variable by configuration process. - ---- - template/ruby.pc.in | 12 ++++++------ - 1 file changed, 6 insertions(+), 6 deletions(-) - -diff --git a/template/ruby.pc.in b/template/ruby.pc.in -index 2d6716c..25e42f3 100644 ---- a/template/ruby.pc.in -+++ b/template/ruby.pc.in -@@ -25,12 +25,12 @@ LIBS=@LIBS@ - DLDFLAGS=@DLDFLAGS@ - ruby=${bindir}/${RUBY_INSTALL_NAME}@EXEEXT@ - rubylibprefix=@rubylibprefix@ --rubylibdir=${rubylibprefix}/${ruby_version} --vendordir=${rubylibprefix}/vendor_ruby --sitedir=${rubylibprefix}/site_ruby --rubyarchdir=${rubylibdir}/${arch} --vendorarchdir=${vendordir}/${sitearch} --sitearchdir=${sitedir}/${sitearch} -+rubylibdir=@rubylibprefix@ -+vendordir=@vendordir@ -+sitedir=@sitedir@ -+rubyarchdir=@archdir@ -+vendorarchdir=@vendorarchdir@ -+sitearchdir=@sitearchdir@ - rubyhdrdir=@rubyhdrdir@ - vendorhdrdir=@vendorhdrdir@ - sitehdrdir=@sitehdrdir@ --- -1.8.0.2 - diff --git a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch new file mode 100644 index 0000000..1e31179 --- /dev/null +++ b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -0,0 +1,70 @@ +From 5afb0d89ab0e6297b333f45b4bd30a20024e80c7 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Fri, 8 Feb 2013 22:48:41 +0100 +Subject: [PATCH] Prevent duplicated paths when empty version string is + configured. + +--- + configure.in | 3 +++ + version.c | 10 ++++++++++ + 2 files changed, 13 insertions(+) + +diff --git a/configure.in b/configure.in +index 5850bbf..7604bb8 100644 +--- a/configure.in ++++ b/configure.in +@@ -3265,6 +3265,9 @@ shvar_to_cpp RIDIR "${ridir}" + if test ${RUBY_LIB_VERSION_STYLE+set}; then + AC_DEFINE_UNQUOTED(RUBY_LIB_VERSION_STYLE, $RUBY_LIB_VERSION_STYLE !!) + else ++ if test "x${ruby_version}" = 'x'; then ++ AC_DEFINE(RUBY_LIB_VERSION_BLANK, 1) ++ fi + AC_DEFINE_UNQUOTED(RUBY_LIB_VERSION, [$RUBY_LIB_VERSION] !!) + fi + AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, ${RUBY_EXEC_PREFIX}) +diff --git a/version.c b/version.c +index 282960d..54c4513 100644 +--- a/version.c ++++ b/version.c +@@ -39,9 +39,15 @@ + #define RUBY_VENDOR_LIB RUBY_LIB_PREFIX"/vendor_ruby" + #endif + ++#ifdef RUBY_LIB_VERSION_BLANK ++#define RUBY_LIB RUBY_LIB_PREFIX ++#define RUBY_SITE_LIB2 RUBY_SITE_LIB ++#define RUBY_VENDOR_LIB2 RUBY_VENDOR_LIB ++#else + #define RUBY_LIB RUBY_LIB_PREFIX "/"RUBY_LIB_VERSION + #define RUBY_SITE_LIB2 RUBY_SITE_LIB "/"RUBY_LIB_VERSION + #define RUBY_VENDOR_LIB2 RUBY_VENDOR_LIB "/"RUBY_LIB_VERSION ++#endif + #ifndef RUBY_ARCH_LIB_FOR + #define RUBY_ARCH_LIB_FOR(arch) RUBY_LIB "/"arch + #endif +@@ -77,8 +83,10 @@ const char ruby_initial_load_paths[] = + RUBY_SITE_ARCH_LIB_FOR(RUBY_THINARCH) "\0" + #endif + RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" ++#ifndef RUBY_LIB_VERSION_BLANK + RUBY_SITE_LIB "\0" + #endif ++#endif + + #ifndef NO_RUBY_VENDOR_LIB + RUBY_VENDOR_LIB2 "\0" +@@ -86,8 +94,10 @@ const char ruby_initial_load_paths[] = + RUBY_VENDOR_ARCH_LIB_FOR(RUBY_THINARCH) "\0" + #endif + RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" ++#ifndef RUBY_LIB_VERSION_BLANK + RUBY_VENDOR_LIB "\0" + #endif ++#endif + + RUBY_LIB "\0" + #ifdef RUBY_THINARCH +-- +1.8.1 + diff --git a/ruby.spec b/ruby.spec index 2c17403..6c682a8 100644 --- a/ruby.spec +++ b/ruby.spec @@ -11,6 +11,7 @@ # Specify the named version. It has precedense to revision. #%%global milestone preview2 +%global milestone rc2 # Keep the revision enabled for pre-releases from SVN. %global revision 39070 @@ -59,7 +60,7 @@ # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} -%global rdoc_version 4.0.0.preview3.1 +%global rdoc_version 4.0.0.rc.2.1 %global bigdecimal_version 1.1.0 %global io_console_version 0.4.1 %global json_version 1.7.5 @@ -88,12 +89,10 @@ Source1: operating_system.rb Source2: libruby.stp Source3: ruby-exercise.stp -# http://redmine.ruby-lang.org/issues/5231 -Patch0: ruby-1.9.3-disable-versioned-paths.patch -# TODO: Should be submitted upstream? +# http://bugs.ruby-lang.org/issues/7807 +Patch0: ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +# http://bugs.ruby-lang.org/issues/7808 Patch1: ruby-1.9.3-arch-specific-dir.patch -# http://redmine.ruby-lang.org/issues/5281 -Patch2: ruby-1.9.3-added-site-and-vendor-arch-flags.patch # Force multiarch directories for i.86 to be always named i386. This solves # some differencies in build between Fedora and RHEL. Patch3: ruby-1.9.3-always-use-i386.patch @@ -105,9 +104,6 @@ Patch8: ruby-1.9.3-custom-rubygems-location.patch # Add support for installing binary extensions according to FHS. # https://github.com/rubygems/rubygems/issues/210 Patch9: rubygems-2.0.0-binary-extensions.patch -# Fixes issues mentioned in rhbz#789532, comment 8. -# TODO: Should be probably upstreamed with #5281. -Patch10: ruby-2.0.0-Expand-ruby.pc-variable-by-configuration-process.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch # This slightly changes behavior of "gem install --install-dir" behavior. @@ -370,12 +366,10 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch0 -p1 %patch1 -p1 -%patch2 -p1 %patch3 -p1 %patch4 -p1 %patch8 -p1 %patch9 -p1 -%patch10 -p1 %patch12 -p1 %patch13 -p1 @@ -397,7 +391,9 @@ autoconf --with-ruby-pc='%{name}.pc' \ --disable-rpath \ --enable-shared \ - --disable-versioned-paths + --with-ruby-version='' \ + + # Q= makes the build output more verbose and allows to check Fedora # compiler options. @@ -411,6 +407,10 @@ make install DESTDIR=%{buildroot} # Rename the ruby executable. It is replaced by RubyPick. mv %{buildroot}%{_bindir}/%{name}{,-mri} +# Version is empty if --with-ruby-version is specified. +# http://bugs.ruby-lang.org/issues/7807 +sed -i 's/Version: \${ruby_version}/Version: %{ruby_version}/' %{buildroot}%{_libdir}/pkgconfig/%{name}.pc + # Dump the macros into macro.ruby to use them to build other Ruby libraries. mkdir -p %{buildroot}%{_sysconfdir}/rpm cat >> %{buildroot}%{_sysconfdir}/rpm/macros.ruby << \EOF @@ -447,7 +447,7 @@ mkdir -p %{buildroot}%{rubygems_dir}/rubygems/defaults cp %{SOURCE1} %{buildroot}%{rubygems_dir}/rubygems/defaults # Move gems root into common direcotry, out of Ruby directory structure. -mv %{buildroot}%{ruby_libdir}/gems/2.0.0 %{buildroot}%{gem_dir} +mv %{buildroot}%{ruby_libdir}/gems %{buildroot}%{gem_dir} # Create folders for gem binary extensions. mkdir -p %{buildroot}%{gem_extdir}/%{name} @@ -538,7 +538,7 @@ DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" %endif -make check TESTS="-v $DISABLE_TESTS" +#make check TESTS="-v $DISABLE_TESTS" %post libs -p /sbin/ldconfig @@ -820,8 +820,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.2.r39070 -- Upgrade to Ruby 2.0.0 (r39070). +* Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 +- Upgrade to Ruby 2.0.0 (rc2). - Build against libdb instead of libdb4 (rhbz#894022). - Provide nonversioned packageconfig (rhbz#789532) and fix provided variables. - Move native extensions from exts to ruby directory. diff --git a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch index 8747b88..f0585c4 100644 --- a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch +++ b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch @@ -14,20 +14,16 @@ diff --git a/lib/rubygems/dependency_installer.rb b/lib/rubygems/dependency_inst index ed90af0..8b6f93f 100644 --- a/lib/rubygems/dependency_installer.rb +++ b/lib/rubygems/dependency_installer.rb -@@ -58,12 +58,7 @@ class Gem::DependencyInstaller +@@ -60,9 +60,6 @@ class Gem::DependencyInstaller + @install_dir = options[:install_dir] || Gem.dir - def initialize(options = {}) if options[:install_dir] then -- @gem_home = options[:install_dir] -- -- # HACK shouldn't change the global settings -- Gem::Specification.dirs = @gem_home -- Gem.ensure_gem_subdirectories @gem_home -- options[:install_dir] = @gem_home # FIX: because we suck and reuse below -+ Gem.ensure_gem_subdirectories options[:install_dir] +- # HACK shouldn't change the global settings, needed for -i behavior +- # maybe move to the install command? See also github #442 +- Gem::Specification.dirs = @install_dir + Gem.ensure_gem_subdirectories @install_dir end - options = DEFAULT_OPTIONS.merge options -- 1.8.1 From fc22a3a50fec94c8c8a2cbeff5dc29be31bd5e35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 13 Feb 2013 16:33:54 +0100 Subject: [PATCH 71/87] Update rubygems --install-dir patch. --- ruby.spec | 2 +- ...obal-Specification.dirs-during-insta.patch | 96 +++++++++++++++++-- 2 files changed, 87 insertions(+), 11 deletions(-) diff --git a/ruby.spec b/ruby.spec index 6c682a8..8cf79b0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -110,7 +110,7 @@ Patch12: ruby-1.9.3-mkmf-verbose.patch # Without this patch, Specifications.dirs is modified and gems installed on # the system cannot be required anymore. This causes later issues when RDoc # documentation should be generated, since json gem is sudenly not accessible. -# https://github.com/rubygems/rubygems/pull/442 +# https://github.com/rubygems/rubygems/pull/452 Patch13: rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} diff --git a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch index f0585c4..b082597 100644 --- a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch +++ b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch @@ -1,29 +1,105 @@ -From 95ee154e3f3d324f5dcd47ed76f26194f727b5d3 Mon Sep 17 00:00:00 2001 +From b95b9942361104dc5b7fd08eb4970f893d8c1a54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= -Date: Wed, 6 Feb 2013 14:07:30 +0100 -Subject: [PATCH] Do not modify global Specification.dirs during installation. +Date: Wed, 13 Feb 2013 13:12:30 +0100 +Subject: [PATCH 1/2] Remove duplicated check. + +The loaded specifications are rejected already in #gather_dependencies, +so this condition cannot trigger. +--- + lib/rubygems/dependency_installer.rb | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/lib/rubygems/dependency_installer.rb b/lib/rubygems/dependency_installer.rb +index d811f62..dffa8df 100644 +--- a/lib/rubygems/dependency_installer.rb ++++ b/lib/rubygems/dependency_installer.rb +@@ -319,9 +319,6 @@ class Gem::DependencyInstaller + + last = @gems_to_install.size - 1 + @gems_to_install.each_with_index do |spec, index| +- # REFACTOR more current spec set hardcoding, should be abstracted? +- next if Gem::Specification.include?(spec) and index != last +- + # TODO: make this sorta_verbose so other users can benefit from it + say "Installing gem #{spec.full_name}" if Gem.configuration.really_verbose + +-- +1.8.1.2 + + +From 2fa9087b1986db6c7945c0f997fed2bfff5ce06a Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Wed, 13 Feb 2013 15:47:47 +0100 +Subject: [PATCH 2/2] Do not modify global Specification.dirs during + installation. While gems are installed into --install-dir just fine even without modifications of Specification.dirs, change in it makes inaccessible gems already present on the system. --- - lib/rubygems/dependency_installer.rb | 7 +------ - 1 file changed, 1 insertion(+), 6 deletions(-) + lib/rubygems/dependency_installer.rb | 15 ++++++--------- + 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/lib/rubygems/dependency_installer.rb b/lib/rubygems/dependency_installer.rb -index ed90af0..8b6f93f 100644 +index dffa8df..841f26a 100644 --- a/lib/rubygems/dependency_installer.rb +++ b/lib/rubygems/dependency_installer.rb -@@ -60,9 +60,6 @@ class Gem::DependencyInstaller - @install_dir = options[:install_dir] || Gem.dir +@@ -57,17 +57,14 @@ class Gem::DependencyInstaller + # :build_args:: See Gem::Installer::new + + def initialize(options = {}) +- @install_dir = options[:install_dir] || Gem.dir if options[:install_dir] then - # HACK shouldn't change the global settings, needed for -i behavior - # maybe move to the install command? See also github #442 - Gem::Specification.dirs = @install_dir - Gem.ensure_gem_subdirectories @install_dir +- Gem.ensure_gem_subdirectories @install_dir ++ Gem.ensure_gem_subdirectories options[:install_dir] end + options = DEFAULT_OPTIONS.merge options + ++ @install_dir = options[:install_dir] + @bin_dir = options[:bin_dir] + @dev_shallow = options[:dev_shallow] + @development = options[:development] +@@ -91,7 +88,7 @@ class Gem::DependencyInstaller + @installed_gems = [] + @toplevel_specs = nil + +- @cache_dir = options[:cache_dir] || @install_dir ++ @cache_dir = options[:cache_dir] || @install_dir || Gem.dir + + # Set with any errors that SpecFetcher finds while search through + # gemspecs for a dep +@@ -185,7 +182,7 @@ class Gem::DependencyInstaller + # that this isn't dependent only on the currently installed gems + dependency_list.specs.reject! { |spec| + not keep_names.include?(spec.full_name) and +- Gem::Specification.include?(spec) ++ (!@install_dir && Gem::Specification.include?(spec)) + } + + unless dependency_list.ok? or @ignore_dependencies or @force then +@@ -237,7 +234,7 @@ class Gem::DependencyInstaller + to_do.push t.spec + end + +- results.remove_installed! dep ++ results.remove_installed! dep unless @install_dir + + @available << results + results.inject_into_list dependency_list +@@ -349,7 +346,7 @@ class Gem::DependencyInstaller + :force => @force, + :format_executable => @format_executable, + :ignore_dependencies => @ignore_dependencies, +- :install_dir => @install_dir, ++ :install_dir => (@install_dir || Gem.dir), + :security_policy => @security_policy, + :user_install => @user_install, + :wrappers => @wrappers, -- -1.8.1 +1.8.1.2 From 41d5ec4d1ba80b85dfba214f59c439c4a3505a5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 14 Feb 2013 15:26:28 +0100 Subject: [PATCH 72/87] Upgrade to Ruby 2.0.0 (r39217). --- ruby-1.9.3-arch-specific-dir.patch | 12 +-- ...ed-paths-when-empty-version-string-i.patch | 14 ++-- ruby.spec | 14 +++- ...s-2.0.0-Fixes-for-empty-ruby-version.patch | 81 +++++++++++++++++++ 4 files changed, 104 insertions(+), 17 deletions(-) create mode 100644 rubygems-2.0.0-Fixes-for-empty-ruby-version.patch diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 5c24947..2546128 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -1,17 +1,17 @@ -From 770799128d4cf0b2908f8cd15d935fc6cc24397a Mon Sep 17 00:00:00 2001 +From 2e15c6bdac1c145cce0c21677477ced8df26718b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 8 Feb 2013 18:20:50 +0100 Subject: [PATCH] Add configuration arch specific dir flag. --- - configure.in | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) + configure.in | 4 ++++ + 1 file changed, 4 insertions(+) diff --git a/configure.in b/configure.in -index 7604bb8..418b0cb 100644 +index d6af000..1c094a3 100644 --- a/configure.in +++ b/configure.in -@@ -3186,6 +3191,10 @@ AC_ARG_WITH(rubylibprefix, +@@ -3221,6 +3221,10 @@ AC_SUBST(rubylibprefix) rubylibdir='${rubylibprefix}/${ruby_version}' rubyarchdir=${multiarch+'${rubyarchprefix}/${ruby_version}'}${multiarch-'${rubylibdir}/${arch}'} @@ -23,5 +23,5 @@ index 7604bb8..418b0cb 100644 AC_ARG_WITH(rubyarchprefix, AS_HELP_STRING([--with-rubyarchprefix=DIR], -- -1.8.1 +1.8.1.2 diff --git a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index 1e31179..5a6c79a 100644 --- a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -1,4 +1,4 @@ -From 5afb0d89ab0e6297b333f45b4bd30a20024e80c7 Mon Sep 17 00:00:00 2001 +From 1e109d1a0265dfdde2324a6a97e4225eb4343efc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 8 Feb 2013 22:48:41 +0100 Subject: [PATCH] Prevent duplicated paths when empty version string is @@ -10,10 +10,10 @@ Subject: [PATCH] Prevent duplicated paths when empty version string is 2 files changed, 13 insertions(+) diff --git a/configure.in b/configure.in -index 5850bbf..7604bb8 100644 +index e83cfb4..d6af000 100644 --- a/configure.in +++ b/configure.in -@@ -3265,6 +3265,9 @@ shvar_to_cpp RIDIR "${ridir}" +@@ -3308,6 +3308,9 @@ shvar_to_cpp RIDIR "${ridir}" if test ${RUBY_LIB_VERSION_STYLE+set}; then AC_DEFINE_UNQUOTED(RUBY_LIB_VERSION_STYLE, $RUBY_LIB_VERSION_STYLE !!) else @@ -24,7 +24,7 @@ index 5850bbf..7604bb8 100644 fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, ${RUBY_EXEC_PREFIX}) diff --git a/version.c b/version.c -index 282960d..54c4513 100644 +index 6ba6453..c78f609 100644 --- a/version.c +++ b/version.c @@ -39,9 +39,15 @@ @@ -43,7 +43,7 @@ index 282960d..54c4513 100644 #ifndef RUBY_ARCH_LIB_FOR #define RUBY_ARCH_LIB_FOR(arch) RUBY_LIB "/"arch #endif -@@ -77,8 +83,10 @@ const char ruby_initial_load_paths[] = +@@ -79,8 +85,10 @@ const char ruby_initial_load_paths[] = RUBY_SITE_ARCH_LIB_FOR(RUBY_THINARCH) "\0" #endif RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" @@ -54,7 +54,7 @@ index 282960d..54c4513 100644 #ifndef NO_RUBY_VENDOR_LIB RUBY_VENDOR_LIB2 "\0" -@@ -86,8 +94,10 @@ const char ruby_initial_load_paths[] = +@@ -88,8 +96,10 @@ const char ruby_initial_load_paths[] = RUBY_VENDOR_ARCH_LIB_FOR(RUBY_THINARCH) "\0" #endif RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" @@ -66,5 +66,5 @@ index 282960d..54c4513 100644 RUBY_LIB "\0" #ifdef RUBY_THINARCH -- -1.8.1 +1.8.1.2 diff --git a/ruby.spec b/ruby.spec index 8cf79b0..f8103de 100644 --- a/ruby.spec +++ b/ruby.spec @@ -11,10 +11,9 @@ # Specify the named version. It has precedense to revision. #%%global milestone preview2 -%global milestone rc2 # Keep the revision enabled for pre-releases from SVN. -%global revision 39070 +%global revision 39217 %global ruby_archive %{name}-%{ruby_version} @@ -63,7 +62,7 @@ %global rdoc_version 4.0.0.rc.2.1 %global bigdecimal_version 1.1.0 %global io_console_version 0.4.1 -%global json_version 1.7.5 +%global json_version 1.7.7 %global minitest_version 4.3.2 %global psych_version 2.0.0 @@ -112,6 +111,9 @@ Patch12: ruby-1.9.3-mkmf-verbose.patch # documentation should be generated, since json gem is sudenly not accessible. # https://github.com/rubygems/rubygems/pull/452 Patch13: rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch +# This prevents issues, when ruby configuration specifies --with-ruby-version=''. +# https://github.com/rubygems/rubygems/pull/455 +Patch14: rubygems-2.0.0-Fixes-for-empty-ruby-version.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} @@ -372,6 +374,7 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch9 -p1 %patch12 -p1 %patch13 -p1 +%patch14 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -538,7 +541,7 @@ DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" %endif -#make check TESTS="-v $DISABLE_TESTS" +make check TESTS="-v $DISABLE_TESTS" %post libs -p /sbin/ldconfig @@ -820,6 +823,9 @@ DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog +* Wed Feb 13 2013 Vít Ondruch - 2.0.0.0-0.2.r39217 +- Upgrade to Ruby 2.0.0 (r39217). + * Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 - Upgrade to Ruby 2.0.0 (rc2). - Build against libdb instead of libdb4 (rhbz#894022). diff --git a/rubygems-2.0.0-Fixes-for-empty-ruby-version.patch b/rubygems-2.0.0-Fixes-for-empty-ruby-version.patch new file mode 100644 index 0000000..9b275a9 --- /dev/null +++ b/rubygems-2.0.0-Fixes-for-empty-ruby-version.patch @@ -0,0 +1,81 @@ +From c9b2eff36728266052ccfff54d3ac0a0624fd0f1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Thu, 14 Feb 2013 11:50:41 +0100 +Subject: [PATCH 1/2] Use File.join insteado of manual path creation. + +This prevents issues, when File.join in #new_default_spec removes +superfluous slashes while they are kept in expected paths. E.g. the test +would fail if ruby configuration specifies --with-ruby-version=''. +--- + test/rubygems/test_gem_commands_contents_command.rb | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/test/rubygems/test_gem_commands_contents_command.rb b/test/rubygems/test_gem_commands_contents_command.rb +index 60df53f..35c9631 100644 +--- a/test/rubygems/test_gem_commands_contents_command.rb ++++ b/test/rubygems/test_gem_commands_contents_command.rb +@@ -140,10 +140,10 @@ lib/foo.rb + @cmd.execute + end + +- expected = %W[ +- #{Gem::ConfigMap[:bindir]}/default_command +- #{Gem::ConfigMap[:rubylibdir]}/default/gem.rb +- #{Gem::ConfigMap[:archdir]}/default_gem.so ++ expected = [ ++ File.join(Gem::ConfigMap[:bindir], 'default_command'), ++ File.join(Gem::ConfigMap[:rubylibdir], 'default/gem.rb'), ++ File.join(Gem::ConfigMap[:archdir], 'default_gem.so') + ].sort.join "\n" + + assert_equal expected, @ui.output.chomp +-- +1.8.1.2 + + +From b022cef7b2e6c2d138388a6c2db02cca8c408cc6 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Thu, 14 Feb 2013 13:35:20 +0100 +Subject: [PATCH 2/2] Do not add last slash to Gem.user_dir if ruby_version + string is empty. + +--- + lib/rubygems/defaults.rb | 4 +++- + test/rubygems/test_gem.rb | 6 ++++-- + 2 files changed, 7 insertions(+), 3 deletions(-) + +diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb +index ea84e5c..05c35bb 100644 +--- a/lib/rubygems/defaults.rb ++++ b/lib/rubygems/defaults.rb +@@ -54,7 +54,9 @@ module Gem + # Path for gems in the user's home directory + + def self.user_dir +- File.join Gem.user_home, '.gem', ruby_engine, ConfigMap[:ruby_version] ++ parts = [Gem.user_home, '.gem', ruby_engine] ++ parts << ConfigMap[:ruby_version] unless ConfigMap[:ruby_version].empty? ++ File.join parts + end + + ## +diff --git a/test/rubygems/test_gem.rb b/test/rubygems/test_gem.rb +index bf77009..9ee78f7 100644 +--- a/test/rubygems/test_gem.rb ++++ b/test/rubygems/test_gem.rb +@@ -1186,8 +1186,10 @@ class TestGem < Gem::TestCase + end + + def test_self_user_dir +- assert_equal File.join(@userhome, '.gem', Gem.ruby_engine, +- Gem::ConfigMap[:ruby_version]), Gem.user_dir ++ parts = [@userhome, '.gem', Gem.ruby_engine] ++ parts << Gem::ConfigMap[:ruby_version] unless Gem::ConfigMap[:ruby_version].empty? ++ ++ assert_equal File.join(parts), Gem.user_dir + end + + def test_self_user_home +-- +1.8.1.2 + From 2ec849748a0c3684e8249d97a700faf376ef68f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 14 Feb 2013 17:13:24 +0100 Subject: [PATCH 73/87] Upgrade to Ruby 2.0.0 (r39237). --- ruby-1.9.3-arch-specific-dir.patch | 2 +- ruby-1.9.3-custom-rubygems-location.patch | 19 +++++++++---------- ruby-1.9.3-mkmf-verbose.patch | 8 ++++---- ...ed-paths-when-empty-version-string-i.patch | 12 ++++++------ ruby.spec | 6 +++--- 5 files changed, 23 insertions(+), 24 deletions(-) diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 2546128..7a79c18 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index d6af000..1c094a3 100644 --- a/configure.in +++ b/configure.in -@@ -3221,6 +3221,10 @@ AC_SUBST(rubylibprefix) +@@ -3188,6 +3188,10 @@ AC_SUBST(rubylibprefix) rubylibdir='${rubylibprefix}/${ruby_version}' rubyarchdir=${multiarch+'${rubyarchprefix}/${ruby_version}'}${multiarch-'${rubylibdir}/${arch}'} diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index 368d39b..c0b507a 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -1,4 +1,4 @@ -From 643a3d3af2a3847e730c79515bc586768053119a Mon Sep 17 00:00:00 2001 +From b5e9dc3683cb085aa57e7b12c35a4f21b2cc1482 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 11 Nov 2011 13:14:45 +0100 Subject: [PATCH] Allow to install RubyGems into custom location, outside of @@ -6,16 +6,15 @@ Subject: [PATCH] Allow to install RubyGems into custom location, outside of --- configure.in | 8 ++++++++ - tool/mkconfig.rb | 1 + tool/rbinstall.rb | 9 +++++++++ version.c | 4 ++++ - 4 files changed, 22 insertions(+) + 3 files changed, 21 insertions(+) diff --git a/configure.in b/configure.in -index 748edc9..6a16745 100644 +index 1627d12..e064b2b 100644 --- a/configure.in +++ b/configure.in -@@ -3256,6 +3256,13 @@ until VENDORARCH_DIR=`eval echo \\"${dir}\\"`; test "x${dir}" = "x${VENDORARCH_D +@@ -3256,6 +3256,13 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], [vendorarchdir=${multiarch+'${rubyarchprefix}/vendor_ruby/${ruby_version}'}${multiarch-'${vendorlibdir}/${sitearch}'}]) @@ -29,7 +28,7 @@ index 748edc9..6a16745 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX='""' -@@ -3316,6 +3323,7 @@ @@ AC_SUBST(sitedir)dnl +@@ -3316,6 +3323,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl @@ -38,7 +37,7 @@ index 748edc9..6a16745 100644 configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb -index 17294a2..2757a73 100755 +index 92e54c6..c72dfb6 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -313,6 +313,7 @@ sitelibdir = CONFIG["sitelibdir"] @@ -66,7 +65,7 @@ index 17294a2..2757a73 100755 install?(:local, :arch, :lib) do diff --git a/version.c b/version.c -index 962f39f..979701d 100644 +index 54c4513..d76100b 100644 --- a/version.c +++ b/version.c @@ -99,6 +99,10 @@ const char ruby_initial_load_paths[] = @@ -80,6 +79,6 @@ index 962f39f..979701d 100644 RUBY_LIB "\0" #ifdef RUBY_THINARCH RUBY_ARCH_LIB_FOR(RUBY_THINARCH) "\0" ---- -1.8.0 +-- +1.8.1.2 diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 30ffea8..de78ad8 100644 --- a/ruby-1.9.3-mkmf-verbose.patch +++ b/ruby-1.9.3-mkmf-verbose.patch @@ -1,4 +1,4 @@ -From b6f6f0b8cd750e97c15f1b739b1c95d6c1989294 Mon Sep 17 00:00:00 2001 +From ec16398159a161fc77436b4855d489f193b2515b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Mon, 19 Nov 2012 15:14:51 +0100 Subject: [PATCH] Verbose mkmf. @@ -8,10 +8,10 @@ Subject: [PATCH] Verbose mkmf. 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/mkmf.rb b/lib/mkmf.rb -index ded4e89..0870f22 100644 +index 4b6c52e..67a15ee 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb -@@ -1752,7 +1752,7 @@ SRC +@@ -1777,7 +1777,7 @@ SRC SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. @@ -21,5 +21,5 @@ index ded4e89..0870f22 100644 Q = $(Q1:0=@) ECHO1 = $(V:1=@#{CONFIG['NULLCMD']}) -- -1.8.0 +1.8.1.2 diff --git a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index 5a6c79a..1727e4c 100644 --- a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -1,4 +1,4 @@ -From 1e109d1a0265dfdde2324a6a97e4225eb4343efc Mon Sep 17 00:00:00 2001 +From e943a89efd63dcfb80a0ab8d9a4db37f523f508e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 8 Feb 2013 22:48:41 +0100 Subject: [PATCH] Prevent duplicated paths when empty version string is @@ -10,10 +10,10 @@ Subject: [PATCH] Prevent duplicated paths when empty version string is 2 files changed, 13 insertions(+) diff --git a/configure.in b/configure.in -index e83cfb4..d6af000 100644 +index 5850bbf..7604bb8 100644 --- a/configure.in +++ b/configure.in -@@ -3308,6 +3308,9 @@ shvar_to_cpp RIDIR "${ridir}" +@@ -3265,6 +3265,9 @@ shvar_to_cpp RIDIR "${ridir}" if test ${RUBY_LIB_VERSION_STYLE+set}; then AC_DEFINE_UNQUOTED(RUBY_LIB_VERSION_STYLE, $RUBY_LIB_VERSION_STYLE !!) else @@ -24,7 +24,7 @@ index e83cfb4..d6af000 100644 fi AC_DEFINE_UNQUOTED(RUBY_EXEC_PREFIX, ${RUBY_EXEC_PREFIX}) diff --git a/version.c b/version.c -index 6ba6453..c78f609 100644 +index 282960d..54c4513 100644 --- a/version.c +++ b/version.c @@ -39,9 +39,15 @@ @@ -43,7 +43,7 @@ index 6ba6453..c78f609 100644 #ifndef RUBY_ARCH_LIB_FOR #define RUBY_ARCH_LIB_FOR(arch) RUBY_LIB "/"arch #endif -@@ -79,8 +85,10 @@ const char ruby_initial_load_paths[] = +@@ -77,8 +83,10 @@ const char ruby_initial_load_paths[] = RUBY_SITE_ARCH_LIB_FOR(RUBY_THINARCH) "\0" #endif RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" @@ -54,7 +54,7 @@ index 6ba6453..c78f609 100644 #ifndef NO_RUBY_VENDOR_LIB RUBY_VENDOR_LIB2 "\0" -@@ -88,8 +96,10 @@ const char ruby_initial_load_paths[] = +@@ -86,8 +94,10 @@ const char ruby_initial_load_paths[] = RUBY_VENDOR_ARCH_LIB_FOR(RUBY_THINARCH) "\0" #endif RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0" diff --git a/ruby.spec b/ruby.spec index f8103de..e85377a 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 39217 +%global revision 39237 %global ruby_archive %{name}-%{ruby_version} @@ -823,8 +823,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Wed Feb 13 2013 Vít Ondruch - 2.0.0.0-0.2.r39217 -- Upgrade to Ruby 2.0.0 (r39217). +* Wed Feb 13 2013 Vít Ondruch - 2.0.0.0-0.2.r39237 +- Upgrade to Ruby 2.0.0 (r39237). * Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 - Upgrade to Ruby 2.0.0 (rc2). From ae0567b7b5870f0afae36d393041ea445980edc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 15 Feb 2013 18:06:40 +0100 Subject: [PATCH 74/87] Fix installation of binary gems. --- ...obal-Specification.dirs-during-insta.patch | 51 ++++++++++- rubygems-2.0.0-binary-extensions.patch | 84 +++++++++++++++---- 2 files changed, 119 insertions(+), 16 deletions(-) diff --git a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch index b082597..c7c4ef7 100644 --- a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch +++ b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch @@ -1,7 +1,7 @@ From b95b9942361104dc5b7fd08eb4970f893d8c1a54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 13 Feb 2013 13:12:30 +0100 -Subject: [PATCH 1/2] Remove duplicated check. +Subject: [PATCH 1/3] Remove duplicated check. The loaded specifications are rejected already in #gather_dependencies, so this condition cannot trigger. @@ -30,7 +30,7 @@ index d811f62..dffa8df 100644 From 2fa9087b1986db6c7945c0f997fed2bfff5ce06a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 13 Feb 2013 15:47:47 +0100 -Subject: [PATCH 2/2] Do not modify global Specification.dirs during +Subject: [PATCH 2/3] Do not modify global Specification.dirs during installation. While gems are installed into --install-dir just fine even without @@ -103,3 +103,50 @@ index dffa8df..841f26a 100644 -- 1.8.1.2 + +From d473204ce920702dd87257db49355929f31530d4 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Fri, 15 Feb 2013 17:02:44 +0100 +Subject: [PATCH 3/3] Default to Gem.dir as late as possible. + +--- + lib/rubygems/dependency_installer.rb | 2 +- + lib/rubygems/installer.rb | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/lib/rubygems/dependency_installer.rb b/lib/rubygems/dependency_installer.rb +index 841f26a..abcfa0f 100644 +--- a/lib/rubygems/dependency_installer.rb ++++ b/lib/rubygems/dependency_installer.rb +@@ -346,7 +346,7 @@ class Gem::DependencyInstaller + :force => @force, + :format_executable => @format_executable, + :ignore_dependencies => @ignore_dependencies, +- :install_dir => (@install_dir || Gem.dir), ++ :install_dir => @install_dir, + :security_policy => @security_policy, + :user_install => @user_install, + :wrappers => @wrappers, +diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb +index 780a88b..6543130 100644 +--- a/lib/rubygems/installer.rb ++++ b/lib/rubygems/installer.rb +@@ -535,13 +535,13 @@ class Gem::Installer + :bin_dir => nil, + :env_shebang => false, + :force => false, +- :install_dir => Gem.dir, + :only_install_dir => false + }.merge options + + @env_shebang = options[:env_shebang] + @force = options[:force] +- @gem_home = options[:install_dir] ++ @install_dir = options[:install_dir] ++ @gem_home = options[:install_dir] || Gem.dir + @ignore_dependencies = options[:ignore_dependencies] + @format_executable = options[:format_executable] + @security_policy = options[:security_policy] +-- +1.8.1.2 + diff --git a/rubygems-2.0.0-binary-extensions.patch b/rubygems-2.0.0-binary-extensions.patch index 43f3599..359b578 100644 --- a/rubygems-2.0.0-binary-extensions.patch +++ b/rubygems-2.0.0-binary-extensions.patch @@ -1,7 +1,7 @@ From ec90622235ae19b28a327cb50a10e0311e8f3d71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 3 Nov 2011 16:43:05 +0100 -Subject: [PATCH 1/7] Add dedicate extensions folder into $LOAD_PATH. +Subject: [PATCH 1/9] Add dedicate extensions folder into $LOAD_PATH. --- lib/rubygems/specification.rb | 32 ++++++++++++++++++++++++++++++-- @@ -68,13 +68,13 @@ index cabdf8d..87b14d2 100644 # # Formerly used to indicate this gem was RDoc-capable. -- -1.8.1 +1.8.1.2 From e42819f32fc5d935f7e7189ec4be8bdab0a2cf3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 16 Nov 2011 13:26:48 +0100 -Subject: [PATCH 2/7] Use spec's ext dir for extension installation. +Subject: [PATCH 2/9] Use spec's ext dir for extension installation. --- lib/rubygems/installer.rb | 2 +- @@ -119,13 +119,13 @@ index 87b14d2..492ddbe 100644 ## -- -1.8.1 +1.8.1.2 From 0e9dd0655111f7dda805233c79a3771459d9a66a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Wed, 16 Nov 2011 14:52:16 +0100 -Subject: [PATCH 3/7] Simplify the extending of $LOAD_PATH for binary gems. +Subject: [PATCH 3/9] Simplify the extending of $LOAD_PATH for binary gems. --- lib/rubygems/specification.rb | 11 +++++------ @@ -161,13 +161,13 @@ index 492ddbe..c703827 100644 ## -- -1.8.1 +1.8.1.2 From 9a8556c609e800d0dbd24af416d613f2e82f323c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 9 Dec 2011 16:31:04 +0100 -Subject: [PATCH 4/7] Fix the binary extension search path construction. +Subject: [PATCH 4/9] Fix the binary extension search path construction. --- lib/rubygems/installer.rb | 2 +- @@ -210,13 +210,13 @@ index c703827..fa9ea6e 100644 ## -- -1.8.1 +1.8.1.2 From 476c2f90cc6f5f490858f253a9b23eb19d53d2fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 13 Dec 2011 12:14:54 +0100 -Subject: [PATCH 5/7] Remove binary extensions during uninstall. +Subject: [PATCH 5/9] Remove binary extensions during uninstall. --- lib/rubygems/uninstaller.rb | 1 + @@ -235,13 +235,13 @@ index d672b9d..5c31a0c 100644 # TODO: should this be moved to spec?... I vote eww (also exists in docmgr) old_platform_name = [spec.name, -- -1.8.1 +1.8.1.2 From 35dc17e86f701fe1be80d98ace79735c535fd570 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 13 Dec 2011 14:27:14 +0100 -Subject: [PATCH 6/7] Avoid dependency on customized operating_system.rb. +Subject: [PATCH 6/9] Avoid dependency on customized operating_system.rb. --- lib/rubygems/defaults.rb | 11 +++++++++++ @@ -287,13 +287,13 @@ index fa9ea6e..2b10499 100644 ## -- -1.8.1 +1.8.1.2 From 0937c0b0a3c2ed08ab5b0875f7f95e24157525c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 7 Feb 2013 13:07:34 +0100 -Subject: [PATCH 7/7] Fix binary extensions installation when --install-dir is +Subject: [PATCH 7/9] Fix binary extensions installation when --install-dir is specified. --- @@ -314,5 +314,61 @@ index f1f2ad7..e1577fc 100644 spec.extensions.each do |extension| -- -1.8.1 +1.8.1.2 + + +From 4d9675cab5decaef3c9f7f91b2f9c9abd2a19cea Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Fri, 15 Feb 2013 16:24:29 +0100 +Subject: [PATCH 8/9] mkmf does not create folder for binary extensions + anymore. + +This was dropped in Ruby r37016 for some reasons :/ +--- + lib/rubygems/ext/builder.rb | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/lib/rubygems/ext/builder.rb b/lib/rubygems/ext/builder.rb +index d7d953f..812c20c 100644 +--- a/lib/rubygems/ext/builder.rb ++++ b/lib/rubygems/ext/builder.rb +@@ -21,6 +21,10 @@ class Gem::Ext::Builder + mf = mf.gsub(/^RUBYLIBDIR\s*=\s*\$[^$]*/, "RUBYLIBDIR = #{dest_path}") + mf = mf.gsub(/\s*\S+\.time$/, "") + ++ # Folder creation was dropped in r37016 for some reasons :/ ++ target_prefix = mf[/^target_prefix\s*=\s*(.*)/, 1] ++ FileUtils.mkdir_p File.join(dest_path, target_prefix) rescue nil # in case of perms issues -- lame ++ + File.open('Makefile', 'wb') {|f| f.print mf} + + # try to find make program from Ruby configure arguments first +-- +1.8.1.2 + + +From 062a11c59731f5875d5a8821a212c8a41cb84577 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Fri, 15 Feb 2013 17:07:07 +0100 +Subject: [PATCH 9/9] Use correct option. + +--- + lib/rubygems/installer.rb | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb +index e1577fc..1492c68 100644 +--- a/lib/rubygems/installer.rb ++++ b/lib/rubygems/installer.rb +@@ -642,7 +642,7 @@ TEXT + say "This could take a while..." + end + +- dest_path = File.join(options[:install_dir] ? gem_dir : spec.ext_dir, spec.require_paths.first) ++ dest_path = File.join(@install_dir ? gem_dir : spec.ext_dir, spec.require_paths.first) + ran_rake = false # only run rake once + + spec.extensions.each do |extension| +-- +1.8.1.2 From 27f535fbb26216aacddcc291e8a89bf504fbd4f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 19 Feb 2013 10:13:20 +0100 Subject: [PATCH 75/87] Introduce %gem_install macro. --- ruby.spec | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/ruby.spec b/ruby.spec index e85377a..cb13286 100644 --- a/ruby.spec +++ b/ruby.spec @@ -443,6 +443,19 @@ cat >> %{buildroot}%{_sysconfdir}/rpm/macros.rubygems << \EOF %%gem_cache %%{gem_dir}/cache/%%{gem_name}-%%{version}.gem %%gem_spec %%{gem_dir}/specifications/%%{gem_name}-%%{version}.gemspec %%gem_docdir %%{gem_dir}/doc/%%{gem_name}-%%{version} + +# Install gem into appropriate directory. +# -n Allows to override gem for installation. +%%gem_install(n:) \ +CONFIGURE_ARGS="--with-cflags='%%{optflags}' $CONFIGURE_ARGS" \\\ +gem install \\\ + -V \\\ + --local \\\ + --install-dir .%{gem_dir} \\\ + --bindir .%{_bindir} \\\ + --force \\\ + --document=ri,rdoc \\\ + %%{-n*}%%{!?-n:%{gem_name}-%{version}.gem} EOF # Install custom operating_system.rb. @@ -825,6 +838,7 @@ make check TESTS="-v $DISABLE_TESTS" %changelog * Wed Feb 13 2013 Vít Ondruch - 2.0.0.0-0.2.r39237 - Upgrade to Ruby 2.0.0 (r39237). +- Introduce %%gem_install macro. * Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 - Upgrade to Ruby 2.0.0 (rc2). From d5cde5c082f79d42e3d0b9810d37bd37ffd37430 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Tue, 19 Feb 2013 13:46:31 +0100 Subject: [PATCH 76/87] Create the .%{gem_dir} and allow to override gem installation dir. --- ruby.spec | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/ruby.spec b/ruby.spec index cb13286..d14271a 100644 --- a/ruby.spec +++ b/ruby.spec @@ -445,17 +445,20 @@ cat >> %{buildroot}%{_sysconfdir}/rpm/macros.rubygems << \EOF %%gem_docdir %%{gem_dir}/doc/%%{gem_name}-%%{version} # Install gem into appropriate directory. -# -n Allows to override gem for installation. -%%gem_install(n:) \ +# -n Overrides gem file name for installation. +# -d Set installation directory. +%%gem_install(d:n:) \ +mkdir -p '%%{-d*}%%{!?-d:.%{gem_dir}}' \ +\ CONFIGURE_ARGS="--with-cflags='%%{optflags}' $CONFIGURE_ARGS" \\\ gem install \\\ -V \\\ --local \\\ - --install-dir .%{gem_dir} \\\ + --install-dir '%%{-d*}%%{!?-d:.%{gem_dir}}' \\\ --bindir .%{_bindir} \\\ --force \\\ --document=ri,rdoc \\\ - %%{-n*}%%{!?-n:%{gem_name}-%{version}.gem} + '%%{-n*}%%{!?-n:%{gem_name}-%{version}.gem}' EOF # Install custom operating_system.rb. From ab0e460c3c018b728da6bfef5e2e6ae48b2be6d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 21 Feb 2013 09:58:27 +0100 Subject: [PATCH 77/87] Macros should not be expanded during Ruby build. --- ruby.spec | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ruby.spec b/ruby.spec index d14271a..5d9d340 100644 --- a/ruby.spec +++ b/ruby.spec @@ -448,17 +448,17 @@ cat >> %{buildroot}%{_sysconfdir}/rpm/macros.rubygems << \EOF # -n Overrides gem file name for installation. # -d Set installation directory. %%gem_install(d:n:) \ -mkdir -p '%%{-d*}%%{!?-d:.%{gem_dir}}' \ +mkdir -p %%{-d*}%%{!?-d:.%%{gem_dir}} \ \ CONFIGURE_ARGS="--with-cflags='%%{optflags}' $CONFIGURE_ARGS" \\\ gem install \\\ -V \\\ --local \\\ - --install-dir '%%{-d*}%%{!?-d:.%{gem_dir}}' \\\ - --bindir .%{_bindir} \\\ + --install-dir %%{-d*}%%{!?-d:.%%{gem_dir}} \\\ + --bindir .%%{_bindir} \\\ --force \\\ --document=ri,rdoc \\\ - '%%{-n*}%%{!?-n:%{gem_name}-%{version}.gem}' + %%{-n*}%%{!?-n:%%{gem_name}-%%{version}.gem} EOF # Install custom operating_system.rb. From 9ccbda6047df8af7f71196c77cbe0618cc09a6eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 21 Feb 2013 14:36:05 +0100 Subject: [PATCH 78/87] Upgrade to Ruby 2.0.0 (r39357). --- ruby-1.9.3-always-use-i386.patch | 2 +- ruby-1.9.3-arch-specific-dir.patch | 2 +- ruby-1.9.3-custom-rubygems-location.patch | 12 ++++++------ ...licated-paths-when-empty-version-string-i.patch | 2 +- ruby.spec | 14 +++++++++----- ...fy-global-Specification.dirs-during-insta.patch | 2 +- rubygems-2.0.0-binary-extensions.patch | 8 ++++---- 7 files changed, 23 insertions(+), 19 deletions(-) diff --git a/ruby-1.9.3-always-use-i386.patch b/ruby-1.9.3-always-use-i386.patch index bcb3a08..dec6994 100644 --- a/ruby-1.9.3-always-use-i386.patch +++ b/ruby-1.9.3-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index 418b0cb..d26fe5b 100644 --- a/configure.in +++ b/configure.in -@@ -3320,6 +3320,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -3362,6 +3362,8 @@ AC_SUBST(vendorarchdir)dnl configure_args=$ac_configure_args AC_SUBST(configure_args)dnl diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index 7a79c18..e32814b 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index d6af000..1c094a3 100644 --- a/configure.in +++ b/configure.in -@@ -3188,6 +3188,10 @@ AC_SUBST(rubylibprefix) +@@ -3217,6 +3217,10 @@ AC_SUBST(rubylibprefix) rubylibdir='${rubylibprefix}/${ruby_version}' rubyarchdir=${multiarch+'${rubyarchprefix}/${ruby_version}'}${multiarch-'${rubylibdir}/${arch}'} diff --git a/ruby-1.9.3-custom-rubygems-location.patch b/ruby-1.9.3-custom-rubygems-location.patch index c0b507a..4a3e7cb 100644 --- a/ruby-1.9.3-custom-rubygems-location.patch +++ b/ruby-1.9.3-custom-rubygems-location.patch @@ -14,9 +14,9 @@ diff --git a/configure.in b/configure.in index 1627d12..e064b2b 100644 --- a/configure.in +++ b/configure.in -@@ -3256,6 +3256,13 @@ AC_ARG_WITH(vendorarchdir, +@@ -3292,6 +3292,13 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], - [vendorarchdir=${multiarch+'${rubyarchprefix}/vendor_ruby/${ruby_version}'}${multiarch-'${vendorlibdir}/${sitearch}'}]) + [vendorarchdir=${multiarch+'${rubysitearchprefix}/vendor_ruby/${ruby_version}'}${multiarch-'${vendorlibdir}/${sitearch}'}]) +AC_ARG_WITH(rubygemsdir, + AS_HELP_STRING([--with-rubygemsdir=DIR], [custom rubygems directory]), @@ -25,10 +25,10 @@ index 1627d12..e064b2b 100644 + AC_DEFINE_UNQUOTED(RUBYGEMS_DIR,"$rubygemsdir" !!) +fi + - if test "${LOAD_RELATIVE+set}"; then - AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) - RUBY_EXEC_PREFIX='""' -@@ -3316,6 +3323,7 @@ AC_SUBST(sitearchdir)dnl + unexpand_shvar rubylibprefix exec_prefix libdir RUBY_BASE_NAME + unexpand_shvar rubyarchprefix exec_prefix libdir arch RUBY_BASE_NAME archlibdir rubylibprefix + unexpand_shvar rubysitearchprefix exec_prefix libdir sitearch arch RUBY_BASE_NAME archlibdir sitearchlibdir rubylibprefix +@@ -3358,6 +3365,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index 1727e4c..a6a8106 100644 --- a/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -13,7 +13,7 @@ diff --git a/configure.in b/configure.in index 5850bbf..7604bb8 100644 --- a/configure.in +++ b/configure.in -@@ -3265,6 +3265,9 @@ shvar_to_cpp RIDIR "${ridir}" +@@ -3306,6 +3306,9 @@ unexpand_shvar exec_prefix prefix if test ${RUBY_LIB_VERSION_STYLE+set}; then AC_DEFINE_UNQUOTED(RUBY_LIB_VERSION_STYLE, $RUBY_LIB_VERSION_STYLE !!) else diff --git a/ruby.spec b/ruby.spec index 5d9d340..46f5e2b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 39237 +%global revision 39357 %global ruby_archive %{name}-%{ruby_version} @@ -42,7 +42,7 @@ %global ruby_vendorlibdir %{_datadir}/ruby/%{ruby_vendordir} %global ruby_vendorarchdir %{_libdir}/ruby/%{ruby_vendordir} -%global rubygems_version 2.0.0.rc.2 +%global rubygems_version 2.0.0 # The RubyGems library has to stay out of Ruby directory three, since the # RubyGems should be share by all Ruby implementations. @@ -59,7 +59,7 @@ # TODO: The IRB has strange versioning. Keep the Ruby's versioning ATM. # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} -%global rdoc_version 4.0.0.rc.2.1 +%global rdoc_version 4.0.0 %global bigdecimal_version 1.1.0 %global io_console_version 0.4.1 %global json_version 1.7.7 @@ -557,6 +557,10 @@ DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" %endif +# The TestRbConfig errors, which does not respect configuration options. +# http://bugs.ruby-lang.org/issues/7902 +DISABLE_TESTS="-x test_rbconfig.rb $DISABLE_TESTS" + make check TESTS="-v $DISABLE_TESTS" %post libs -p /sbin/ldconfig @@ -839,8 +843,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Wed Feb 13 2013 Vít Ondruch - 2.0.0.0-0.2.r39237 -- Upgrade to Ruby 2.0.0 (r39237). +* Thu Feb 21 2013 Vít Ondruch - 2.0.0.0-0.1.r39357 +- Upgrade to Ruby 2.0.0 (r39357). - Introduce %%gem_install macro. * Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 diff --git a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch index c7c4ef7..a6d2334 100644 --- a/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch +++ b/rubygems-2.0.0-Do-not-modify-global-Specification.dirs-during-insta.patch @@ -131,7 +131,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 780a88b..6543130 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -535,13 +535,13 @@ class Gem::Installer +@@ -536,13 +536,13 @@ class Gem::Installer :bin_dir => nil, :env_shebang => false, :force => false, diff --git a/rubygems-2.0.0-binary-extensions.patch b/rubygems-2.0.0-binary-extensions.patch index 359b578..d826472 100644 --- a/rubygems-2.0.0-binary-extensions.patch +++ b/rubygems-2.0.0-binary-extensions.patch @@ -85,7 +85,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 780a88b..854c177 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -642,7 +642,7 @@ TEXT +@@ -645,7 +645,7 @@ TEXT say "This could take a while..." end @@ -178,7 +178,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index 854c177..f1f2ad7 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -642,7 +642,7 @@ TEXT +@@ -645,7 +645,7 @@ TEXT say "This could take a while..." end @@ -304,7 +304,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index f1f2ad7..e1577fc 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -642,7 +642,7 @@ TEXT +@@ -645,7 +645,7 @@ TEXT say "This could take a while..." end @@ -360,7 +360,7 @@ diff --git a/lib/rubygems/installer.rb b/lib/rubygems/installer.rb index e1577fc..1492c68 100644 --- a/lib/rubygems/installer.rb +++ b/lib/rubygems/installer.rb -@@ -642,7 +642,7 @@ TEXT +@@ -645,7 +645,7 @@ TEXT say "This could take a while..." end From 366b0e9454bc51d79f4f6fb74541f4287599a9cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 21 Feb 2013 14:37:50 +0100 Subject: [PATCH 79/87] Ensure that rubygem-bigdecimal has higher release then the one from Ruby 1.9.3. --- ruby.spec | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index 46f5e2b..1c6885f 100644 --- a/ruby.spec +++ b/ruby.spec @@ -27,6 +27,7 @@ %global release 1 +%{!?release_string:%global release_string %{?development_release:0.}%{release}%{?development_release:.%{development_release}}%{?dist}} %global ruby_libdir %{_datadir}/%{name} %global ruby_libarchdir %{_libdir}/%{name} @@ -77,7 +78,7 @@ Summary: An interpreter of object-oriented scripting language Name: ruby Version: %{ruby_version_patch_level} -Release: %{?development_release:0.}%{release}%{?development_release:.%{development_release}}%{?dist} +Release: %{release_string} Group: Development/Languages # Public Domain for example for: include/ruby/st.h, strftime.c, ... License: (Ruby or BSD) and Public Domain @@ -262,6 +263,11 @@ This package contains documentation for %{name}. %package -n rubygem-bigdecimal Summary: BigDecimal provides arbitrary-precision floating point decimal arithmetic Version: %{bigdecimal_version} +# This could colide with previous releases of bigdecimal. Prefix +# the bigdecimal release number with Ruby version to avoid collisions (this +# breaks prerelease versioning, but I see no way around). +# https://bugs.ruby-lang.org/issues/7761 +Release: %{major_version}%{minor_version}%{teeny_version}.%{release_string} Group: Development/Libraries License: GPL+ or Artistic Requires: ruby(release) From 452d82629d29e6a1f0224e412cccf0925b629f3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Thu, 21 Feb 2013 15:52:32 +0100 Subject: [PATCH 80/87] Add reference to upstream ticket possibly removing one patch. --- ruby.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ruby.spec b/ruby.spec index 1c6885f..daef2b0 100644 --- a/ruby.spec +++ b/ruby.spec @@ -103,6 +103,8 @@ Patch4: ruby-1.9.3-fix-s390x-build.patch Patch8: ruby-1.9.3-custom-rubygems-location.patch # Add support for installing binary extensions according to FHS. # https://github.com/rubygems/rubygems/issues/210 +# Note that 8th patch might be resolved by +# https://bugs.ruby-lang.org/issues/7897 Patch9: rubygems-2.0.0-binary-extensions.patch # Make mkmf verbose by default Patch12: ruby-1.9.3-mkmf-verbose.patch From 6bbe91338d87c8bc9455025bff59e155757b7108 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 09:09:33 +0100 Subject: [PATCH 81/87] Revert "Add architecture dependency on ruby-libs to ruby-irb." This reverts commit d3938ffb0a8cf3e4917fd8a2ad8e491791ff23d0, since it produces build error: BuildError: mismatch when analyzing ruby-irb-2.0.0.0-0.1.r39357.fc19.noarch.rpm, rpmdiff output was: removed REQUIRES ruby-libs(x86-64) = 2.0.0.0 added REQUIRES ruby-libs(x86-32) = 2.0.0.0 --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index daef2b0..acee48b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -220,7 +220,7 @@ specified in standard Ruby syntax. Summary: The Interactive Ruby Version: %{irb_version} Group: Development/Libraries -Requires: %{name}-libs%{?_isa} = %{ruby_version_patch_level} +Requires: %{name}-libs = %{ruby_version_patch_level} Provides: irb = %{version}-%{release} Provides: ruby(irb) = %{version}-%{release} BuildArch: noarch From ed5c12686264e5bf10182576fb9997a5d33ea4be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 11:52:15 +0100 Subject: [PATCH 82/87] Adjust the patch to pass test_archdirs(TestRbConfig). This is hopefuly better aligned with upstream intentions. --- ruby-1.9.3-arch-specific-dir.patch | 4 ++-- ruby.spec | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby-1.9.3-arch-specific-dir.patch b/ruby-1.9.3-arch-specific-dir.patch index e32814b..fcdc2fc 100644 --- a/ruby-1.9.3-arch-specific-dir.patch +++ b/ruby-1.9.3-arch-specific-dir.patch @@ -15,8 +15,8 @@ index d6af000..1c094a3 100644 rubylibdir='${rubylibprefix}/${ruby_version}' rubyarchdir=${multiarch+'${rubyarchprefix}/${ruby_version}'}${multiarch-'${rubylibdir}/${arch}'} -+AC_ARG_WITH(archdir, -+ AS_HELP_STRING([--with-archdir=DIR], [architecture specific ruby libraries [[LIBDIR/RUBY_BASE_NAME/ARCH]]]), ++AC_ARG_WITH(rubyarchdir, ++ AS_HELP_STRING([--with-rubyarchdir=DIR], [architecture specific ruby libraries [[LIBDIR/RUBY_BASE_NAME/ARCH]]]), + [rubyarchdir=$withval]) + rubyarchprefix=${multiarch+'${archlibdir}/${RUBY_BASE_NAME}'}${multiarch-'${rubylibprefix}/${arch}'} diff --git a/ruby.spec b/ruby.spec index acee48b..a28f669 100644 --- a/ruby.spec +++ b/ruby.spec @@ -392,7 +392,7 @@ autoconf %configure \ --with-rubylibprefix='%{ruby_libdir}' \ - --with-archdir='%{ruby_libarchdir}' \ + --with-rubyarchdir='%{ruby_libarchdir}' \ --with-sitedir='%{ruby_sitelibdir}' \ --with-sitearchdir='%{ruby_sitearchdir}' \ --with-vendordir='%{ruby_vendorlibdir}' \ From 54c8ac4750b6dad67f574c2a0a5749aa5af57c00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 12:08:37 +0100 Subject: [PATCH 83/87] One PPC error was fixed, other was introduced. --- ruby.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index a28f669..fc9e084 100644 --- a/ruby.spec +++ b/ruby.spec @@ -560,9 +560,9 @@ DISABLE_TESTS="-x test_dl2.rb $DISABLE_TESTS" %endif %ifarch ppc ppc64 -# test_ioctl_linux(TestIO) fails with #. -# https://bugs.ruby-lang.org/issues/7718 -DISABLE_TESTS="-x test_io.rb $DISABLE_TESTS" +# test_spawn_too_long_path(TestProcess) fails with [Errno::ENOENT, Errno::E2BIG, nil] expected but nothing was raised. +# https://bugs.ruby-lang.org/issues/7904 +DISABLE_TESTS="-x test_process.rb $DISABLE_TESTS" %endif # The TestRbConfig errors, which does not respect configuration options. From 84dd0dc693f2f0a696e9bbfa6c421923d659c0dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 12:09:14 +0100 Subject: [PATCH 84/87] Change to backport error number. --- ruby.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruby.spec b/ruby.spec index fc9e084..0c58260 100644 --- a/ruby.spec +++ b/ruby.spec @@ -566,7 +566,7 @@ DISABLE_TESTS="-x test_process.rb $DISABLE_TESTS" %endif # The TestRbConfig errors, which does not respect configuration options. -# http://bugs.ruby-lang.org/issues/7902 +# http://bugs.ruby-lang.org/issues/7912 DISABLE_TESTS="-x test_rbconfig.rb $DISABLE_TESTS" make check TESTS="-v $DISABLE_TESTS" From 0381e734491a4d49292f2b45c6c320c4d8fa7a81 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 12:24:10 +0100 Subject: [PATCH 85/87] Upgrade to Ruby 2.0.0 (r39387). --- ruby.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby.spec b/ruby.spec index 0c58260..343ace1 100644 --- a/ruby.spec +++ b/ruby.spec @@ -13,7 +13,7 @@ #%%global milestone preview2 # Keep the revision enabled for pre-releases from SVN. -%global revision 39357 +%global revision 39387 %global ruby_archive %{name}-%{ruby_version} @@ -851,8 +851,8 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Thu Feb 21 2013 Vít Ondruch - 2.0.0.0-0.1.r39357 -- Upgrade to Ruby 2.0.0 (r39357). +* Thu Feb 21 2013 Vít Ondruch - 2.0.0.0-0.1.r39387 +- Upgrade to Ruby 2.0.0 (r39387). - Introduce %%gem_install macro. * Tue Feb 05 2013 Vít Ondruch - 2.0.0.0-0.1.rc2 From 7719831647abc8843d8f90cda09122bc8752db29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 12:25:06 +0100 Subject: [PATCH 86/87] Fix rubygem-bigdecimal version. Upstream patch applied, until it is backported for 2.0.0. --- ruby.spec | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/ruby.spec b/ruby.spec index 343ace1..2370300 100644 --- a/ruby.spec +++ b/ruby.spec @@ -61,7 +61,7 @@ # http://redmine.ruby-lang.org/issues/5313 %global irb_version %{ruby_version_patch_level} %global rdoc_version 4.0.0 -%global bigdecimal_version 1.1.0 +%global bigdecimal_version 1.2.0 %global io_console_version 0.4.1 %global json_version 1.7.7 %global minitest_version 4.3.2 @@ -93,6 +93,9 @@ Source3: ruby-exercise.stp Patch0: ruby-2.0.0-Prevent-duplicated-paths-when-empty-version-string-i.patch # http://bugs.ruby-lang.org/issues/7808 Patch1: ruby-1.9.3-arch-specific-dir.patch +# Fixes rubygem-bigdecimla version. +# https://bugs.ruby-lang.org/issues/7761 +Patch2: ruby-2.0.0-ext-bigdecimal-bigdecimal.gemspec-bump-to-1.2.0.patch # Force multiarch directories for i.86 to be always named i386. This solves # some differencies in build between Fedora and RHEL. Patch3: ruby-1.9.3-always-use-i386.patch @@ -265,11 +268,6 @@ This package contains documentation for %{name}. %package -n rubygem-bigdecimal Summary: BigDecimal provides arbitrary-precision floating point decimal arithmetic Version: %{bigdecimal_version} -# This could colide with previous releases of bigdecimal. Prefix -# the bigdecimal release number with Ruby version to avoid collisions (this -# breaks prerelease versioning, but I see no way around). -# https://bugs.ruby-lang.org/issues/7761 -Release: %{major_version}%{minor_version}%{teeny_version}.%{release_string} Group: Development/Libraries License: GPL+ or Artistic Requires: ruby(release) @@ -376,6 +374,7 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch0 -p1 %patch1 -p1 +%patch2 -p1 %patch3 -p1 %patch4 -p1 %patch8 -p1 From 5c3192eb43e3f9d30a90b7476376253fa7af5c9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADt=20Ondruch?= Date: Fri, 22 Feb 2013 13:43:34 +0100 Subject: [PATCH 87/87] Fix random WEBRick test failures. --- ruby-1.9.3.p195-fix-webrick-tests.patch | 13 +++++++++++++ ruby.spec | 4 ++++ 2 files changed, 17 insertions(+) create mode 100644 ruby-1.9.3.p195-fix-webrick-tests.patch diff --git a/ruby-1.9.3.p195-fix-webrick-tests.patch b/ruby-1.9.3.p195-fix-webrick-tests.patch new file mode 100644 index 0000000..b340bff --- /dev/null +++ b/ruby-1.9.3.p195-fix-webrick-tests.patch @@ -0,0 +1,13 @@ +diff --git a/test/runner.rb b/test/runner.rb +index 49844c7..8e59a85 100644 +--- a/test/runner.rb ++++ b/test/runner.rb +@@ -2,6 +2,8 @@ require 'rbconfig' + + require 'test/unit' + ++require_relative 'ruby/envutil' ++ + src_testdir = File.dirname(File.realpath(__FILE__)) + $LOAD_PATH << src_testdir + module Gem diff --git a/ruby.spec b/ruby.spec index 2370300..d3bbd48 100644 --- a/ruby.spec +++ b/ruby.spec @@ -101,6 +101,9 @@ Patch2: ruby-2.0.0-ext-bigdecimal-bigdecimal.gemspec-bump-to-1.2.0.patch Patch3: ruby-1.9.3-always-use-i386.patch # http://redmine.ruby-lang.org/issues/5465 Patch4: ruby-1.9.3-fix-s390x-build.patch +# Fixes random WEBRick test failures. +# https://bugs.ruby-lang.org/issues/6573. +Patch5: ruby-1.9.3.p195-fix-webrick-tests.patch # Allows to install RubyGems into custom directory, outside of Ruby's tree. # http://redmine.ruby-lang.org/issues/5617 Patch8: ruby-1.9.3-custom-rubygems-location.patch @@ -377,6 +380,7 @@ Tcl/Tk interface for the object-oriented scripting language Ruby. %patch2 -p1 %patch3 -p1 %patch4 -p1 +%patch5 -p1 %patch8 -p1 %patch9 -p1 %patch12 -p1