Blame SPECS/rubygem-websocket-driver.spec

0f242a
%{?scl:%scl_package rubygem-%{gem_name}}
0f242a
%{!?scl:%global pkg_name %{name}}
0f242a
0f242a
# Generated from websocket-driver-0.3.4.gem by gem2rpm -*- rpm-spec -*-
0f242a
%global gem_name websocket-driver
0f242a
0f242a
Name: %{?scl_prefix}rubygem-%{gem_name}
0f242a
Version: 0.6.4
0f242a
Release: 1%{?dist}
0f242a
Summary: WebSocket protocol handler with pluggable I/O
0f242a
Group: Development/Languages
0f242a
License: MIT
0f242a
URL: http://github.com/faye/websocket-driver-ruby
0f242a
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
0f242a
# git clone https://github.com/faye/websocket-driver-ruby.git
0f242a
# cd websocket-driver-ruby && git checkout 0.6.4
0f242a
# tar czvf websocket-driver-ruby-0.6.4-tests.tgz spec/
0f242a
Source1: websocket-driver-ruby-%{version}-tests.tgz
0f242a
0f242a
Requires: %{?scl_prefix_ruby}ruby(release)
0f242a
Requires: %{?scl_prefix_ruby}ruby(rubygems)
0f242a
Requires: %{?scl_prefix}rubygem(websocket-extensions)
0f242a
BuildRequires: %{?scl_prefix_ruby}ruby(release)
0f242a
BuildRequires: %{?scl_prefix_ruby}ruby(rubygems)
0f242a
BuildRequires: %{?scl_prefix_ruby}ruby
0f242a
BuildRequires: %{?scl_prefix_ruby}ruby-devel
0f242a
BuildRequires: %{?scl_prefix_ruby}rubygems-devel
0f242a
BuildRequires: %{?scl_prefix}rubygem(websocket-extensions)
0f242a
BuildRequires: %{?scl_prefix}rubygem(rspec)
0f242a
Provides: %{?scl_prefix}rubygem(%{gem_name}) = %{version}
0f242a
0f242a
# Explicitly require runtime subpackage, as long as older scl-utils do not generate it
0f242a
%{?scl:Requires: %{?scl_prefix}runtime}
0f242a
0f242a
%description
0f242a
This module provides a complete implementation of the WebSocket protocols that
0f242a
can be hooked up to any TCP library. It aims to simplify things by decoupling
0f242a
the protocol details from the I/O layer, such that users only need to implement
0f242a
code to stream data in and out of it without needing to know anything about how
0f242a
the protocol actually works. Think of it as a complete WebSocket system with
0f242a
pluggable I/O.
0f242a
0f242a
%package doc
0f242a
Summary: Documentation for %{pkg_name}
0f242a
Group: Documentation
0f242a
Requires: %{?scl_prefix}%{pkg_name} = %{version}-%{release}
0f242a
BuildArch: noarch
0f242a
0f242a
%description doc
0f242a
Documentation for %{pkg_name}.
0f242a
0f242a
%prep
0f242a
%{?scl:scl enable %{scl} - << \EOF}
0f242a
set -e
0f242a
gem unpack %{SOURCE0}
0f242a
0f242a
%setup -q -D -T -n  %{gem_name}-%{version}
0f242a
0f242a
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
0f242a
%{?scl:EOF}
0f242a
0f242a
%build
0f242a
%{?scl:scl enable %{scl} - << \EOF}
0f242a
set -e
0f242a
gem build %{gem_name}.gemspec
0f242a
0f242a
%gem_install
0f242a
%{?scl:EOF}
0f242a
0f242a
%install
0f242a
mkdir -p %{buildroot}%{gem_dir}
0f242a
cp -a .%{gem_dir}/* \
0f242a
        %{buildroot}%{gem_dir}/
0f242a
0f242a
mkdir -p %{buildroot}%{gem_extdir_mri}
0f242a
cp -a .%{gem_extdir_mri}/{gem.build_complete,*.so} %{buildroot}%{gem_extdir_mri}/
0f242a
0f242a
# Prevent dangling symlink in -debuginfo (rhbz#878863).
0f242a
rm -rf %{buildroot}%{gem_instdir}/ext/
0f242a
0f242a
%check
0f242a
pushd .%{gem_instdir}
0f242a
tar xf %{SOURCE1}
0f242a
# Bundler
0f242a
sed -i -e '2d' examples/tcp_server.rb
0f242a
sed -i -e '2d' spec/spec_helper.rb
0f242a
export RUBYOPT="-I$(dirs +1)%{gem_extdir_mri}"
0f242a
%{?scl:scl enable %{scl} - << \EOF}
0f242a
rspec spec
0f242a
%{?scl:EOF}
0f242a
popd
0f242a
0f242a
%files
0f242a
%dir %{gem_instdir}
0f242a
%{gem_libdir}
0f242a
%{gem_extdir_mri}
0f242a
%exclude %{gem_cache}
0f242a
# Asking upstream to separate the license text.
0f242a
# https://github.com/faye/websocket-driver-ruby/issues/44
0f242a
%doc %{gem_instdir}/README.md
0f242a
%{gem_spec}
0f242a
0f242a
%files doc
0f242a
%doc %{gem_docdir}
0f242a
%doc %{gem_instdir}/CHANGELOG.md
0f242a
%{gem_instdir}/examples
0f242a
0f242a
%changelog
0f242a
* Thu Jul 07 2016 Jun Aruga <jaruga@redhat.com> - 0.6.4-1
0f242a
- Update to websocket-driver 0.6.4.
0f242a
0f242a
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.4-5
0f242a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
0f242a
0f242a
* Mon Jan 11 2016 Pavel Valena <pvalena@redhat.com> - 0.3.4-4
0f242a
- Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_2.3
0f242a
- Correct attributes for websocket_mask.so
0f242a
0f242a
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.4-3
0f242a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
0f242a
0f242a
* Sun Jan 18 2015 Mamoru TASAKA <mtasaka@fedoraproject.org> - 0.3.4-2
0f242a
- Rebuild for https://fedoraproject.org/wiki/Changes/Ruby_2.2
0f242a
0f242a
* Tue Jul 15 2014 Josef Stribny <jstribny@redhat.com> - 0.3.4-1
0f242a
- Initial package