Stephan Kulow 2014-01-18 13:27:55 +00:00 committed by Git OBS Bridge
parent d6f874fb71
commit 7feb62e6c8
2 changed files with 34 additions and 20 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sat Jan 18 13:21:12 UTC 2014 - coolo@suse.com
- use new ruby macros
-------------------------------------------------------------------
Sat Jul 14 19:01:06 UTC 2012 - chris@computersalat.de

View File

@ -1,7 +1,7 @@
#
# spec file for package rubygem-hpricot
#
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -15,23 +15,22 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: rubygem-hpricot
Version: 0.8.6
Release: 0
%define mod_name hpricot
%define mod_full_name %{mod_name}-%{version}
#
Group: Development/Languages/Ruby
License: MIT
#
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: rubygems_with_buildroot_patch
%rubygems_requires
#
BuildRequires: ruby-macros >= 3
BuildRequires: rubygem(rdoc) > 3.10
Url: http://code.whytheluckystiff.net/hpricot/
Source: %{mod_full_name}.gem
#
Source: http://rubygems.org/gems/%{mod_full_name}.gem
Summary: A swift, liberal HTML parser with a fantastic library
License: MIT
Group: Development/Languages/Ruby
%description
a swift, liberal HTML parser with a fantastic library
@ -39,6 +38,7 @@ a swift, liberal HTML parser with a fantastic library
Summary: RDoc documentation for %{mod_name}
Group: Development/Languages/Ruby
Requires: %{name} = %{version}
%description doc
Documentation generated at gem installation time.
Usually in RDoc and RI formats.
@ -47,31 +47,40 @@ Usually in RDoc and RI formats.
Summary: Test suite for %{mod_name}
Group: Development/Languages/Ruby
Requires: %{name} = %{version}
%description testsuite
Test::Unit or RSpec files, useful for developers.
%prep
#gem_unpack
#if you need patches, apply them here and replace the # with a % sign in the surrounding lines
#gem_build
%build
%install
%gem_install %{S:0}
%gem_install -f
%gem_cleanup
### rpmlint stuff
# wrong-script-end-of-line-encoding
%{__perl} -p -i -e 's|\r\n|\n|' %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_name}-%{version}/test/nokogiri-bench.rb
mkdir -p %{buildroot}%{_docdir}/%{name}
ln -s %{gem_base}/gems/%{mod_full_name}/CHANGELOG %buildroot/%{_docdir}/%{name}/CHANGELOG
ln -s %{gem_base}/gems/%{mod_full_name}/COPYING %buildroot/%{_docdir}/%{name}/COPYING
ln -s %{gem_base}/gems/%{mod_full_name}/README.md %buildroot/%{_docdir}/%{name}/README.md
%files
%defattr(-,root,root,-)
%{_libdir}/ruby/gems/%{rb_ver}/cache/%{mod_full_name}.gem
%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/
%exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/test
%{_libdir}/ruby/gems/%{rb_ver}/specifications/%{mod_full_name}.gemspec
%{_docdir}/%{name}
%{gem_base}/cache/%{mod_full_name}.gem
%{gem_base}/gems/%{mod_full_name}/
%{gem_extensions}/%{mod_full_name}
%exclude %{gem_base}/gems/%{mod_full_name}/test
%{gem_base}/specifications/%{mod_full_name}.gemspec
%files doc
%defattr(-,root,root,-)
%doc %{_libdir}/ruby/gems/%{rb_ver}/doc/%{mod_full_name}/
%doc %{gem_base}/doc
%files testsuite
%defattr(-,root,root,-)
%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/test
%{gem_base}/gems/%{mod_full_name}/test
%changelog