Blame rubygem-archivist.spec

16cc690
# Generated from archivist-1.0.5.1.gem by gem2rpm -*- rpm-spec -*-
16cc690
%global gem_name archivist
16cc690
16cc690
%global rubyabi 1.9.1
16cc690
16cc690
Summary: A rails 3 model archiving system based on acts_as_archive
16cc690
Name: rubygem-%{gem_name}
16cc690
Version: 1.1.1
1b5a50b
Release: 2%{?dist}
16cc690
Group: Development/Languages
16cc690
License: MIT
16cc690
URL: http://github.com/tpickett66/archivist
16cc690
Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
16cc690
# Partial support for sqlite3.
16cc690
# https://github.com/tpickett66/archivist/issues/3
16cc690
Patch0: archivist-1.1.1-support-sqlite3.patch
16cc690
Requires: ruby(abi) = %{rubyabi}
16cc690
Requires: ruby(rubygems)
16cc690
Requires: rubygem(activerecord) => 3.0.0
16cc690
BuildRequires: ruby(abi) = %{rubyabi}
16cc690
BuildRequires: rubygems-devel
16cc690
BuildRequires: rubygem(minitest)
16cc690
BuildRequires: rubygem(rails)
16cc690
BuildRequires: rubygem(sqlite3)
16cc690
BuildRequires: rubygem(shoulda)
16cc690
BuildRequires: rubygem(factory_girl)
16cc690
BuildArch: noarch
16cc690
Provides: rubygem(%{gem_name}) = %{version}
16cc690
16cc690
%description
16cc690
This is a functional replacement for acts_as_archive in
16cc690
rails 3 applications, the only functionality that is not
16cc690
duplicated is the migration from acts_as_paranoid
16cc690
16cc690
16cc690
%package doc
16cc690
Summary: Documentation for %{name}
16cc690
Group: Documentation
16cc690
Requires: %{name} = %{version}-%{release}
16cc690
BuildArch: noarch
16cc690
16cc690
%description doc
16cc690
Documentation for %{name}
16cc690
16cc690
16cc690
%prep
16cc690
%setup -q -c -T
16cc690
mkdir -p .%{gem_dir}
16cc690
gem install --local --install-dir .%{gem_dir} \
16cc690
            -V --force %{SOURCE0}
16cc690
16cc690
pushd .%{gem_instdir}
16cc690
%patch0 -p1
16cc690
popd
16cc690
16cc690
%build
16cc690
16cc690
%install
16cc690
mkdir -p %{buildroot}%{gem_dir}
16cc690
cp -a .%{gem_dir}/* \
16cc690
        %{buildroot}%{gem_dir}/
16cc690
16cc690
chmod a+x %{buildroot}%{gem_instdir}/Rakefile
16cc690
chmod a+x %{buildroot}%{gem_instdir}/test/dummy/Rakefile
16cc690
16cc690
%check
16cc690
pushd .%{gem_instdir}
16cc690
16cc690
pushd test/dummy
16cc690
# Get rid of Bundler.
16cc690
sed -i "/Bundler.require/ d" config/application.rb
16cc690
# Force sqlite3 as a DB backend.
16cc690
sed -i "s/<%=.*%>/sqlite3/" config/database.yml
16cc690
popd
16cc690
16cc690
# Debugger should not be needed by test suite I guess.
16cc690
sed -i "13,+5d" test/test_helper.rb
16cc690
16cc690
# I tried to make the test suite work with sqlite3, but failed. Since sqlite3
16cc690
# is not supported ATM, I am not sure if that is not dead end.
16cc690
# https://github.com/tpickett66/archivist/issues/3
16cc690
# testrb test/*_test.rb
16cc690
testrb test/archivist_test.rb
16cc690
popd
16cc690
16cc690
%files
16cc690
%dir %{gem_instdir}
16cc690
%{gem_libdir}
16cc690
%doc %{gem_instdir}/MIT-LICENSE
16cc690
%exclude %{gem_cache}
16cc690
%{gem_spec}
16cc690
16cc690
%files doc
16cc690
%doc %{gem_docdir}
16cc690
%doc %{gem_instdir}/README.rdoc
16cc690
%{gem_instdir}/Rakefile
16cc690
%{gem_instdir}/test
16cc690
16cc690
16cc690
%changelog
1b5a50b
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.1-2
1b5a50b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
1b5a50b
16cc690
* Wed Aug 15 2012 Vít Ondruch <vondruch@redhat.com> - 1.1.1-1
16cc690
- Update to archivist 1.1.1.
16cc690
16cc690
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.5.1-5
16cc690
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
16cc690
16cc690
* Thu Feb 02 2012 Vít Ondruch <vondruch@redhat.com> - 1.0.5.1-4
16cc690
- Rebuilt for Ruby 1.9.3.
16cc690
16cc690
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.5.1-3
16cc690
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
16cc690
16cc690
* Thu Sep 01 2011 Maros Zatko <mzatko@redhat.com> - 1.0.5.1-2
16cc690
- Added %%doc, removed shoulda dep
16cc690
16cc690
* Thu Sep 01 2011 Maros Zatko <mzatko@redhat.com> - 1.0.5.1-1
16cc690
- Initial package