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.2.2.gem b/rack-2.2.2.gem new file mode 100644 index 0000000000000000000000000000000000000000..82d4c7e4a49bde5439749e96691bd570060b84cb Binary files /dev/null and b/rack-2.2.2.gem differ diff --git a/rubygem-rack.spec b/rubygem-rack.spec index 973c6ba54d7974613d541381fb031dda74f66fef..d2335ce8e7e24a946b3a0ab6d1794a8763722942 100644 --- a/rubygem-rack.spec +++ b/rubygem-rack.spec @@ -1,80 +1,98 @@ %global gem_name rack -Name: rubygem-rack -Version: 2.0.4 -Epoch: 1 -Release: 2 -Summary: A modular Ruby webserver interface -License: MIT and BSD -URL: https://github.com/rack/rack -Source0: https://rubygems.org/downloads/rack-%{version}.gem - -BuildRequires: rubygems-devel ruby -BuildArch: noarch + +Name: rubygem-%{gem_name} +Version: 2.2.2 +Epoch: 1 +Release: 1 +Summary: A modular Ruby webserver interface +License: MIT and BSD +URL: https://rack.github.io/ +Source0: https://rubygems.org/downloads/%{gem_name}-%{version}.gem +BuildRequires: ruby(release) rubygems-devel ruby >= 2.2.2 +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} - -%description help -Man pages and other related documents for %{name}. +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: Documentation for %{name} +Requires: %{name} = %{epoch}:%{version}-%{release} +Provides: %{name}-doc = %{epoch}:%{version}-%{release} +Obsoletes: %{name}-doc < %{epoch}:%{version}-%{release} +BuildArch: noarch + +%description help +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} +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}/MIT-LICENSE %{gem_libdir} %{gem_instdir}/bin -%{gem_spec} %exclude %{gem_cache} +%{gem_spec} -%files help -%defattr(-,root,root) +%files help %doc %{gem_docdir} -%doc %{gem_instdir}/example -%doc %{gem_instdir}/contrib -%doc %{gem_instdir}/HISTORY.md +%doc %{gem_instdir}/CHANGELOG.md %doc %{gem_instdir}/README.rdoc -%{gem_instdir}/SPEC -%{gem_instdir}/test +%doc %{gem_instdir}/CONTRIBUTING.md +%doc %{gem_instdir}/SPEC.rdoc %{gem_instdir}/Rakefile %{gem_instdir}/%{gem_name}.gemspec +%doc %{gem_instdir}/example +%doc %{gem_instdir}/contrib %changelog +* Wed Mar 10 2021 zhanghua - 1:2.2.2-1 +- Upgrade to 2.2.2 + * Wed Sep 9 2020 Ge Wang - 1:2.0.4-2 - Modify Source0 Url