commit
3264f3a896
82
rubygem-sinatra.spec
Normal file
82
rubygem-sinatra.spec
Normal file
@ -0,0 +1,82 @@
|
||||
%global gem_name sinatra
|
||||
%{?_with_bootstrap: %global bootstrap 1}
|
||||
Summary: Ruby-based web application framework
|
||||
Name: rubygem-%{gem_name}
|
||||
Version: 2.0.3
|
||||
Release: 1
|
||||
License: MIT
|
||||
URL: http://www.sinatrarb.com/
|
||||
Source0: https://rubygems.org/gems/sinatra-%{version}.gem
|
||||
Source1: https://github.com/sinatra/sinatra/archive/v%{version}.tar.gz
|
||||
BuildRequires: rubygems-devel
|
||||
%if ! 0%{?bootstrap}
|
||||
BuildRequires: rubygem(rack) >= 2.0 rubygem(rack-protection) = %{version} rubygem(tilt)
|
||||
BuildRequires: rubygem(mustermann) rubygem(rack-test) rubygem(minitest) > 5
|
||||
%endif
|
||||
Epoch: 1
|
||||
BuildArch: noarch
|
||||
%description
|
||||
Sinatra is a DSL intended for quickly creating web-applications in Ruby
|
||||
with minimal effort.
|
||||
|
||||
%package help
|
||||
Summary: Documentation for %{name}
|
||||
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||||
Provides: %{name}-doc = %{version}-%{release}
|
||||
Obsoletes: %{name}-doc < %{version}-%{release}
|
||||
%description help
|
||||
This package contains 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
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{gem_dir}
|
||||
cp -rv .%{gem_dir}/* %{buildroot}%{gem_dir}
|
||||
sed -i -e 's|^#!/usr/bin/env ruby|#!/usr/bin/ruby|' \
|
||||
%{buildroot}%{gem_instdir}/examples/*.rb
|
||||
|
||||
%check
|
||||
%if ! 0%{?bootstrap}
|
||||
pushd .%{gem_instdir}
|
||||
tar xzvf %{SOURCE1}
|
||||
cd %{gem_name}-%{version}
|
||||
for FILE in $(grep -rl '^require.*bundler.*' test/); do
|
||||
sed -i "/^require 'bundler.*'/ s/^/#/" ${FILE}
|
||||
done
|
||||
mv test/integration_test.rb{,.disabled}
|
||||
ruby -e 'Dir.glob "./test/*_test.rb", &method(:require)'
|
||||
popd
|
||||
%endif
|
||||
|
||||
%files
|
||||
%dir %{gem_instdir}
|
||||
%exclude %{gem_instdir}/.*
|
||||
%license %{gem_instdir}/LICENSE
|
||||
%{gem_libdir}
|
||||
%exclude %{gem_instdir}/sinatra.gemspec
|
||||
%exclude %{gem_cache}
|
||||
%{gem_spec}
|
||||
|
||||
%files help
|
||||
%doc %{gem_docdir}
|
||||
%doc %{gem_instdir}/AUTHORS.md
|
||||
%doc %{gem_instdir}/CHANGELOG.md
|
||||
%doc %{gem_instdir}/CONTRIBUTING.md
|
||||
%{gem_instdir}/Gemfile
|
||||
%doc %{gem_instdir}/MAINTENANCE.md
|
||||
%doc %{gem_instdir}/README*.md
|
||||
%{gem_instdir}/Rakefile
|
||||
%doc %{gem_instdir}/SECURITY.md
|
||||
%{gem_instdir}/VERSION
|
||||
%{gem_instdir}/examples
|
||||
|
||||
%changelog
|
||||
* Sat Aug 22 2020 liyanan <liyanan32@huawei.com> - 2.0.3-1
|
||||
- package init
|
||||
5
rubygem-sinatra.yaml
Normal file
5
rubygem-sinatra.yaml
Normal file
@ -0,0 +1,5 @@
|
||||
git_url: https://github.com/sinatra/sinatra.git
|
||||
version_control: github
|
||||
src_repo: sinatra/sinatra
|
||||
tag_prefix: "^v"
|
||||
seperator: "."
|
||||
BIN
sinatra-2.0.3.gem
Normal file
BIN
sinatra-2.0.3.gem
Normal file
Binary file not shown.
BIN
v2.0.3.tar.gz
Normal file
BIN
v2.0.3.tar.gz
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user