Blob Blame Raw
# Generated from concurrent-ruby-1.0.0.gem by gem2rpm -*- rpm-spec -*-
%global gem_name concurrent-ruby

Name: rubygem-%{gem_name}
Version: 1.0.2
Release: 1%{?dist}
Summary: Modern concurrency tools for Ruby
Group: Development/Languages
License: MIT
# git clone && cd concurrent-ruby
# git checkout v1.0.2 && tar czvf concurrent-ruby-1.0.2-specs.tar.gz spec/
Source1: %{gem_name}-%{version}-specs.tar.gz
BuildRequires: ruby(release)
BuildRequires: rubygems-devel
BuildRequires: ruby >= 1.9.3
BuildRequires: rubygem(rspec)
BuildRequires: rubygem(timecop)
BuildArch: noarch

Modern concurrency tools including agents, futures, promises, thread pools,
actors, supervisors, and more.

Inspired by Erlang, Clojure, Go, JavaScript, actors, and classic concurrency

%package doc
Summary: Documentation for %{name}
Group: Documentation
Requires: %{name} = %{version}-%{release}
BuildArch: noarch

%description doc
Documentation for %{name}.

gem unpack %{SOURCE0}

%setup -q -D -T -n  %{gem_name}-%{version}

gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec

# Create the gem as gem install only works on a gem file
gem build %{gem_name}.gemspec

# %%gem_install compiles any C extensions and installs the gem into ./%%gem_dir
# by default, so that we can move it into the buildroot in %%install

mkdir -p %{buildroot}%{gem_dir}
cp -a .%{gem_dir}/* \

# Run the test suite
pushd .%{gem_instdir}
tar xzf %{SOURCE1}

# -edge is not part of this gem.
sed -i '/require.*concurrent-edge/ s/^/#/' spec/spec_helper.rb

# We don't have the C extension. It would need to come from concurrent-ruby-ext
# and that would lead to cicrular dependency.
sed -i '/allow_c_extensions?/,/^      end/ s/^/#/' spec/concurrent/atomic/atomic_reference_spec.rb

# Exclude the -edge test cases.
rspec -rspec_helper \
  --exclude-pattern 'spec/concurrent/{actor_spec.rb,channel_spec.rb,lazy_register_spec.rb,channel/**/*,atomic/atomic_markable_reference_spec.rb,edge/**/*}'\


%dir %{gem_instdir}
%license %{gem_instdir}/LICENSE.txt
%exclude %{gem_cache}

%files doc
%doc %{gem_docdir}
%doc %{gem_instdir}/
%doc %{gem_instdir}/

* Mon Jul 04 2016 Vít Ondruch <> - 1.0.2-1
- Update to Concurrent Ruby 1.0.2.

* Thu Feb 04 2016 Fedora Release Engineering <> - 1.0.0-2
- Rebuilt for

* Wed Dec 23 2015 Vít Ondruch <> - 1.0.0-1
- Initial package