Blame SPECS/rubygem-coffee-rails.spec

b72b7d
%{?scl:%scl_package rubygem-%{gem_name}}
b72b7d
%{!?scl:%global pkg_name %{name}}
b72b7d
b72b7d
# Generated from coffee-rails-3.2.2.gem by gem2rpm -*- rpm-spec -*-
b72b7d
%global gem_name coffee-rails
b72b7d
b72b7d
# Fallback to rh-nodejs4. rh-nodejs4-scldevel is probably not available in
b72b7d
# the buildroot.
b72b7d
%{?scl:%{!?scl_nodejs:%global scl_nodejs rh-nodejs4}}
b72b7d
%{?scl:%{!?scl_prefix_nodejs:%global scl_prefix_nodejs %{scl_nodejs}-}}
b72b7d
b72b7d
Summary: Coffee Script adapter for the Rails asset pipeline
b72b7d
Name: %{?scl_prefix}rubygem-%{gem_name}
b72b7d
Version: 4.2.1
b72b7d
Release: 1%{?dist}
b72b7d
Group: Development/Languages
b72b7d
License: MIT
b72b7d
URL: https://github.com/rails/coffee-rails
b72b7d
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
b72b7d
# git clone https://github.com/rails/coffee-rails.git && cd coffee-rails
b72b7d
# git checkout v4.2.1 && tar czvf coffee-rails-4.2.1-tests.tgz test/
b72b7d
Source1: %{gem_name}-%{version}-tests.tgz
b72b7d
b72b7d
Requires:      %{?scl_prefix_ruby}ruby(release)
b72b7d
Requires:      %{?scl_prefix_ruby}ruby(rubygems)
b72b7d
Requires:      %{?scl_prefix}rubygem(coffee-script) >= 2.2.0
b72b7d
Requires:      %{?scl_prefix}rubygem(railties) >= 4.0.0
b72b7d
Requires:      %{?scl_prefix}rubygem(railties) < 5.2.0
b72b7d
BuildRequires: %{?scl_prefix_ruby}ruby(release)
b72b7d
BuildRequires: %{?scl_prefix_ruby}rubygems-devel
b72b7d
BuildRequires: %{?scl_prefix_ruby}ruby
b72b7d
BuildRequires: %{?scl_prefix}rubygem(coffee-script) >= 2.2.0
b72b7d
BuildRequires: %{?scl_prefix_ruby}rubygem(minitest)
b72b7d
BuildRequires: %{?scl_prefix}rubygem(railties) => 4.0.0
b72b7d
BuildRequires: %{?scl_prefix}rubygem(railties) < 5.2.0
b72b7d
BuildRequires: %{?scl_prefix}rubygem(sprockets-rails)
b72b7d
BuildRequires: %{?scl_prefix}rubygem(tzinfo)
b72b7d
BuildArch:     noarch
b72b7d
Provides:      %{?scl_prefix}rubygem(%{gem_name}) = %{version}
b72b7d
b72b7d
# Explicitly require runtime subpackage, as long as older scl-utils do not generate it
b72b7d
%{?scl:Requires: %{?scl_prefix}runtime}
b72b7d
b72b7d
BuildRequires: %{?scl_prefix_nodejs}nodejs
b72b7d
b72b7d
%description
b72b7d
Coffee Script adapter for the Rails asset pipeline.
b72b7d
b72b7d
%package doc
b72b7d
Summary: Documentation for %{pkg_name}
b72b7d
Group: Documentation
b72b7d
Requires: %{?scl_prefix}%{pkg_name} = %{version}-%{release}
b72b7d
BuildArch: noarch
b72b7d
b72b7d
%description doc
b72b7d
Documentation for %{pkg_name}.
b72b7d
b72b7d
%prep
b72b7d
%setup -n %{pkg_name}-%{version} -q -c -T
b72b7d
%{?scl:scl enable %{scl} - << \EOF}
b72b7d
%gem_install -n %{SOURCE0}
b72b7d
%{?scl:EOF}
b72b7d
b72b7d
%build
b72b7d
b72b7d
%install
b72b7d
mkdir -p %{buildroot}%{gem_dir}
b72b7d
cp -a .%{gem_dir}/* \
b72b7d
        %{buildroot}%{gem_dir}/
b72b7d
b72b7d
%check
b72b7d
pushd .%{gem_instdir}
b72b7d
tar xzvf %{SOURCE1}
b72b7d
# Disable Bundler.
b72b7d
sed -i '/require .bundler\/setup./ s/^/#/' test/test_helper.rb
b72b7d
%{?scl:scl enable %{scl} %{scl_nodejs} - << \EOF}
b72b7d
ruby -I.:test:lib -e 'Dir.glob("test/**/*_test.rb").each {|t| require t}'
b72b7d
%{?scl:EOF}
b72b7d
popd
b72b7d
b72b7d
%files
b72b7d
# There is no %%license macro on RHEL6.
b72b7d
# https://bugzilla.redhat.com/show_bug.cgi?id=1386246
b72b7d
%{!?_licensedir:%global license %%doc}
b72b7d
b72b7d
%dir %{gem_instdir}
b72b7d
%license %{gem_instdir}/MIT-LICENSE
b72b7d
%{gem_libdir}
b72b7d
%exclude %{gem_cache}
b72b7d
%{gem_spec}
b72b7d
b72b7d
%files doc
b72b7d
%doc %{gem_docdir}
b72b7d
%doc %{gem_instdir}/CHANGELOG.md
b72b7d
%doc %{gem_instdir}/README.md
b72b7d
b72b7d
%changelog
b72b7d
* Mon Nov 21 2016 Jun Aruga <jaruga@redhat.com> - 4.2.1-1
b72b7d
- Update to coffee-rails 4.2.1.
b72b7d
b72b7d
* Wed Mar 02 2016 Pavel Valena <pvalena@redhat.com> - 4.1.0-4
b72b7d
- Update to 4.1.0
b72b7d
b72b7d
* Tue Jan 27 2015 Josef Stribny <jstribny@redhat.com> - 4.0.1-1
b72b7d
- Update to 4.0.1
b72b7d
b72b7d
* Mon Feb 17 2014 Josef Stribny <jstribny@redhat.com> - 4.0.0-4
b72b7d
- Depend on scldevel(v8) virtual provide
b72b7d
b72b7d
* Thu Nov 28 2013 Josef Stribny <jstribny@redhat.com> - 4.0.0-3
b72b7d
- Use v8 macro
b72b7d
b72b7d
* Thu Oct 17 2013 Josef Stribny <jstribny@redhat.com> - 4.0.0-2
b72b7d
- Convert to scl
b72b7d
b72b7d
* Mon Aug 05 2013 Josef Stribny <jstribny@redhat.com> - 4.0.0-1
b72b7d
- Update to coffee-rails 4.0.0
b72b7d
b72b7d
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.2.2-4
b72b7d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
b72b7d
b72b7d
* Thu Mar 14 2013 Bohuslav Kabrda <bkabrda@redhat.com> - 3.2.2-3
b72b7d
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0
b72b7d
b72b7d
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.2.2-2
b72b7d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
b72b7d
b72b7d
* Mon Jul 23 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 3.2.2-1
b72b7d
- Initial package