|
|
72fb55 |
%{?scl:%scl_package rubygem-%{gem_name}}
|
|
|
72fb55 |
%{!?scl:%global pkg_name %{name}}
|
|
|
72fb55 |
|
|
|
72fb55 |
# Generated from globalid-0.3.0.gem by gem2rpm -*- rpm-spec -*-
|
|
|
72fb55 |
%global gem_name globalid
|
|
|
72fb55 |
|
|
|
72fb55 |
%{?_with_bootstrap: %global bootstrap 1}
|
|
|
72fb55 |
|
|
|
72fb55 |
Name: %{?scl_prefix}rubygem-%{gem_name}
|
|
|
72fb55 |
Version: 0.3.6
|
|
|
72fb55 |
Release: 2%{?dist}
|
|
|
72fb55 |
Summary: Refer to any model with a URI: gid://app/class/id
|
|
|
72fb55 |
Group: Development/Languages
|
|
|
72fb55 |
License: MIT
|
|
|
72fb55 |
URL: http://www.rubyonrails.org
|
|
|
72fb55 |
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
|
|
72fb55 |
# git clone https://github.com/rails/globalid.git && cd globalid
|
|
|
72fb55 |
# git checkout v0.3.6
|
|
|
72fb55 |
# tar czvf globalid-0.3.6-tests.tar.gz test/
|
|
|
72fb55 |
Source1: %{gem_name}-%{version}-tests.tar.gz
|
|
|
72fb55 |
# Fix Fixnum/Bignum deprecated warning for Ruby 2.4.0.
|
|
|
72fb55 |
# https://github.com/rails/globalid/commit/c1ef236
|
|
|
72fb55 |
Patch0: rubygem-globalid-0.3.7-fix-fixnum-bignum-warnings.patch
|
|
|
72fb55 |
|
|
|
72fb55 |
Requires: %{?scl_prefix_ruby}ruby(release)
|
|
|
72fb55 |
Requires: %{?scl_prefix_ruby}ruby(rubygems)
|
|
|
72fb55 |
Requires: %{?scl_prefix}rubygem(activesupport) >= 4.1.0
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix_ruby}ruby(release)
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix_ruby}rubygems-devel
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix_ruby}ruby >= 1.9.3
|
|
|
72fb55 |
%if ! 0%{?bootstrap}
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix}rubygem(activesupport) >= 4.1
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix}rubygem(activemodel) >= 4.1
|
|
|
72fb55 |
BuildRequires: %{?scl_prefix}rubygem(railties) >= 4.1
|
|
|
72fb55 |
%endif
|
|
|
72fb55 |
BuildArch: noarch
|
|
|
72fb55 |
Provides: %{?scl_prefix}rubygem(%{gem_name}) = %{version}
|
|
|
72fb55 |
|
|
|
72fb55 |
# Explicitly require runtime subpackage, as long as older scl-utils do not generate it
|
|
|
72fb55 |
%{?scl:Requires: %{?scl_prefix}runtime}
|
|
|
72fb55 |
|
|
|
72fb55 |
%description
|
|
|
72fb55 |
URIs for your models makes it easy to pass references around.
|
|
|
72fb55 |
|
|
|
72fb55 |
%package doc
|
|
|
72fb55 |
Summary: Documentation for %{pkg_name}
|
|
|
72fb55 |
Group: Documentation
|
|
|
72fb55 |
Requires: %{?scl_prefix}%{pkg_name} = %{version}-%{release}
|
|
|
72fb55 |
BuildArch: noarch
|
|
|
72fb55 |
|
|
|
72fb55 |
%description doc
|
|
|
72fb55 |
Documentation for %{pkg_name}.
|
|
|
72fb55 |
|
|
|
72fb55 |
%prep
|
|
|
72fb55 |
%{?scl:scl enable %{scl} - << \EOF}
|
|
|
72fb55 |
set -e
|
|
|
72fb55 |
gem unpack %{SOURCE0}
|
|
|
72fb55 |
|
|
|
72fb55 |
%setup -q -D -T -n %{gem_name}-%{version}
|
|
|
72fb55 |
|
|
|
72fb55 |
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
|
|
|
72fb55 |
%{?scl:EOF}
|
|
|
72fb55 |
|
|
|
72fb55 |
|
|
|
72fb55 |
%build
|
|
|
72fb55 |
%{?scl:scl enable %{scl} - << \EOF}
|
|
|
72fb55 |
set -e
|
|
|
72fb55 |
gem build %{gem_name}.gemspec
|
|
|
72fb55 |
%gem_install
|
|
|
72fb55 |
%{?scl:EOF}
|
|
|
72fb55 |
|
|
|
72fb55 |
|
|
|
72fb55 |
%install
|
|
|
72fb55 |
mkdir -p %{buildroot}%{gem_dir}
|
|
|
72fb55 |
cp -a .%{gem_dir}/* \
|
|
|
72fb55 |
%{buildroot}%{gem_dir}/
|
|
|
72fb55 |
|
|
|
72fb55 |
%if ! 0%{?bootstrap}
|
|
|
72fb55 |
%check
|
|
|
72fb55 |
pushd .%{gem_instdir}
|
|
|
72fb55 |
tar xf %{SOURCE1}
|
|
|
72fb55 |
cat %{PATCH0} | patch -p1
|
|
|
72fb55 |
sed -i '1d' ./test/helper.rb
|
|
|
72fb55 |
%{?scl:scl enable %{scl} - << \EOF}
|
|
|
72fb55 |
ruby -Ilib:test -rforwardable -e "Dir.glob './test/cases/*test.rb', &method(:require)"
|
|
|
72fb55 |
%{?scl:EOF}
|
|
|
72fb55 |
popd
|
|
|
72fb55 |
%endif
|
|
|
72fb55 |
|
|
|
72fb55 |
%files
|
|
|
72fb55 |
# There is no %%license macro on RHEL6.
|
|
|
72fb55 |
# https://bugzilla.redhat.com/show_bug.cgi?id=1386246
|
|
|
72fb55 |
%{!?_licensedir:%global license %%doc}
|
|
|
72fb55 |
|
|
|
72fb55 |
%dir %{gem_instdir}
|
|
|
72fb55 |
%{gem_libdir}
|
|
|
72fb55 |
%license %{gem_instdir}/MIT-LICENSE
|
|
|
72fb55 |
%{gem_instdir}/lib
|
|
|
72fb55 |
%exclude %{gem_cache}
|
|
|
72fb55 |
%{gem_spec}
|
|
|
72fb55 |
|
|
|
72fb55 |
%files doc
|
|
|
72fb55 |
%doc %{gem_docdir}
|
|
|
72fb55 |
|
|
|
72fb55 |
%changelog
|
|
|
72fb55 |
* Tue Feb 14 2017 Jun Aruga <jaruga@redhat.com> - 0.3.6-2
|
|
|
72fb55 |
- Fix Fixnum/Bignum deprecated warning for Ruby 2.4.0.
|
|
|
72fb55 |
|
|
|
72fb55 |
* Tue Nov 08 2016 Jun Aruga <jaruga@redhat.com> - 0.3.6-1
|
|
|
72fb55 |
- Update to 0.3.6
|
|
|
72fb55 |
|
|
|
72fb55 |
* Mon Feb 22 2016 Pavel Valena <pvalena@redhat.com> - 0.3.3-4
|
|
|
72fb55 |
- Add scl macros
|
|
|
72fb55 |
|
|
|
72fb55 |
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.3.3-3
|
|
|
72fb55 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
|
|
72fb55 |
|
|
|
72fb55 |
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.3-2
|
|
|
72fb55 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
|
|
72fb55 |
|
|
|
72fb55 |
* Thu Mar 19 2015 Josef Stribny <jstribny@redhat.com> - 0.3.3-1
|
|
|
72fb55 |
- Update to 0.3.3
|
|
|
72fb55 |
|
|
|
72fb55 |
* Tue Jan 06 2015 Josef Stribny <jstribny@redhat.com> - 0.3.0-1
|
|
|
72fb55 |
- Initial package
|