2020-08-28 15:50:37 +08:00
|
|
|
%global gem_name activemodel
|
|
|
|
|
%{?_with_bootstrap: %global bootstrap 1}
|
2021-02-08 17:47:31 +08:00
|
|
|
%global bootstrap 1
|
2020-08-28 15:50:37 +08:00
|
|
|
Name: rubygem-%{gem_name}
|
2021-02-08 17:47:31 +08:00
|
|
|
Version: 5.2.4.4
|
2020-08-28 15:50:37 +08:00
|
|
|
Release: 1
|
|
|
|
|
Summary: A toolkit for building modeling frameworks (part of Rails)
|
|
|
|
|
License: MIT
|
|
|
|
|
URL: http://rubyonrails.org
|
2021-02-08 17:47:31 +08:00
|
|
|
Source0: https://rubygems.org/gems/activemodel-5.2.4.4.gem
|
|
|
|
|
Source1: https://github.com/rails/rails/archive/v5.2.4.4.tar.gz
|
2020-08-28 15:50:37 +08:00
|
|
|
BuildRequires: ruby(release) rubygems-devel ruby >= 2.2.2 rubygem(activesupport) = %{version}
|
|
|
|
|
%if ! 0%{?bootstrap}
|
|
|
|
|
BuildRequires: rubygem(railties) = %{version}
|
|
|
|
|
%endif
|
|
|
|
|
BuildRequires: rubygem(bcrypt) => 3.1.2 rubygem(builder)
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
%description
|
|
|
|
|
A toolkit for building modeling frameworks like Active Record. Rich support
|
|
|
|
|
for attributes, callbacks, validations, serialization, internationalization,
|
|
|
|
|
and testing.
|
|
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
|
Summary: Documentation for %{name}
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
%description doc
|
|
|
|
|
Documentation for %{name}.
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -c -T
|
|
|
|
|
%gem_install -n %{SOURCE0}
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
mkdir -p %{buildroot}%{gem_dir}
|
|
|
|
|
cp -a .%{gem_dir}/* \
|
|
|
|
|
%{buildroot}%{gem_dir}/
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
pushd .%{gem_instdir}
|
|
|
|
|
tar xzvf %{SOURCE1}
|
|
|
|
|
cd rails-%{version}/%{gem_name}
|
|
|
|
|
%if 0%{?bootstrap}
|
|
|
|
|
mv ./test/cases/railtie_test.rb{,.disable}
|
|
|
|
|
%endif
|
|
|
|
|
ruby -Ilib:test -e "Dir.glob('./test/**/*_test.rb').sort.each {|t| require t}"
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%dir %{gem_instdir}
|
|
|
|
|
%license %{gem_instdir}/MIT-LICENSE
|
|
|
|
|
%{gem_libdir}
|
|
|
|
|
%exclude %{gem_cache}
|
|
|
|
|
%{gem_spec}
|
|
|
|
|
|
|
|
|
|
%files doc
|
|
|
|
|
%doc %{gem_docdir}
|
|
|
|
|
%doc %{gem_instdir}/CHANGELOG.md
|
|
|
|
|
%doc %{gem_instdir}/README.rdoc
|
|
|
|
|
|
|
|
|
|
%changelog
|
2021-02-08 17:47:31 +08:00
|
|
|
* Mon Feb 8 2021sunguoshuai<sunguoshuai@huawei.com>- 5.2.4.4-1
|
|
|
|
|
- Upgrade to 5.2.4.4
|
|
|
|
|
|
2020-08-28 15:50:37 +08:00
|
|
|
* Sat Aug 8 2020 chengzihan <chengzihan2@huawei.com> - 5.2.3-1
|
|
|
|
|
- Package init
|