init package
This commit is contained in:
parent
88d6c5fa13
commit
bea2f1a2de
BIN
rr-1.2.1-tests.tgz
Normal file
BIN
rr-1.2.1-tests.tgz
Normal file
Binary file not shown.
BIN
rr-1.2.1.gem
Normal file
BIN
rr-1.2.1.gem
Normal file
Binary file not shown.
77
rubygem-rr.spec
Normal file
77
rubygem-rr.spec
Normal file
@ -0,0 +1,77 @@
|
|||||||
|
%global gem_name rr
|
||||||
|
|
||||||
|
Name: rubygem-%{gem_name}
|
||||||
|
Version: 1.2.1
|
||||||
|
Release: 1
|
||||||
|
Summary: RR is a test double framework with a terse syntax
|
||||||
|
License: MIT
|
||||||
|
URL: https://rr.github.io/rr
|
||||||
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||||||
|
# git clone https://github.com/rr/rr.git && cd rr
|
||||||
|
# git checkout v1.2.1 && tar czvf rr-1.2.1-tests.tgz test/
|
||||||
|
Source1: %{gem_name}-%{version}-tests.tgz
|
||||||
|
BuildRequires: ruby(release)
|
||||||
|
BuildRequires: rubygems-devel
|
||||||
|
BuildRequires: ruby
|
||||||
|
# The following are for running test suite
|
||||||
|
BuildRequires: rubygem(test-unit)
|
||||||
|
BuildRequires: rubygem(test-unit-rr)
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description
|
||||||
|
RR is a test double framework that features a rich selection of double
|
||||||
|
techniques and a terse syntax.
|
||||||
|
|
||||||
|
%package doc
|
||||||
|
Summary: Documentation for %{name}
|
||||||
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description doc
|
||||||
|
Documentation for %{name}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -n %{gem_name}-%{version}
|
||||||
|
|
||||||
|
%build
|
||||||
|
# Create the gem as gem install only works on a gem file
|
||||||
|
gem build ../%{gem_name}-%{version}.gemspec
|
||||||
|
|
||||||
|
# %%gem_install compiles any C extensions and installs the gem into ./%%gem_dir
|
||||||
|
# by default, so that we can move it into the buildroot in %%install
|
||||||
|
%gem_install
|
||||||
|
|
||||||
|
%install
|
||||||
|
mkdir -p %{buildroot}%{gem_dir}
|
||||||
|
cp -a .%{gem_dir}/* \
|
||||||
|
%{buildroot}%{gem_dir}/
|
||||||
|
|
||||||
|
%check
|
||||||
|
pushd .%{gem_instdir}
|
||||||
|
tar xvzf %{SOURCE1}
|
||||||
|
ruby test/run-test.rb
|
||||||
|
popd
|
||||||
|
|
||||||
|
%files
|
||||||
|
%dir %{gem_instdir}
|
||||||
|
%license %{gem_instdir}/LICENSE
|
||||||
|
%{gem_libdir}
|
||||||
|
%exclude %{gem_cache}
|
||||||
|
%{gem_spec}
|
||||||
|
|
||||||
|
%files doc
|
||||||
|
%doc %{gem_docdir}
|
||||||
|
%{gem_instdir}/Appraisals
|
||||||
|
%{gem_instdir}/CHANGES.md
|
||||||
|
%{gem_instdir}/CREDITS.md
|
||||||
|
%{gem_instdir}/Gemfile
|
||||||
|
%doc %{gem_instdir}/README.md
|
||||||
|
%{gem_instdir}/Rakefile
|
||||||
|
%doc %{gem_instdir}/doc
|
||||||
|
%{gem_instdir}/gemfiles
|
||||||
|
%{gem_instdir}/rr.gemspec
|
||||||
|
%{gem_instdir}/spec
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Thu Mar 3 2022 caodongxia<caodongxia@huawei.com> - 1.2.1-1
|
||||||
|
- Init package
|
||||||
Loading…
x
Reference in New Issue
Block a user