diff --git a/rack-2.0.4.gem b/rack-2.0.4.gem deleted file mode 100644 index 6f947734f2ba06ae5792d8e7bcb4139c46a9b680..0000000000000000000000000000000000000000 Binary files a/rack-2.0.4.gem and /dev/null differ diff --git a/rack-2.0.6.gem b/rack-2.0.6.gem new file mode 100644 index 0000000000000000000000000000000000000000..b40363bac1a6053aa73c14c4a3944dce4e1cc77e Binary files /dev/null and b/rack-2.0.6.gem differ diff --git a/rubygem-rack.spec b/rubygem-rack.spec index ea5c984507658b4e92ec2e7524c2976b32072d53..c1835478cd31515f1aceb8cc81beb41cc80b9b22 100644 --- a/rubygem-rack.spec +++ b/rubygem-rack.spec @@ -1,79 +1,89 @@ %global gem_name rack -Name: rubygem-rack -Version: 2.0.4 -Epoch: 1 -Release: 1 -Summary: A modular Ruby webserver interface -License: MIT and BSD -URL: https://github.com/rack/rack -Source0: https://github.com/rack/rack/archive/rack-%{version}.gem - -BuildRequires: rubygems-devel ruby -BuildArch: noarch - +%{?_with_bootstrap: %global bootstrap 1} +Name: rubygem-%{gem_name} +Version: 2.0.6 +Epoch: 1 +Release: 1 +Summary: A modular Ruby webserver interface +License: MIT and BSD +URL: https://rack.github.io/ +Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem +BuildRequires: ruby(release) rubygems-devel ruby >= 2.2.2 rubygem(concurrent-ruby) memcached +BuildRequires: rubygem(memcache-client) rubygem(minitest) +%if ! 0%{?bootstrap} +BuildRequires: rubygem(thin) +%endif +BuildArch: noarch +%global __brp_mangle_shebangs_exclude_from ^%{gem_instdir}/test/cgi/test.ru$ %description -Rack provides a minimal, modular, and adaptable interface for developing -web applications in Ruby. By wrapping HTTP requests and responses in the -simplest way possible, it unifies and distills the API for web servers, -web frameworks, and software in between (the so-called middleware) into -a single method call. - -%package help -Summary: Documents for %{name} -Buildarch: noarch -Requires: man info %{name} = %{epoch}:%{version}-%{release} -Provides: %{name}-doc = %{epoch}:%{version}-%{release} -Obsoletes: %{name}-doc < %{epoch}:%{version}-%{release} +Rack provides a minimal, modular and adaptable interface for developing +web applications in Ruby. By wrapping HTTP requests and responses in +the simplest way possible, it unifies and distills the API for web +servers, web frameworks, and software in between (the so-called +middleware) into a single method call. -%description help -Man pages and other related documents for %{name}. +%package doc +Summary: Documentation for %{name} +Requires: %{name} = %{epoch}:%{version}-%{release} +BuildArch: noarch +%description doc +Documentation for %{name}. %prep -%setup -q -c -T -%gem_install -n %{SOURCE0} +%setup -q -n %{gem_name}-%{version} %build +gem build ../%{gem_name}-%{version}.gemspec +%gem_install %install -install -d 0755 %{buildroot}%{gem_dir} -cp -a .%{gem_dir}/* %{buildroot}%{gem_dir}/ -install -d 0755 %{buildroot}%{_bindir} -cp -pa .%{_bindir}/* %{buildroot}%{_bindir}/ - +mkdir -p %{buildroot}%{gem_dir} +cp -a .%{gem_dir}/* \ + %{buildroot}%{gem_dir}/ +mkdir -p %{buildroot}%{_bindir} +cp -a .%{_bindir}/* \ + %{buildroot}%{_bindir}/ find %{buildroot}%{gem_instdir}/bin -type f | xargs chmod a+x find %{buildroot}%{gem_instdir}/{bin,test/cgi} -type f | \ -xargs sed -i 's|^#!/usr/bin/env ruby$|#!/usr/bin/ruby|' - + xargs sed -i 's|^#!/usr/bin/env ruby$|#!/usr/bin/ruby|' for file in `find %{buildroot}/%{gem_instdir} -type f -perm /a+x`; do -[ -z "`head -n 1 $file | grep \"^#!/\"`" ] && chmod -v 644 $file + [ -z "`head -n 1 $file | grep \"^#!/\"`" ] && chmod -v 644 $file done - for file in `find %{buildroot}%{gem_instdir} -type f`; do -[ ! -z "`head -n 1 $file | grep \"^#!\"`" ] && chmod -v 755 $file + [ ! -z "`head -n 1 $file | grep \"^#!\"`" ] && chmod -v 755 $file done +%check +pushd .%{gem_instdir} +sed -i '/^ it "check pid file presence and not owned process" do$/,/^ end$/ s/^/#/' \ + test/spec_server.rb +PID=%(mktemp) +memcached -d -P "$PID" +LC_ALL=C.UTF-8 \ +ruby -Ilib:test -e 'Dir.glob "./test/spec_*.rb", &method(:require)' +kill -TERM $(< "$PID") +popd + %files -%defattr(-,root,root) -%license %{gem_instdir}/COPYING -%{_bindir}/rackup %dir %{gem_instdir} +%{_bindir}/rackup +%license %{gem_instdir}/COPYING %{gem_libdir} %{gem_instdir}/bin -%{gem_spec} %exclude %{gem_cache} +%{gem_spec} -%files help -%defattr(-,root,root) +%files doc %doc %{gem_docdir} -%doc %{gem_instdir}/example -%doc %{gem_instdir}/contrib %doc %{gem_instdir}/HISTORY.md %doc %{gem_instdir}/README.rdoc -%{gem_instdir}/SPEC -%{gem_instdir}/test %{gem_instdir}/Rakefile +%{gem_instdir}/SPEC %{gem_instdir}/%{gem_name}.gemspec +%doc %{gem_instdir}/example +%{gem_instdir}/test +%doc %{gem_instdir}/contrib %changelog -* Thu Mar 5 2020 openEuler Buildteam - 1:2.0.4-1 -- Package init +* Thu Aug 20 2020 luoshengwei - 2.0.6-1 +- package init diff --git a/rubygem-rack.yaml b/rubygem-rack.yaml index 666da997903436717c8fb92dba96ee1689f4699f..ee1416c4a12acae326927093792326a3abccc17f 100644 --- a/rubygem-rack.yaml +++ b/rubygem-rack.yaml @@ -1,4 +1,4 @@ version_control: github src_repo: rack/rack -tag_prefix: ^v -seperator: . +tag_prefix: "rack-" +separator: "."