69 lines
1.6 KiB
RPMSpec
69 lines
1.6 KiB
RPMSpec
|
|
%global gem_name crack
|
||
|
|
|
||
|
|
Summary: Really simple JSON and XML parsing, ripped from Merb and Rails
|
||
|
|
Name: rubygem-%{gem_name}
|
||
|
|
Version: 0.4.2
|
||
|
|
Release: 1
|
||
|
|
License: MIT
|
||
|
|
URL: http://github.com/jnunemaker/crack
|
||
|
|
Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||
|
|
# ruby package has just soft dependency on rubygem(bigdecimal), while
|
||
|
|
# crack always requires it.
|
||
|
|
Requires: rubygem(bigdecimal)
|
||
|
|
BuildRequires: rubygems-devel rubygem(bigdecimal) rubygem(minitest) rubygem(safe_yaml)
|
||
|
|
BuildArch: noarch
|
||
|
|
#BZ 781829
|
||
|
|
Epoch: 1
|
||
|
|
|
||
|
|
%description
|
||
|
|
Really simple JSON and XML parsing, ripped from Merb and Rails.
|
||
|
|
|
||
|
|
%package doc
|
||
|
|
Summary: Documentation for %{name}
|
||
|
|
|
||
|
|
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||
|
|
|
||
|
|
%description doc
|
||
|
|
This package contains documentation for %{name}.
|
||
|
|
|
||
|
|
%prep
|
||
|
|
%setup -q -c -T
|
||
|
|
%gem_install -n %{SOURCE0}
|
||
|
|
|
||
|
|
%build
|
||
|
|
|
||
|
|
%install
|
||
|
|
mkdir -p %{buildroot}%{gem_dir}
|
||
|
|
cp -a .%{gem_dir}/* \
|
||
|
|
%{buildroot}%{gem_dir}/
|
||
|
|
|
||
|
|
# Fix non-standard-executable-perm rpmlint warning.
|
||
|
|
chmod a+x %{buildroot}%{gem_instdir}/script/*
|
||
|
|
|
||
|
|
|
||
|
|
%check
|
||
|
|
pushd .%{gem_instdir}
|
||
|
|
ruby -Ilib:test -e 'Dir.glob "./test/**/*_test.rb", &method(:require)'
|
||
|
|
popd
|
||
|
|
|
||
|
|
%files
|
||
|
|
%dir %{gem_instdir}
|
||
|
|
%exclude %{gem_instdir}/.*
|
||
|
|
%doc %{gem_instdir}/LICENSE
|
||
|
|
%doc %{gem_instdir}/README.md
|
||
|
|
%doc %{gem_instdir}/History
|
||
|
|
%{gem_libdir}
|
||
|
|
%exclude %{gem_cache}
|
||
|
|
%{gem_spec}
|
||
|
|
|
||
|
|
%files doc
|
||
|
|
%doc %{gem_docdir}
|
||
|
|
%{gem_instdir}/Gemfile
|
||
|
|
%{gem_instdir}/crack.gemspec
|
||
|
|
%{gem_instdir}/script
|
||
|
|
%{gem_instdir}/test
|
||
|
|
|
||
|
|
%changelog
|
||
|
|
* Mon Jul 27 2020 wangxiao <wangxiao65@huawei.com> - 0.4.2-1
|
||
|
|
- package init
|