Blame SPECS/rubygem-hike.spec

9bc22f
%{!?scl:%global pkg_name %{name}}
9bc22f
%{?scl:%scl_package rubygem-%{gem_name}}
9bc22f
9bc22f
# Generated from hike-1.1.0.gem by gem2rpm -*- rpm-spec -*-
9bc22f
%global gem_name hike
9bc22f
9bc22f
Summary: Find files in a set of paths
9bc22f
Name: %{?scl_prefix}rubygem-%{gem_name}
9bc22f
Version: 1.2.3
9bc22f
Release: 1%{?dist}
9bc22f
Group: Development/Languages
9bc22f
License: MIT
9bc22f
URL: http://github.com/sstephenson/hike
9bc22f
Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
9bc22f
# git clone https://github.com/sstephenson/hike.git && cd hike && git checkout v1.2.3
9bc22f
# tar czvf hike-1.2.3-tests.tgz test/
9bc22f
Source1: %{gem_name}-%{version}-tests.tgz
9bc22f
Requires: %{?scl_prefix_ruby}ruby(release)
9bc22f
Requires: %{?scl_prefix_ruby}ruby(rubygems)
9bc22f
Requires: %{?scl_prefix_ruby}ruby
9bc22f
BuildRequires: %{?scl_prefix_ruby}ruby(release)
9bc22f
BuildRequires: %{?scl_prefix_ruby}rubygems-devel
9bc22f
BuildRequires: %{?scl_prefix_ruby}ruby
9bc22f
BuildRequires: %{?scl_prefix_ruby}rubygem(minitest)
9bc22f
BuildArch: noarch
9bc22f
Provides: %{?scl_prefix}rubygem(%{gem_name}) = %{version}
9bc22f
9bc22f
%description
9bc22f
A Ruby library for finding files in a set of paths.
9bc22f
9bc22f
9bc22f
%package doc
9bc22f
Summary: Documentation for %{pkg_name}
9bc22f
Group: Documentation
9bc22f
Requires: %{?scl_prefix}%{pkg_name} = %{version}-%{release}
9bc22f
BuildArch: noarch
9bc22f
9bc22f
%description doc
9bc22f
Documentation for %{pkg_name}
9bc22f
9bc22f
9bc22f
%prep
9bc22f
%setup -q -c -T
9bc22f
mkdir -p .%{gem_dir}
9bc22f
%{?scl:scl enable %scl - << \EOF}
9bc22f
%gem_install -n %{SOURCE0}
9bc22f
%{?scl:EOF}
9bc22f
9bc22f
%build
9bc22f
9bc22f
%install
9bc22f
mkdir -p %{buildroot}%{gem_dir}
9bc22f
cp -a .%{gem_dir}/* \
9bc22f
        %{buildroot}%{gem_dir}/
9bc22f
9bc22f
%check
9bc22f
pushd .%{gem_instdir}
9bc22f
tar xzf %{SOURCE1}
9bc22f
%{?scl:scl enable %scl - << \EOF}
9bc22f
# To run the tests using minitest 5
9bc22f
ruby -rminitest/autorun -Ilib:test - << \RUBY
9bc22f
  module Kernel
9bc22f
    alias orig_require require
9bc22f
    remove_method :require
9bc22f
9bc22f
    def require path
9bc22f
      orig_require path unless path == 'test/unit'
9bc22f
    end
9bc22f
9bc22f
  end
9bc22f
9bc22f
  Test = Minitest
9bc22f
9bc22f
  Dir.glob "./test/test_*.rb", &method(:require)
9bc22f
RUBY
9bc22f
%{?scl:EOF}
9bc22f
popd
9bc22f
9bc22f
9bc22f
%files
9bc22f
%dir %{gem_instdir}
9bc22f
%doc %{gem_instdir}/LICENSE
9bc22f
%{gem_libdir}
9bc22f
%exclude %{gem_cache}
9bc22f
%{gem_spec}
9bc22f
9bc22f
%files doc
9bc22f
%doc %{gem_instdir}/README.md
9bc22f
%doc %{gem_docdir}
9bc22f
9bc22f
9bc22f
%changelog
9bc22f
* Mon Jan 26 2015 Josef Stribny <jstribny@redhat.com> - 1.2.3-1
9bc22f
- Update to 1.2.3
9bc22f
9bc22f
* Fri Mar 21 2014 Vít Ondruch <vondruch@redhat.com> - 1.2.1-5
9bc22f
- Rebuid against new scl-utils to depend on -runtime package.
9bc22f
  Resolves: rhbz#1069109
9bc22f
9bc22f
* Wed Jun 12 2013 Josef Stribny <jstribny@redhat.com> - 1.2.1-4
9bc22f
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0
9bc22f
9bc22f
* Wed Jul 25 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.2.1-3
9bc22f
- Specfile cleanup
9bc22f
9bc22f
* Mon Apr 02 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.2.1-2
9bc22f
- Rebuilt for scl.
9bc22f
9bc22f
* Mon Jan 30 2012 Vít Ondruch <vondruch@redhat.com> - 1.2.1-1
9bc22f
- Update to Hike 1.2.1.
9bc22f
9bc22f
* Wed Jun 29 2011 Vít Ondruch <vondruch@redhat.com> - 1.1.0-1
9bc22f
- Initial package