Rebuilt for Ruby 1.9.3.
Upgrade to pg 0.12.2.
This commit is contained in:
parent
d466755883
commit
c9cce211c1
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
||||
/pg-0.11.0.gem
|
||||
/pg-0.12.2.gem
|
||||
|
@ -1,14 +1,11 @@
|
||||
# Generated from pg-0.11.0.gem by gem2rpm -*- rpm-spec -*-
|
||||
%global gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
|
||||
%global gemname pg
|
||||
%global geminstdir %{gemdir}/gems/%{gemname}-%{version}
|
||||
%{!?ruby_sitearch: %global ruby_sitearch %(ruby -rrbconfig -e 'puts Config::CONFIG["sitearchdir"]')}
|
||||
%global rubyabi 1.8
|
||||
%global gem_name pg
|
||||
%global rubyabi 1.9.1
|
||||
|
||||
Summary: A Ruby interface to the PostgreSQL RDBMS
|
||||
Name: rubygem-%{gemname}
|
||||
Version: 0.11.0
|
||||
Release: 6%{?dist}
|
||||
Name: rubygem-%{gem_name}
|
||||
Version: 0.12.2
|
||||
Release: 1%{?dist}
|
||||
Group: Development/Languages
|
||||
# Upstream license clarification (https://bitbucket.org/ged/ruby-pg/issue/72/)
|
||||
#
|
||||
@ -17,17 +14,18 @@ Group: Development/Languages
|
||||
#
|
||||
License: (GPLv2 or Ruby) and BSD
|
||||
URL: http://bitbucket.org/ged/ruby-pg/
|
||||
Source0: http://rubygems.org/gems/%{gemname}-%{version}.gem
|
||||
Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||||
Requires: ruby(abi) = %{rubyabi}
|
||||
Requires: rubygems
|
||||
Requires: ruby(rubygems)
|
||||
Requires: ruby
|
||||
BuildRequires: ruby(abi) = %{rubyabi}
|
||||
BuildRequires: rubygems
|
||||
BuildRequires: ruby ruby-devel
|
||||
BuildRequires: ruby-devel
|
||||
BuildRequires: rubygems-devel
|
||||
BuildRequires: ruby
|
||||
BuildRequires: postgresql-server postgresql-devel
|
||||
# Keep requiring rspec-core as long as rubygem(rspec) is provided by RSpec 1.x
|
||||
BuildRequires: rubygem(rspec-core)
|
||||
Provides: rubygem(%{gemname}) = %{version}
|
||||
Provides: rubygem(%{gem_name}) = %{version}
|
||||
|
||||
%description
|
||||
This is the extension library to access a PostgreSQL database from Ruby.
|
||||
@ -46,67 +44,74 @@ Documentation for %{name}
|
||||
|
||||
%prep
|
||||
%setup -q -c -T
|
||||
mkdir -p .%{gemdir}
|
||||
mkdir -p .%{gem_dir}
|
||||
export CONFIGURE_ARGS="--with-cflags='%{optflags}'"
|
||||
gem install --local --install-dir .%{gemdir} \
|
||||
gem install --local --install-dir .%{gem_dir} \
|
||||
-V --force %{SOURCE0}
|
||||
|
||||
%build
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{gemdir}
|
||||
cp -a .%{gemdir}/* \
|
||||
%{buildroot}%{gemdir}/
|
||||
mkdir -p %{buildroot}%{gem_dir}
|
||||
mkdir -p %{buildroot}%{gem_extdir}/lib
|
||||
cp -a .%{gem_dir}/* \
|
||||
%{buildroot}%{gem_dir}/
|
||||
|
||||
install -d -m0755 %{buildroot}%{ruby_sitearch}
|
||||
mv %{buildroot}%{geminstdir}/lib/pg_ext.so %{buildroot}%{ruby_sitearch}/
|
||||
mv %{buildroot}%{gem_libdir}/pg_ext.so %{buildroot}%{gem_extdir}/lib
|
||||
|
||||
# Remove the binary extension sources and build leftovers.
|
||||
rm -rf %{buildroot}%{geminstdir}/ext
|
||||
rm -rf %{buildroot}%{gem_instdir}/ext
|
||||
|
||||
# Remove useless shebangs.
|
||||
sed -i -e '/^#!\/usr\/bin\/env/d' %{buildroot}%{geminstdir}/lib/pg.rb
|
||||
sed -i -e '/^#!rake/d' %{buildroot}%{geminstdir}/Rakefile
|
||||
sed -i -e '/^#!rake/d' %{buildroot}%{geminstdir}/Rakefile.local
|
||||
sed -i -e '/^#!\/usr\/bin\/env/d' %{buildroot}%{gem_libdir}/pg.rb
|
||||
sed -i -e '/^#!rake/d' %{buildroot}%{gem_instdir}/Rakefile
|
||||
|
||||
# Fix spec shebangs.
|
||||
# https://bitbucket.org/ged/ruby-pg/issue/74/
|
||||
for file in `find %{buildroot}%{geminstdir}/spec -type f ! -perm /a+x -name "*.rb"`; do
|
||||
for file in `find %{buildroot}%{gem_instdir}/spec -type f ! -perm /a+x -name "*.rb"`; do
|
||||
[ ! -z "`head -n 1 $file | grep \"^#!/\"`" ] \
|
||||
&& sed -i -e 's/^#!\/usr\/bin\/env spec/#!\/usr\/bin\/env rspec/' $file \
|
||||
&& chmod -v 755 $file
|
||||
done
|
||||
|
||||
%check
|
||||
pushd .%{geminstdir}
|
||||
pushd .%{gem_instdir}
|
||||
rspec spec
|
||||
popd
|
||||
|
||||
%files
|
||||
%{ruby_sitearch}/pg_ext.so
|
||||
%dir %{geminstdir}
|
||||
%doc %{geminstdir}/BSD
|
||||
%doc %{geminstdir}/GPL
|
||||
%doc %{geminstdir}/LICENSE
|
||||
%{geminstdir}/lib
|
||||
%{gemdir}/cache/%{gemname}-%{version}.gem
|
||||
%{gemdir}/specifications/%{gemname}-%{version}.gemspec
|
||||
%exclude %{gem_instdir}/.gemtest
|
||||
%{gem_extdir}
|
||||
%dir %{gem_instdir}
|
||||
%doc %{gem_instdir}/BSD
|
||||
%doc %{gem_instdir}/GPL
|
||||
%doc %{gem_instdir}/LICENSE
|
||||
%{gem_libdir}
|
||||
%exclude %{gem_cache}
|
||||
%{gem_spec}
|
||||
|
||||
%files doc
|
||||
%doc %{gemdir}/doc/%{gemname}-%{version}
|
||||
%doc %{geminstdir}/ChangeLog
|
||||
%doc %{geminstdir}/Contributors
|
||||
%{geminstdir}/Rakefile
|
||||
%{geminstdir}/Rakefile.local
|
||||
%doc %{geminstdir}/README
|
||||
%doc %{geminstdir}/README.ja
|
||||
%doc %{geminstdir}/README.OS_X
|
||||
%doc %{geminstdir}/README.windows
|
||||
%{geminstdir}/rake
|
||||
%{geminstdir}/spec
|
||||
%doc %{gem_docdir}
|
||||
%doc %{gem_instdir}/ChangeLog
|
||||
%doc %{gem_instdir}/Contributors.rdoc
|
||||
%doc %{gem_instdir}/History.rdoc
|
||||
%doc %{gem_instdir}/Manifest.txt
|
||||
%{gem_instdir}/Rakefile
|
||||
%{gem_instdir}/Rakefile.cross
|
||||
%doc %{gem_instdir}/README.rdoc
|
||||
%doc %{gem_instdir}/README.ja.rdoc
|
||||
%doc %{gem_instdir}/README.OS_X.rdoc
|
||||
%doc %{gem_instdir}/README.windows.rdoc
|
||||
%{gem_instdir}/misc
|
||||
%{gem_instdir}/sample
|
||||
%{gem_instdir}/spec
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Jan 24 2012 Vít Ondruch <vondruch@redhat.com> - 0.12.2-1
|
||||
- Rebuilt for Ruby 1.9.3.
|
||||
- Upgrade to pg 0.12.2.
|
||||
|
||||
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11.0-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user