[remctl/el5: 2/2] Adjust for new Ruby on Fedora 19

Ken Dreyer ktdreyer at fedoraproject.org
Wed Mar 20 18:54:59 UTC 2013


commit 60efdc45ac5072c200cfe041ca4fc17c872b5014
Author: Ken Dreyer <ktdreyer at ktdreyer.com>
Date:   Wed Mar 13 13:58:06 2013 -0600

    Adjust for new Ruby on Fedora 19
    
    - Adjust RPM conditionals
    - Work around broken Ruby 2.0 "make install" bug

 remctl.spec |   25 +++++++++++++++++++------
 1 files changed, 19 insertions(+), 6 deletions(-)
---
diff --git a/remctl.spec b/remctl.spec
index ca144bd..34789e5 100644
--- a/remctl.spec
+++ b/remctl.spec
@@ -1,6 +1,6 @@
 Name: remctl
 Version: 3.3
-Release: 2%{?dist}
+Release: 3%{?dist}
 Summary: Client/server for Kerberos-authenticated command execution
 
 Group: Applications/Internet
@@ -18,6 +18,9 @@ BuildRequires: python2-devel
 BuildRequires: ruby
 BuildRequires: ruby(abi) = 1.8
 %endif
+%if 0%{?fedora} >= 19
+BuildRequires: ruby(release)
+%endif
 BuildRequires: ruby-devel
 
 # RHEL 5/6 compatibility for PHP
@@ -107,10 +110,12 @@ remctl's Python bindings, you need to install this package.
 Summary: Ruby interface to remctl
 Group: Development/Libraries
 Requires: %{name} = %{version}-%{release}
-%if 0%{?rhel} && 0%{?rhel} <= 6
-Requires: ruby(abi) = 1.8
-%else
-Requires: ruby(abi) = 1.9.1
+%{?el5:Requires:  ruby(abi) = 1.8}
+%{?el6:Requires:  ruby(abi) = 1.8}
+%{?fc17:Requires: ruby(abi) = 1.9.1}
+%{?fc18:Requires: ruby(abi) = 1.9.1}
+%if 0%{?fedora} >= 19
+Requires: ruby(release)
 %endif
 Provides: ruby(remctl) = %{version}-%{release}
 
@@ -139,10 +144,14 @@ make
 
 %install
 rm -rf %{buildroot}
+# On Fedora 19, Ruby 2.0 has broken headers.
+# https://bugzilla.redhat.com/921650
+# We have to pass an empty "ruby_headers=" setting to "make install".
 make install \
 	DESTDIR=%{buildroot} \
 	INSTALL="install -p" \
-	RUBYARCHDIR="%{buildroot}%{ruby_vendorarchdir}"
+	RUBYARCHDIR="%{buildroot}%{ruby_vendorarchdir}" \
+	ruby_headers=
 
 chmod 0755 %{buildroot}%{perl_vendorarch}/auto/Net/Remctl/Remctl.so
 chmod 0644 %{buildroot}%{perl_vendorarch}/Net/Remctl.pm
@@ -208,6 +217,10 @@ rm -rf %{buildroot}
 
 
 %changelog
+* Wed Mar 13 2013 Ken Dreyer <ktdreyer at ktdreyer.com> - 3.3-2
+- Adjust RPM conditionals for new Ruby guidelines on Fedora 19
+- Add workaround for Ruby 2.0 "make install" bug (#921650)
+
 * Thu Feb 14 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.3-2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
 


More information about the scm-commits mailing list