235411e
# Generated from concurrent-ruby-1.0.0.gem by gem2rpm -*- rpm-spec -*-
235411e
%global gem_name concurrent-ruby
235411e
235411e
Name: rubygem-%{gem_name}
7383c78
Version: 1.0.5
7383c78
Release: 1%{?dist}
235411e
Summary: Modern concurrency tools for Ruby
235411e
Group: Development/Languages
235411e
License: MIT
235411e
URL: http://www.concurrent-ruby.com
235411e
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
80db40f
# git clone https://github.com/ruby-concurrency/concurrent-ruby.git && cd concurrent-ruby
7383c78
# git checkout v1.0.5 && tar czvf concurrent-ruby-1.0.5-specs.tar.gz spec/
235411e
Source1: %{gem_name}-%{version}-specs.tar.gz
7383c78
# Avoid sporadic test failures due to wrong object_id formatting.
7383c78
# https://github.com/ruby-concurrency/concurrent-ruby/pull/651
7383c78
Patch1: concurrent-ruby-1.0.5-fix-inspect-output.patch
235411e
BuildRequires: ruby(release)
235411e
BuildRequires: rubygems-devel
235411e
BuildRequires: ruby >= 1.9.3
235411e
BuildRequires: rubygem(rspec)
235411e
BuildRequires: rubygem(timecop)
235411e
BuildArch: noarch
235411e
235411e
%description
235411e
Modern concurrency tools including agents, futures, promises, thread pools,
235411e
actors, supervisors, and more.
235411e
235411e
Inspired by Erlang, Clojure, Go, JavaScript, actors, and classic concurrency
235411e
patterns.
235411e
235411e
235411e
%package doc
235411e
Summary: Documentation for %{name}
235411e
Group: Documentation
235411e
Requires: %{name} = %{version}-%{release}
235411e
BuildArch: noarch
235411e
235411e
%description doc
235411e
Documentation for %{name}.
235411e
235411e
%prep
235411e
gem unpack %{SOURCE0}
235411e
235411e
%setup -q -D -T -n  %{gem_name}-%{version}
235411e
235411e
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
235411e
7383c78
%patch1 -p1
7383c78
235411e
%build
235411e
# Create the gem as gem install only works on a gem file
235411e
gem build %{gem_name}.gemspec
235411e
235411e
# %%gem_install compiles any C extensions and installs the gem into ./%%gem_dir
235411e
# by default, so that we can move it into the buildroot in %%install
235411e
%gem_install
235411e
235411e
%install
235411e
mkdir -p %{buildroot}%{gem_dir}
235411e
cp -a .%{gem_dir}/* \
235411e
        %{buildroot}%{gem_dir}/
235411e
235411e
235411e
# Run the test suite
235411e
%check
235411e
pushd .%{gem_instdir}
235411e
tar xzf %{SOURCE1}
235411e
235411e
# -edge is not part of this gem.
235411e
sed -i '/require.*concurrent-edge/ s/^/#/' spec/spec_helper.rb
235411e
60be4c2
# We don't have the C extension. It would need to come from concurrent-ruby-ext
60be4c2
# and that would lead to cicrular dependency.
235411e
sed -i '/allow_c_extensions?/,/^      end/ s/^/#/' spec/concurrent/atomic/atomic_reference_spec.rb
235411e
235411e
# Exclude the -edge test cases.
235411e
rspec -rspec_helper \
ca93902
  --exclude-pattern 'spec/concurrent/{actor_spec.rb,channel_spec.rb,lazy_register_spec.rb,channel/**/*,atomic/atomic_markable_reference_spec.rb,edge/**/*}' \
235411e
  spec
235411e
235411e
popd
235411e
235411e
%files
235411e
%dir %{gem_instdir}
235411e
%license %{gem_instdir}/LICENSE.txt
235411e
%{gem_libdir}
235411e
%exclude %{gem_cache}
235411e
%{gem_spec}
235411e
235411e
%files doc
235411e
%doc %{gem_docdir}
235411e
%doc %{gem_instdir}/CHANGELOG.md
235411e
%doc %{gem_instdir}/README.md
235411e
235411e
%changelog
7383c78
* Tue May 09 2017 Vít Ondruch <vondruch@redhat.com> - 1.0.5-1
7383c78
- Update to Concurrent Ruby 1.0.5.
7383c78
b2ced8e
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.4-2
b2ced8e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
b2ced8e
ca93902
* Tue Jan 03 2017 Vít Ondruch <vondruch@redhat.com> - 1.0.4-1
ca93902
- Update to Concurrent Ruby 1.0.4.
ca93902
60be4c2
* Mon Jul 04 2016 Vít Ondruch <vondruch@redhat.com> - 1.0.2-1
60be4c2
- Update to Concurrent Ruby 1.0.2.
60be4c2
573a838
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2
573a838
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
573a838
235411e
* Wed Dec 23 2015 Vít Ondruch <vondruch@redhat.com> - 1.0.0-1
235411e
- Initial package