166 lines
4.1 KiB
RPMSpec
166 lines
4.1 KiB
RPMSpec
%global gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
|
|
%global gemname test-unit
|
|
%global geminstdir %{gemdir}/gems/%{gemname}-%{version}
|
|
|
|
%global rubyabi 1.8
|
|
%global ruby19 0
|
|
|
|
%if %{?fedora:0%{fedora} >= 17}%{?rhel:0%{rhel} >= 7}
|
|
%global gemdir %{gem_dir}
|
|
%global gem_name %{gemname}
|
|
%global geminstdir %{gem_instdir}
|
|
%global rubyabi 1.9.1
|
|
%global ruby19 1
|
|
%endif
|
|
|
|
# svn repository
|
|
# http://test-unit.rubyforge.org/svn/trunk/
|
|
|
|
Summary: Improved version of Test::Unit bundled in Ruby 1.8.x
|
|
Name: rubygem-%{gemname}
|
|
Version: 2.4.5
|
|
Release: 3%{?dist}
|
|
Group: Development/Languages
|
|
# lib/test/unit/diff.rb is under GPLv2 or Ruby or Python
|
|
# Other file: GPLv2 or Ruby
|
|
License: (GPLv2 or Ruby) and (GPLv2 or Ruby or Python)
|
|
URL: http://rubyforge.org/projects/test-unit/
|
|
|
|
Source0: http://rubygems.org/gems/%{gemname}-%{version}.gem
|
|
BuildRequires: ruby(abi) = %{rubyabi}
|
|
BuildRequires: rubygems
|
|
%if 0%{?ruby19} > 0
|
|
BuildRequires: rubygems-devel
|
|
%endif
|
|
# For %%check
|
|
#BuildRequires: rubygem(rake)
|
|
#BuildRequires: rubygem(hoe)
|
|
Requires: ruby(abi) = %{rubyabi}
|
|
Requires: rubygems
|
|
|
|
BuildArch: noarch
|
|
Provides: rubygem(%{gemname}) = %{version}-%{release}
|
|
|
|
%description
|
|
Test::Unit 2.x - Improved version of Test::Unit bundled in
|
|
Ruby 1.8.x.
|
|
Ruby 1.9.x bundles minitest not Test::Unit. Test::Unit
|
|
bundled in Ruby 1.8.x had not been improved but unbundled
|
|
Test::Unit (Test::Unit 2.x) will be improved actively.
|
|
|
|
%package doc
|
|
Summary: Documentation for %{name}
|
|
Group: Documentation
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
%description doc
|
|
This package contains documentation for %{name}.
|
|
|
|
%prep
|
|
%setup -q -c -T
|
|
|
|
mkdir -p .%{geminstdir}
|
|
gem install \
|
|
-V \
|
|
--local \
|
|
--install-dir .%{gemdir} \
|
|
--force \
|
|
--rdoc \
|
|
%{SOURCE0}
|
|
|
|
find . -name \*.gem | xargs chmod 0644
|
|
find . -type f | xargs chmod ugo+r
|
|
|
|
%build
|
|
|
|
%install
|
|
mkdir -p %{buildroot}%{gemdir}
|
|
cp -a .%{gemdir}/* \
|
|
%{buildroot}%{gemdir}/
|
|
|
|
# Move bin/ script to standard path
|
|
# The name "testrb" conflicts with ruby 1.8.x, rename it
|
|
mkdir -p %{buildroot}/%{_bindir}
|
|
mv %{buildroot}%{gemdir}/bin/* \
|
|
%{buildroot}/%{_bindir}/
|
|
rmdir %{buildroot}%{gemdir}/bin
|
|
find %{buildroot}%{geminstdir}/bin -type f | xargs chmod 0755
|
|
|
|
## rename!!
|
|
mv %{buildroot}%{_bindir}/testrb{,2}
|
|
|
|
%check
|
|
pushd .%{geminstdir}
|
|
#rake test --trace
|
|
ruby -Ilib ./test/run-test.rb
|
|
popd
|
|
|
|
%files
|
|
%defattr(-,root,root,-)
|
|
%dir %{geminstdir}
|
|
%doc %{geminstdir}/[A-Z]*
|
|
%exclude %{geminstdir}/Rakefile
|
|
|
|
%{_bindir}/testrb2
|
|
%{geminstdir}/bin/
|
|
%{geminstdir}/lib/
|
|
|
|
%{gemdir}/cache/%{gemname}-%{version}.gem
|
|
%{gemdir}/specifications/%{gemname}-%{version}.gemspec
|
|
|
|
%files doc
|
|
%defattr(-,root,root,-)
|
|
%{geminstdir}/Rakefile
|
|
%{geminstdir}/sample/
|
|
%{geminstdir}/test/
|
|
|
|
%{gemdir}/doc/%{gemname}-%{version}/
|
|
|
|
%changelog
|
|
* Tue Apr 03 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 2.4.5-3
|
|
- Fix conditionals for F17 to work for RHEL 7 as well.
|
|
|
|
* Sun Jan 22 2012 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.5-2
|
|
- 2.4.5
|
|
|
|
* Sun Jan 15 2012 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.4-1
|
|
- 2.4.4
|
|
|
|
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.4.3-2
|
|
- F-17: Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
|
|
|
* Sun Dec 18 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.3-1
|
|
- 2.4.3
|
|
|
|
* Sun Nov 27 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.2-1
|
|
- 2.4.2
|
|
|
|
* Wed Nov 16 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.1-1
|
|
- 2.4.1
|
|
|
|
* Mon Sep 19 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.4.0-1
|
|
- 2.4.0
|
|
|
|
* Thu Aug 18 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.3.2-1
|
|
- 2.3.2
|
|
|
|
* Sun Aug 14 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.3.1-1
|
|
- 2.3.1
|
|
|
|
* Sun Apr 24 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.3.0-1
|
|
- 2.3.0
|
|
|
|
* Fri Feb 18 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 2.2.0-1
|
|
- 2.2.0
|
|
|
|
* Mon Feb 14 2011 Mamoru Tasaka <mtasaka@ioa.s.u-tokyo.ac.jp> - 2.1.2-2
|
|
- F-15 mass rebuild
|
|
|
|
* Thu Nov 26 2010 Mamoru Tasaka <mtasaka@ioa.s.u-tokyo.ac.jp> - 2.1.2-1
|
|
- 2.1.2
|
|
|
|
* Sun Sep 19 2010 Mamoru Tasaka <mtasaka@ioa.s.u-tokyo.ac.jp> - 2.1.1-2
|
|
- Fix up license tag
|
|
|
|
* Sat Sep 18 2010 Mamoru Tasaka <mtasaka@ioa.s.u-tokyo.ac.jp> - 2.1.1-1
|
|
- Initial package
|