|
|
|
@ -2,8 +2,8 @@
|
|
|
|
|
%global gem_name pg
|
|
|
|
|
|
|
|
|
|
Name: rubygem-%{gem_name}
|
|
|
|
|
Version: 1.2.3
|
|
|
|
|
Release: 7%{?dist}
|
|
|
|
|
Version: 1.0.0
|
|
|
|
|
Release: 3%{?dist}
|
|
|
|
|
Summary: A Ruby interface to the PostgreSQL RDBMS
|
|
|
|
|
# Upstream license clarification (https://bitbucket.org/ged/ruby-pg/issue/72/)
|
|
|
|
|
#
|
|
|
|
@ -11,13 +11,17 @@ Summary: A Ruby interface to the PostgreSQL RDBMS
|
|
|
|
|
# the BSD 3-Clause license; the contents of the BSD file are incorrect.
|
|
|
|
|
#
|
|
|
|
|
License: (BSD or Ruby) and PostgreSQL
|
|
|
|
|
URL: https://github.com/ged/ruby-pg
|
|
|
|
|
URL: https://bitbucket.org/ged/ruby-pg
|
|
|
|
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
|
|
|
|
# Disable RPATH.
|
|
|
|
|
# https://bitbucket.org/ged/ruby-pg/issue/183
|
|
|
|
|
Patch0: rubygem-pg-0.17.1-remove-rpath.patch
|
|
|
|
|
# Required in ext/pg_text_decoder.c
|
|
|
|
|
Requires: rubygem(bigdecimal)
|
|
|
|
|
# Add feature to set testing port.
|
|
|
|
|
# https://github.com/ged/ruby-pg/commit/104ec67
|
|
|
|
|
Patch1: rubygem-pg-1.1.4-add-feature-to-set-testing-port.patch
|
|
|
|
|
# Fix compatibility with PG 10.6 and above.
|
|
|
|
|
# https://github.com/ged/ruby-pg/issues/287
|
|
|
|
|
Patch2: rubygem-pg-1.1.3-Fix-specs-for-PostgreSQL-11.patch
|
|
|
|
|
BuildRequires: ruby(release)
|
|
|
|
|
BuildRequires: rubygems-devel
|
|
|
|
|
BuildRequires: ruby-devel
|
|
|
|
@ -25,8 +29,7 @@ BuildRequires: ruby-devel
|
|
|
|
|
# https://fedoraproject.org/wiki/Packaging:C_and_C++#BuildRequires_and_Requires
|
|
|
|
|
BuildRequires: gcc
|
|
|
|
|
|
|
|
|
|
BuildRequires: postgresql-server libpq-devel
|
|
|
|
|
BuildRequires: rubygem(bigdecimal)
|
|
|
|
|
BuildRequires: postgresql-server postgresql-devel
|
|
|
|
|
BuildRequires: rubygem(rspec)
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
@ -43,9 +46,11 @@ BuildArch: noarch
|
|
|
|
|
Documentation for %{name}.
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n %{gem_name}-%{version}
|
|
|
|
|
%setup -q -n %{gem_name}-%{version}
|
|
|
|
|
|
|
|
|
|
%patch0 -p1
|
|
|
|
|
%patch1 -p1
|
|
|
|
|
%patch2 -p1
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
# Create the gem as gem install only works on a gem file
|
|
|
|
@ -76,19 +81,23 @@ for file in `find %{buildroot}%{gem_libdir} -type f -name "*.rb"`; do
|
|
|
|
|
&& chmod -v 644 $file
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
# Fix spec shebangs.
|
|
|
|
|
# https://bitbucket.org/ged/ruby-pg/issues/269/
|
|
|
|
|
for file in `find %{buildroot}%{gem_instdir}/spec -type f -name "*.rb"`; do
|
|
|
|
|
if [ ! -z "`head -n 1 $file | grep \"^#!/\"`" ]; then
|
|
|
|
|
sed -i '/^#!\/usr\/bin\/env/ d' $file
|
|
|
|
|
chmod -v 644 $file
|
|
|
|
|
fi
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
pushd .%{gem_instdir}
|
|
|
|
|
# Set --verbose to show detail log by $VERBOSE.
|
|
|
|
|
# See https://github.com/ged/ruby-pg/blob/master/spec/helpers.rb $VERBOSE
|
|
|
|
|
# Assign a random port to consider a case of multi builds in parallel in a host.
|
|
|
|
|
# https://github.com/ged/ruby-pg/pull/39
|
|
|
|
|
if ! PGPORT="$((54321 + ${RANDOM} % 1000))" ruby -S --verbose \
|
|
|
|
|
rspec -I$(dirs +1)%{gem_extdir_mri} -f d spec; then
|
|
|
|
|
echo "==== [setup.log start ] ===="
|
|
|
|
|
cat tmp_test_specs/setup.log
|
|
|
|
|
echo "==== [setup.log end ] ===="
|
|
|
|
|
false
|
|
|
|
|
fi
|
|
|
|
|
PGPORT="$((54321 + ${RANDOM} % 1000))" ruby -S --verbose \
|
|
|
|
|
rspec -I$(dirs +1)%{gem_extdir_mri} -f d spec
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
@ -116,64 +125,11 @@ popd
|
|
|
|
|
%{gem_instdir}/spec
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 1.2.3-7
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 1.2.3-6
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
|
|
|
|
|
* Mon Feb 08 2021 Pavel Raiskup <praiskup@redhat.com> - 1.2.3-5
|
|
|
|
|
- rebuild for libpq ABI fix rhbz#1908268
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.3-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Wed Jan 6 2021 Vít Ondruch <vondruch@redhat.com> - 1.2.3-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_3.0
|
|
|
|
|
|
|
|
|
|
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.3-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Mar 19 2020 Jun Aruga <jaruga@redhat.com> - 1.2.3-1
|
|
|
|
|
- Update to pg 1.2.3.
|
|
|
|
|
|
|
|
|
|
* Fri Mar 06 2020 Jun Aruga <jaruga@redhat.com> - 1.2.2-1
|
|
|
|
|
- Update to pg 1.2.2.
|
|
|
|
|
|
|
|
|
|
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.1-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jan 17 2020 Vít Ondruch <vondruch@redhat.com> - 1.2.1-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_2.7
|
|
|
|
|
|
|
|
|
|
* Mon Jan 06 2020 Jun Aruga <jaruga@redhat.com> - 1.2.1-1
|
|
|
|
|
- Update to pg 1.2.1.
|
|
|
|
|
|
|
|
|
|
* Thu Jan 02 2020 Jun Aruga <jaruga@redhat.com> - 1.2.0-1
|
|
|
|
|
- Update to pg 1.2.0.
|
|
|
|
|
|
|
|
|
|
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.4-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.4-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jan 17 2019 Vít Ondruch <vondruch@redhat.com> - 1.1.4-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_2.6
|
|
|
|
|
|
|
|
|
|
* Thu Jan 10 2019 Vít Ondruch <vondruch@redhat.com> - 1.1.4-1
|
|
|
|
|
- Update to pg 1.1.4.
|
|
|
|
|
|
|
|
|
|
* Wed Jan 09 2019 Vít Ondruch <vondruch@redhat.com> - 1.1.3-2
|
|
|
|
|
- Fix PostgreSQL 11 compatibility.
|
|
|
|
|
|
|
|
|
|
* Tue Sep 18 2018 Jun Aruga <jaruga@redhat.com> - 1.1.3-1
|
|
|
|
|
- Update to pg 1.1.3.
|
|
|
|
|
- Update to output log when tests fail.
|
|
|
|
|
* Tue Jun 13 2023 Jarek Prokop <jprokop@redhat.com> - 1.0.0-3
|
|
|
|
|
- Fix FTBFS with PostgreSQL 10.6 and above.
|
|
|
|
|
|
|
|
|
|
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.0-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
|
|
|
|
* Thu May 23 2019 Jun Aruga <jaruga@redhat.com> - 1.0.0-2
|
|
|
|
|
- Assign a random testing port.
|
|
|
|
|
|
|
|
|
|
* Tue Feb 13 2018 Vít Ondruch <vondruch@redhat.com> - 1.0.0-1
|
|
|
|
|
- Update to pg 1.0.0.
|
|
|
|
|