From b4b6c00b6bab433842f7fe268eb98810919c3596 Mon Sep 17 00:00:00 2001 From: Vít Ondruch Date: Jun 11 2015 12:33:33 +0000 Subject: Upgrade to Ruby 2.3.0 (r50815). Move gemified net-telnet into subpackage. --- diff --git a/ruby-1.9.3-mkmf-verbose.patch b/ruby-1.9.3-mkmf-verbose.patch index 2a0b422..54039e0 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 682eb46..e6b1445 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb -@@ -1883,7 +1883,7 @@ SRC +@@ -1892,7 +1892,7 @@ SRC SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. diff --git a/ruby-2.1.0-Allow-to-specify-additional-preludes-by-configuratio.patch b/ruby-2.1.0-Allow-to-specify-additional-preludes-by-configuratio.patch index e51ac10..ca5727e 100644 --- a/ruby-2.1.0-Allow-to-specify-additional-preludes-by-configuratio.patch +++ b/ruby-2.1.0-Allow-to-specify-additional-preludes-by-configuratio.patch @@ -39,7 +39,7 @@ diff --git a/configure.in b/configure.in index 0e371e2..d4f1dcb 100644 --- a/configure.in +++ b/configure.in -@@ -4202,6 +4202,13 @@ AC_SUBST(rubyarchhdrdir)dnl +@@ -4203,6 +4203,13 @@ AC_SUBST(rubyarchhdrdir)dnl AC_SUBST(sitearchhdrdir)dnl AC_SUBST(vendorarchhdrdir)dnl diff --git a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch index 1d1c776..5070d07 100644 --- a/ruby-2.1.0-Enable-configuration-of-archlibdir.patch +++ b/ruby-2.1.0-Enable-configuration-of-archlibdir.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index 37d9a62..553d4d0 100644 --- a/configure.in +++ b/configure.in -@@ -3448,6 +3448,11 @@ if test ${multiarch+set}; then +@@ -3449,6 +3449,11 @@ if test ${multiarch+set}; then fi archlibdir='${libdir}/${arch}' diff --git a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch index f55a8ff..1b3dc3f 100644 --- a/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch +++ b/ruby-2.1.0-Prevent-duplicated-paths-when-empty-version-string-i.patch @@ -14,7 +14,7 @@ diff --git a/configure.in b/configure.in index db37cd6..ce8d149 100644 --- a/configure.in +++ b/configure.in -@@ -4056,7 +4056,8 @@ AS_CASE(["$ruby_version_dir_name"], +@@ -4057,7 +4057,8 @@ AS_CASE(["$ruby_version_dir_name"], ruby_version_dir=/'${ruby_version_dir_name}' if test -z "${ruby_version_dir_name}"; then diff --git a/ruby-2.1.0-always-use-i386.patch b/ruby-2.1.0-always-use-i386.patch index 98cca14..c35e0fd 100644 --- a/ruby-2.1.0-always-use-i386.patch +++ b/ruby-2.1.0-always-use-i386.patch @@ -11,7 +11,7 @@ diff --git a/configure.in b/configure.in index 553d4d0..03a4152 100644 --- a/configure.in +++ b/configure.in -@@ -4120,6 +4120,8 @@ AC_SUBST(vendorarchdir)dnl +@@ -4121,6 +4121,8 @@ AC_SUBST(vendorarchdir)dnl AC_SUBST(CONFIGURE, "`echo $0 | sed 's|.*/||'`")dnl AC_SUBST(configure_args, "`echo "${ac_configure_args}" | sed 's/\\$/$$/g'`")dnl diff --git a/ruby-2.1.0-custom-rubygems-location.patch b/ruby-2.1.0-custom-rubygems-location.patch index 6727933..6696f42 100644 --- a/ruby-2.1.0-custom-rubygems-location.patch +++ b/ruby-2.1.0-custom-rubygems-location.patch @@ -15,7 +15,7 @@ diff --git a/configure.in b/configure.in index 03a4152..0e371e2 100644 --- a/configure.in +++ b/configure.in -@@ -4092,6 +4092,10 @@ AC_ARG_WITH(vendorarchdir, +@@ -4093,6 +4093,10 @@ AC_ARG_WITH(vendorarchdir, [vendorarchdir=$withval], [vendorarchdir=${multiarch+'${rubysitearchprefix}/vendor_ruby'${ruby_version_dir}}${multiarch-'${vendorlibdir}/${sitearch}'}]) @@ -26,7 +26,7 @@ index 03a4152..0e371e2 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) RUBY_EXEC_PREFIX='' -@@ -4116,6 +4120,7 @@ AC_SUBST(sitearchdir)dnl +@@ -4117,6 +4121,7 @@ AC_SUBST(sitearchdir)dnl AC_SUBST(vendordir)dnl AC_SUBST(vendorlibdir)dnl AC_SUBST(vendorarchdir)dnl diff --git a/ruby-2.3.0-Fix-require-paths-for-BigDecimal-and-io-console.patch b/ruby-2.3.0-Fix-require-paths-for-BigDecimal-and-io-console.patch new file mode 100644 index 0000000..d43886a --- /dev/null +++ b/ruby-2.3.0-Fix-require-paths-for-BigDecimal-and-io-console.patch @@ -0,0 +1,51 @@ +From 4555bde348ed0c33f7969df014fc857539f5f5eb Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Thu, 11 Jun 2015 09:18:34 +0200 +Subject: [PATCH 1/2] Fix io-console require path. + +--- + ext/io/console/io-console.gemspec | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ext/io/console/io-console.gemspec b/ext/io/console/io-console.gemspec +index 309b9bd..52ecdd9 100644 +--- a/ext/io/console/io-console.gemspec ++++ b/ext/io/console/io-console.gemspec +@@ -12,7 +12,7 @@ Gem::Specification.new do |s| + s.required_ruby_version = ">= 2.0.0" + s.homepage = "http://www.ruby-lang.org" + s.authors = ["Nobu Nakada"] +- s.require_path = %[.] ++ s.require_path = %[lib] + s.files = %w[console.c extconf.rb lib/console/size.rb] + s.extensions = %w[extconf.rb] + s.licenses = "ruby" +-- +2.4.0 + + +From ef7e13b70efd88d0eff3d060cfbd2df01f1f90d9 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?V=C3=ADt=20Ondruch?= +Date: Thu, 11 Jun 2015 09:22:57 +0200 +Subject: [PATCH 2/2] Fix bigdecimal require path. + +--- + ext/bigdecimal/bigdecimal.gemspec | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ext/bigdecimal/bigdecimal.gemspec b/ext/bigdecimal/bigdecimal.gemspec +index e0c24db..c93c2b6 100644 +--- a/ext/bigdecimal/bigdecimal.gemspec ++++ b/ext/bigdecimal/bigdecimal.gemspec +@@ -12,7 +12,7 @@ Gem::Specification.new do |s| + s.email = "mrkn@mrkn.jp" + s.description = "This library provides arbitrary-precision decimal floating-point number class." + s.authors = ["Kenta Murata", "Zachary Scott", "Shigeo Kobayashi"] +- s.require_path = %[.] ++ s.require_path = %[lib] + s.files = %w[ + bigdecimal.gemspec + bigdecimal.c +-- +2.4.0 + diff --git a/ruby-2.3.0-ruby_version.patch b/ruby-2.3.0-ruby_version.patch index 2b87d4d..f2b8f0c 100644 --- a/ruby-2.3.0-ruby_version.patch +++ b/ruby-2.3.0-ruby_version.patch @@ -20,7 +20,7 @@ diff --git a/configure.in b/configure.in index db37cd6..6e73fae 100644 --- a/configure.in +++ b/configure.in -@@ -4005,9 +4005,6 @@ AS_CASE(["$target_os"], +@@ -4006,9 +4006,6 @@ AS_CASE(["$target_os"], rubyw_install_name='$(RUBYW_INSTALL_NAME)' ]) @@ -30,7 +30,7 @@ index db37cd6..6e73fae 100644 rubyarchprefix=${multiarch+'${archlibdir}/${RUBY_BASE_NAME}'}${multiarch-'${rubylibprefix}/${arch}'} AC_ARG_WITH(rubyarchprefix, AS_HELP_STRING([--with-rubyarchprefix=DIR], -@@ -4030,58 +4027,64 @@ AC_ARG_WITH(ridir, +@@ -4031,58 +4028,64 @@ AC_ARG_WITH(ridir, AC_SUBST(ridir) AC_SUBST(RI_BASE_NAME) @@ -124,7 +124,7 @@ index db37cd6..6e73fae 100644 if test "${LOAD_RELATIVE+set}"; then AC_DEFINE_UNQUOTED(LOAD_RELATIVE, $LOAD_RELATIVE) -@@ -4098,6 +4101,7 @@ AC_SUBST(sitearchincludedir)dnl +@@ -4099,6 +4102,7 @@ AC_SUBST(sitearchincludedir)dnl AC_SUBST(arch)dnl AC_SUBST(sitearch)dnl AC_SUBST(ruby_version)dnl diff --git a/ruby.spec b/ruby.spec index a014a63..669fb0b 100644 --- a/ruby.spec +++ b/ruby.spec @@ -10,7 +10,7 @@ #%%global milestone rc1 # Keep the revision enabled for pre-releases from SVN. -%global revision 50427 +%global revision 50815 %global ruby_archive %{name}-%{ruby_version} @@ -37,12 +37,13 @@ %global bigdecimal_version 1.2.7 %global io_console_version 0.4.3 %global json_version 1.8.2 -%global minitest_version 5.4.3 -%global power_assert_version 0.2.2 +%global minitest_version 5.7.0 +%global power_assert_version 0.2.3 %global psych_version 2.0.13 %global rake_version 10.4.2 %global rdoc_version 4.2.0 -%global test_unit_version 3.0.9 +%global net_telnet_version 0.1.1 +%global test_unit_version 3.1.1 # Might not be needed in the future, if we are lucky enough. # https://bugzilla.redhat.com/show_bug.cgi?id=888262 @@ -111,6 +112,9 @@ Patch5: ruby-1.9.3-mkmf-verbose.patch # in support for ABRT. # http://bugs.ruby-lang.org/issues/8566 Patch6: ruby-2.1.0-Allow-to-specify-additional-preludes-by-configuratio.patch +# Fix require paths for BigDecimal and io-console. +# https://bugs.ruby-lang.org/issues/11249 +Patch7: ruby-2.3.0-Fix-require-paths-for-BigDecimal-and-io-console.patch Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: ruby(rubygems) >= %{rubygems_version} @@ -334,8 +338,6 @@ minitest/pride shows pride in testing and adds coloring to your test output. -# The Summary/Description fields are rather poor. -# https://github.com/k-tsj/power_assert/issues/3 %package -n rubygem-power_assert Summary: Power Assert for Ruby Version: %{power_assert_version} @@ -347,7 +349,9 @@ Provides: rubygem(power_assert) = %{version}-%{release} BuildArch: noarch %description -n rubygem-power_assert -Power Assert for Ruby. +Power Assert shows each value of variables and method calls in the expression. +It is useful for testing, providing which value wasn't correct when the +condition is not satisfied. %package -n rubygem-psych @@ -366,6 +370,25 @@ capabilities. In addition to wrapping libyaml, Psych also knows how to serialize and de-serialize most Ruby objects to and from the YAML format. +%package -n rubygem-net-telnet +Summary: Provides telnet client functionality +Version: %{net_telnet_version} +Group: Development/Libraries +Requires: ruby(release) +Requires: ruby(rubygems) >= %{rubygems_version} +Provides: rubygem(net-telnet) = %{version}-%{release} + +%description -n rubygem-net-telnet +Provides telnet client functionality. + +This class also has, through delegation, all the methods of a socket object +(by default, a TCPSocket, but can be set by the Proxy option to new()). This +provides methods such as close() to end the session and sysread() to read data +directly from the host, instead of via the waitfor() mechanism. Note that if +you do use sysread() directly when in telnet mode, you should probably pass +the output through preprocess() to extract telnet command sequences. + + # The Summary/Description fields are rather poor. # https://github.com/test-unit/test-unit/issues/73 %package -n rubygem-test-unit @@ -410,6 +433,7 @@ rm -rf ext/fiddle/libffi* %patch4 -p1 %patch5 -p1 %patch6 -p1 +%patch7 -p1 # Provide an example of usage of the tapset: cp -a %{SOURCE3} . @@ -544,29 +568,10 @@ ln -s %{_libdir}/gems/%{name}/psych-%{psych_version}/psych.so %{buildroot}%{ruby # Adjust the gemspec files so that the gems will load properly sed -i '/^end$/ i\ - s.require_paths = ["lib"]' %{buildroot}%{gem_dir}/specifications/rdoc-%{rdoc_version}.gemspec - -sed -i '/^end$/ i\ - s.require_paths = ["lib"]\ - s.extensions = ["bigdecimal.so"]' %{buildroot}%{gem_dir}/specifications/bigdecimal-%{bigdecimal_version}.gemspec - -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 '/^end$/ i\ - s.require_paths = ["lib"]\ s.extensions = ["json/ext/parser.so", "json/ext/generator.so"]' %{buildroot}%{gem_dir}/specifications/json-%{json_version}.gemspec -# Push the .gemspecs through the RubyGems to let them write the stub headers. -# This speeds up loading of libraries and avoids warnings in Spring: -# https://github.com/rubygems/rubygems/pull/694 -for s in rdoc-%{rdoc_version}.gemspec json-%{json_version}.gemspec; do - s="%{buildroot}%{gem_dir}/specifications/$s" - make runruby TESTRUN_SCRIPT="-rubygems \ - -e \"spec = Gem::Specification.load(%{$s})\" \ - -e \"File.write %{$s}, spec.to_ruby\"" -done +# Move man pages into proper location +mv %{buildroot}%{gem_dir}/gems/rake-%{rake_version}/doc/rake.1 %{buildroot}%{_mandir}/man1 # Install a tapset and fix up the path to the library. mkdir -p %{buildroot}%{tapset_dir} @@ -861,6 +866,11 @@ make check TESTS="-v $DISABLE_TESTS" %{gem_dir}/gems/psych-%{psych_version} %{gem_dir}/specifications/psych-%{psych_version}.gemspec +%files -n rubygem-net-telnet +%{gem_dir}/gems/net-telnet-%{net_telnet_version} +%exclude %{gem_dir}/gems/net-telnet-%{net_telnet_version}/.* +%{gem_dir}/specifications/net-telnet-%{net_telnet_version}.gemspec + %files -n rubygem-test-unit %{gem_dir}/gems/test-unit-%{test_unit_version} %{gem_dir}/specifications/test-unit-%{test_unit_version}.gemspec @@ -875,11 +885,12 @@ make check TESTS="-v $DISABLE_TESTS" %{ruby_libdir}/tkextlib %changelog -* Tue May 05 2015 Vít Ondruch - 2.3.0-0.5.r50427 -- Upgrade to Ruby 2.3.0 (r50427). +* Tue May 05 2015 Vít Ondruch - 2.3.0-0.5.r50815 +- Upgrade to Ruby 2.3.0 (r50815). - Initialize all load paths in operating_system.rb. - Fix directory ownership. - Fix the git BR following the git package split. +- Move gemified net-telnet into subpackage. * Tue Feb 03 2015 Vít Ondruch - 2.2.0-5 - Make operating_system.rb more robust.