[packages/ruby-mysql] build noarch; package to vendor dirs

glen glen at pld-linux.org
Thu Sep 12 00:21:05 CEST 2013

commit 680479b8191f63aaa8989a61551313aa68d6e779
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Thu Sep 12 01:20:47 2013 +0300

    build noarch; package to vendor dirs

 ruby-mysql.spec | 28 +++++++++++-----------------
 1 file changed, 11 insertions(+), 17 deletions(-)
diff --git a/ruby-mysql.spec b/ruby-mysql.spec
index 0270e66..049aef0 100644
--- a/ruby-mysql.spec
+++ b/ruby-mysql.spec
@@ -2,25 +2,21 @@ Summary:	Pure Ruby MySQL library
 Summary(pl.UTF-8):	Biblioteka MySQL napisana w czystym Rubym
 Name:		ruby-mysql
 Version:	2.9.2
-Release:	1
+Release:	2
 License:	GPL
 Group:		Development/Languages
 Source0:	http://rubygems.org/downloads/%{name}-%{version}.gem
 # Source0-md5:	d0fc9e635a0f343b441ea8c0c30c2eb7
 Patch0:		%{name}-socketpath.patch
 URL:		http://www.tmtm.org/ruby/mysql/
-BuildRequires:	rpmbuild(macros) >= 1.484
-BuildRequires:	ruby >= 1:1.8.6
-BuildRequires:	ruby-modules
-Obsoletes:	ruby-Mysql
+BuildRequires:	rpm-rubyprov
+BuildRequires:	rpmbuild(macros) >= 1.665
 Provides:	ruby-mysql-library
+Obsoletes:	ruby-Mysql
 Conflicts:	mysql-ruby
+BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-# nothing to be placed there. we're not noarch only because of ruby packaging
-%define		_enable_debug_packages	0
 Pure Ruby MySQL library.
@@ -52,21 +48,19 @@ ri documentation for %{name}.
 Dokumentacji w formacie ri dla %{name}.
-%setup -q -c
-%{__tar} xf %{SOURCE0} -O data.tar.gz | %{__tar} xz
-find -newer README.rdoc -o -print | xargs touch --reference %{SOURCE0}
+%setup -q -n %{pkgname}-%{version}
 %patch0 -p1
 rdoc --ri --op ri lib
 rdoc --op rdoc lib
 rm ri/created.rid
+rm ri/cache.ri
-install -d $RPM_BUILD_ROOT{%{ruby_rubylibdir},%{ruby_ridir},%{ruby_rdocdir}}
-cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir}
+install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{ruby_ridir},%{ruby_rdocdir}}
+cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
 cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir}
 cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version}
@@ -76,8 +70,8 @@ rm -rf $RPM_BUILD_ROOT
 %doc README*
 %files rdoc

---- gitweb:


More information about the pld-cvs-commit mailing list