65 lines
1.5 KiB
RPMSpec
65 lines
1.5 KiB
RPMSpec
|
|
%global gem_name faraday
|
||
|
|
Name: rubygem-%{gem_name}
|
||
|
|
Version: 0.9.0
|
||
|
|
Release: 1
|
||
|
|
Summary: HTTP/REST API client library
|
||
|
|
License: MIT
|
||
|
|
URL: https://github.com/lostisland/faraday
|
||
|
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||
|
|
BuildRequires: ruby(release) rubygem(multipart-post) => 1.2 rubygem(multipart-post) < 3
|
||
|
|
BuildRequires: rubygems-devel ruby
|
||
|
|
BuildArch: noarch
|
||
|
|
%global __requires_exclude ^/usr/bin/env$
|
||
|
|
%description
|
||
|
|
HTTP/REST API client library
|
||
|
|
|
||
|
|
%package doc
|
||
|
|
Summary: Documentation for %{name}
|
||
|
|
Requires: %{name} = %{version}-%{release}
|
||
|
|
BuildArch: noarch
|
||
|
|
%description doc
|
||
|
|
Documentation for %{name}
|
||
|
|
|
||
|
|
%prep
|
||
|
|
gem unpack %{SOURCE0}
|
||
|
|
%setup -q -D -T -n %{gem_name}-%{version}
|
||
|
|
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
|
||
|
|
|
||
|
|
%build
|
||
|
|
gem build %{gem_name}.gemspec
|
||
|
|
%gem_install
|
||
|
|
pushd .%{gem_instdir}/
|
||
|
|
rm %{gem_name}.gemspec
|
||
|
|
rm Gemfile
|
||
|
|
rm Rakefile
|
||
|
|
rm .document
|
||
|
|
popd
|
||
|
|
|
||
|
|
%install
|
||
|
|
mkdir -p %{buildroot}%{gem_dir}
|
||
|
|
cp -pa .%{gem_dir}/* \
|
||
|
|
%{buildroot}%{gem_dir}/
|
||
|
|
|
||
|
|
%check
|
||
|
|
pushd .%{gem_instdir}
|
||
|
|
popd
|
||
|
|
|
||
|
|
%files
|
||
|
|
%dir %{gem_instdir}
|
||
|
|
%{gem_libdir}
|
||
|
|
%{gem_spec}
|
||
|
|
%doc %{gem_instdir}/LICENSE.md
|
||
|
|
%doc %{gem_instdir}/README.md
|
||
|
|
%exclude %{gem_cache}
|
||
|
|
|
||
|
|
%files doc
|
||
|
|
%doc %{gem_docdir}
|
||
|
|
%{gem_instdir}/CHANGELOG.md
|
||
|
|
%{gem_instdir}/CONTRIBUTING.md
|
||
|
|
%{gem_instdir}/script
|
||
|
|
%{gem_instdir}/test
|
||
|
|
|
||
|
|
%changelog
|
||
|
|
* Sat Jul 25 2020 wutao <wutao61@huawei.com> - 0.9.0-1
|
||
|
|
- package init
|