packages: ruby-trollop/ruby-trollop.spec - rel 2 - use gem source - updated...

baggins baggins at pld-linux.org
Tue Mar 2 13:52:15 CET 2010


Author: baggins                      Date: Tue Mar  2 12:52:15 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- rel 2
- use gem source
- updated build process
- added rdoc and ri packages

---- Files affected:
packages/ruby-trollop:
   ruby-trollop.spec (1.3 -> 1.4) 

---- Diffs:

================================================================
Index: packages/ruby-trollop/ruby-trollop.spec
diff -u packages/ruby-trollop/ruby-trollop.spec:1.3 packages/ruby-trollop/ruby-trollop.spec:1.4
--- packages/ruby-trollop/ruby-trollop.spec:1.3	Sun Nov 29 23:31:05 2009
+++ packages/ruby-trollop/ruby-trollop.spec	Tue Mar  2 13:52:10 2010
@@ -1,16 +1,17 @@
 # $Revision$, $Date$
+%define pkgname trollop
 Summary:	Yet another commandline option parsing library
-Name:		ruby-trollop
+Name:		ruby-%{pkgname}
 Version:	1.15
-Release:	1
+Release:	2
 License:	Ruby
-Source0:	http://rubyforge.org/frs/download.php/64572/trollop-%{version}.tgz
-# Source0-md5:	e234198bcea979758a293e129ee7be4e
+Source0:	http://rubygems.org/downloads/%{pkgname}-%{version}.gem
+# Source0-md5:	359347775ff3166eb13ec80363ad67a1
 Group:		Development/Languages
 URL:		http://trollop.rubyforge.org/
-BuildRequires:	rpmbuild(macros) >= 1.277
+BuildRequires:	rpmbuild(macros) >= 1.484
+BuildRequires:	ruby >= 1:1.8.6
 BuildRequires:	ruby-modules
-BuildRequires:	setup.rb
 %{?ruby_mod_ver_requires_eq}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -18,18 +19,49 @@
 Trollop is YAFCLAP --- yet another fine commandline argument
 processing library for Ruby.
 
+%package rdoc
+Summary:	HTML documentation for %{pkgname}
+Summary(pl.UTF-8):	Dokumentacja w formacie HTML dla %{pkgname}
+Group:		Documentation
+Requires:	ruby >= 1:1.8.7-4
+
+%description rdoc
+HTML documentation for %{pkgname}.
+
+%description rdoc -l pl.UTF-8
+Dokumentacja w formacie HTML dla %{pkgname}.
+
+%package ri
+Summary:	ri documentation for %{pkgname}
+Summary(pl.UTF-8):	Dokumentacja w formacie ri dla %{pkgname}
+Group:		Documentation
+Requires:	ruby
+
+%description ri
+ri documentation for %{pkgname}.
+
+%description ri -l pl.UTF-8
+Dokumentacji w formacie ri dla %{pkgname}.
+
 %prep
-%setup -q -n trollop-%{version}
-install %{_datadir}/setup.rb .
+%setup -q -c
+%{__tar} xf %{SOURCE0} -O data.tar.gz | %{__tar} xz
+find -newer README.txt -o -print | xargs touch --reference %{SOURCE0}
 
 %build
-ruby setup.rb config --rbdir=%{ruby_rubylibdir} --sodir=%{ruby_archdir}
-ruby setup.rb setup
+rdoc --ri --op ri lib
+rdoc --op rdoc lib
+# rm -r ri/NOT_THIS_MODULE_RELATED_DIRS
+rm ri/created.rid
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{ruby_rubylibdir}
-ruby setup.rb install --prefix=$RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT{%{ruby_rubylibdir},%{ruby_ridir},%{ruby_rdocdir}}
+
+cp -a lib/* $RPM_BUILD_ROOT%{ruby_rubylibdir}
+cp -a ri/* $RPM_BUILD_ROOT%{ruby_ridir}
+cp -a rdoc $RPM_BUILD_ROOT%{ruby_rdocdir}/%{name}-%{version}
+
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -39,12 +71,26 @@
 %doc *.txt
 %{ruby_rubylibdir}/*.rb
 
+%files rdoc
+%defattr(644,root,root,755)
+%{ruby_rdocdir}/%{name}-%{version}
+
+%files ri
+%defattr(644,root,root,755)
+%{ruby_ridir}/Trollop
+
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
 * %{date} PLD Team <feedback at pld-linux.org>
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.4  2010/03/02 12:52:10  baggins
+- rel 2
+- use gem source
+- updated build process
+- added rdoc and ri packages
+
 Revision 1.3  2009/11/29 22:31:05  wiget
 - updated to 1.15
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/ruby-trollop/ruby-trollop.spec?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list