|
|
|
@ -34,11 +34,16 @@
|
|
|
|
|
|
|
|
|
|
Name: perl-DBI
|
|
|
|
|
Version: 1.643
|
|
|
|
|
Release: 9%{?dist}
|
|
|
|
|
Release: 26%{?dist}
|
|
|
|
|
Summary: A database access API for perl
|
|
|
|
|
License: GPL+ or Artistic
|
|
|
|
|
License: GPL-1.0-or-later OR Artistic-1.0-Perl
|
|
|
|
|
URL: http://dbi.perl.org/
|
|
|
|
|
Source0: https://cpan.metacpan.org/authors/id/T/TI/TIMB/DBI-%{version}.tar.gz
|
|
|
|
|
# Backport patches to properly solve CVE-2014-10401 and CVE-2014-10402
|
|
|
|
|
Patch0: DBI-1.643-Fix-for-CVE-2014-10401.patch
|
|
|
|
|
Patch1: DBI-1.643-Fix-for-empty-attributes-in-DSN.patch
|
|
|
|
|
Patch2: DBI-1.643-Catch-warning.patch
|
|
|
|
|
Patch3: DBI-1.643-Document-the-new-behavior-for-f_dir.patch
|
|
|
|
|
BuildRequires: coreutils
|
|
|
|
|
BuildRequires: findutils
|
|
|
|
|
BuildRequires: gcc
|
|
|
|
@ -115,7 +120,6 @@ BuildRequires: perl(Test::Simple) >= 0.90
|
|
|
|
|
BuildRequires: perl(Test::Pod) >= 1.00
|
|
|
|
|
BuildRequires: perl(Test::Pod::Coverage) >= 1.04
|
|
|
|
|
%endif
|
|
|
|
|
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
|
|
|
|
%if %{with perl_DBI_enables_Clone}
|
|
|
|
|
Suggests: perl(Clone) >= 0.34
|
|
|
|
|
%endif
|
|
|
|
@ -134,6 +138,8 @@ Suggests: perl(SQL::Statement) >= 1.402
|
|
|
|
|
# Filter unwanted dependencies
|
|
|
|
|
%{?perl_default_filter}
|
|
|
|
|
%global __requires_exclude %{?__requires_exclude:%{__requires_exclude}|}^perl\\(RPC::\\)
|
|
|
|
|
%global __requires_exclude %{__requires_exclude}|^perl\\(DBI::db\\)
|
|
|
|
|
%global __requires_exclude %{__requires_exclude}|^perl\\(DBI::st\\)
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
DBI is a database access Application Programming Interface (API) for
|
|
|
|
@ -144,7 +150,6 @@ database interface independent of the actual database being used.
|
|
|
|
|
%if %{with perl_DBI_enables_coro}
|
|
|
|
|
%package Coro
|
|
|
|
|
Summary: Asynchronous DBD::Gofer stream transport using Coro
|
|
|
|
|
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
|
|
|
|
|
|
|
|
|
%description Coro
|
|
|
|
|
This is an experimental asynchronous DBD::Gofer stream transport for DBI
|
|
|
|
@ -152,8 +157,31 @@ implemented on top of Coro. The BIG WIN from using Coro is that it enables
|
|
|
|
|
the use of existing DBI frameworks like DBIx::Class.
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%package tests
|
|
|
|
|
Summary: Tests for %{name}
|
|
|
|
|
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
|
|
|
|
Requires: perl-Test-Harness
|
|
|
|
|
# Optional run-time:
|
|
|
|
|
%if %{with perl_DBI_enables_Clone}
|
|
|
|
|
Requires: perl(Clone) >= 0.34
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with perl_DBI_enables_DB_File}
|
|
|
|
|
Requires: perl(DB_File)
|
|
|
|
|
%endif
|
|
|
|
|
%if %{with perl_DBI_enables_MLDBM}
|
|
|
|
|
Requires: perl(MLDBM)
|
|
|
|
|
%endif
|
|
|
|
|
# Do not build-require optional Params::Util to test the fall-back code
|
|
|
|
|
%if %{with perl_DBI_enables_SQL_Statement}
|
|
|
|
|
Requires: perl(SQL::Statement) >= 1.402
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%description tests
|
|
|
|
|
Tests from %{name}. Execute them
|
|
|
|
|
with "%{_libexecdir}/%{name}/test".
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n DBI-%{version}
|
|
|
|
|
%autosetup -p1 -n DBI-%{version}
|
|
|
|
|
for F in lib/DBD/Gofer.pm; do
|
|
|
|
|
iconv -f ISO-8859-1 -t UTF-8 < "$F" > "${F}.utf8"
|
|
|
|
|
touch -r "$F" "${F}.utf8"
|
|
|
|
@ -167,20 +195,27 @@ chmod 0644 ex/*
|
|
|
|
|
chmod 0755 dbixs_rev.pl
|
|
|
|
|
%if %{without perl_DBI_enables_coro}
|
|
|
|
|
rm lib/DBD/Gofer/Transport/corostream.pm
|
|
|
|
|
sed -i -e '/^lib\/DBD\/Gofer\/Transport\/corostream.pm$/d' MANIFEST
|
|
|
|
|
perl -i -ne 'print $_ unless m{^lib/DBD/Gofer/Transport/corostream.pm}' MANIFEST
|
|
|
|
|
|
|
|
|
|
%endif
|
|
|
|
|
# Remove RPC::Pl* reverse dependencies due to security concerns,
|
|
|
|
|
# CVE-2013-7284, bug #1051110
|
|
|
|
|
for F in lib/Bundle/DBI.pm lib/DBD/Proxy.pm lib/DBI/ProxyServer.pm \
|
|
|
|
|
dbiproxy.PL t/80proxy.t; do
|
|
|
|
|
rm "$F"
|
|
|
|
|
sed -i -e '\|^'"$F"'|d' MANIFEST
|
|
|
|
|
perl -i -ne 'print $_ unless m{^\Q'"$F"'\E}' MANIFEST
|
|
|
|
|
done
|
|
|
|
|
sed -i -e 's/"dbiproxy$ext_pl",//' Makefile.PL
|
|
|
|
|
perl -pi -e 's/"dbiproxy\$ext_pl",//' Makefile.PL
|
|
|
|
|
# Remove Win32 specific files to avoid unwanted dependencies
|
|
|
|
|
for F in lib/DBI/W32ODBC.pm lib/Win32/DBIODBC.pm; do
|
|
|
|
|
rm "$F"
|
|
|
|
|
sed -i -e '\|^'"$F"'|d' MANIFEST
|
|
|
|
|
perl -i -ne 'print $_ unless m{^\Q'"$F"'\E}' MANIFEST
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
# Help generators to recognize Perl scripts
|
|
|
|
|
for F in t/*.t t/*.pl; do
|
|
|
|
|
perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!.*perl\b}{$Config{startperl}}' "$F"
|
|
|
|
|
chmod +x "$F"
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
@ -193,6 +228,27 @@ perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" \
|
|
|
|
|
find %{buildroot} -type f -name '*.bs' -empty -delete
|
|
|
|
|
%{_fixperms} '%{buildroot}'/*
|
|
|
|
|
|
|
|
|
|
# Install tests
|
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
cp -a t %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
rm %{buildroot}%{_libexecdir}/%{name}/t/pod*.t
|
|
|
|
|
# Remove using of blib
|
|
|
|
|
perl -i -ne 'print $_ unless m{^use.*blib/}' %{buildroot}%{_libexecdir}/%{name}/t/1*.t
|
|
|
|
|
perl -pi -e 's/\-Mblib=\$getcwd\/blib//' %{buildroot}%{_libexecdir}/%{name}/t/85gofer.t
|
|
|
|
|
cat > %{buildroot}%{_libexecdir}/%{name}/test << 'EOF'
|
|
|
|
|
#!/bin/bash
|
|
|
|
|
set -e
|
|
|
|
|
# Some tests write into temporary files/directories. The easiest solution
|
|
|
|
|
# is to copy the tests into a writable directory and execute them from there.
|
|
|
|
|
DIR=$(mktemp -d)
|
|
|
|
|
pushd "$DIR"
|
|
|
|
|
cp -a %{_libexecdir}/%{name}/* ./
|
|
|
|
|
prove -I . -j "$(getconf _NPROCESSORS_ONLN)"
|
|
|
|
|
popd
|
|
|
|
|
rm -rf "$DIR"
|
|
|
|
|
EOF
|
|
|
|
|
chmod +x %{buildroot}%{_libexecdir}/%{name}/test
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
make test
|
|
|
|
|
|
|
|
|
@ -217,13 +273,70 @@ make test
|
|
|
|
|
%{perl_vendorarch}/DBD/Gofer/Transport/corostream.pm
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%files tests
|
|
|
|
|
%{_libexecdir}/%{name}
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 1.643-9
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 1.643-26
|
|
|
|
|
- Bump release for October 2024 mass rebuild:
|
|
|
|
|
Resolves: RHEL-64018
|
|
|
|
|
|
|
|
|
|
* Fri Oct 25 2024 MSVSphere Packaging Team <packager@msvsphere-os.ru> - 1.643-25
|
|
|
|
|
- Rebuilt for MSVSphere 10
|
|
|
|
|
|
|
|
|
|
* Fri Aug 09 2024 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-25
|
|
|
|
|
- Perl 5.40 re-rebuild of bootstrapped packages
|
|
|
|
|
|
|
|
|
|
* Thu Aug 08 2024 Troy Dawson <tdawson@redhat.com> - 1.643-24
|
|
|
|
|
- Bump release for Aug 2024 java mass rebuild
|
|
|
|
|
|
|
|
|
|
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 1.643-23
|
|
|
|
|
- Bump release for June 2024 mass rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-22
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-21
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Tue Sep 26 2023 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-20
|
|
|
|
|
- Fix CVE-2014-10401 and CVE-2014-10402
|
|
|
|
|
|
|
|
|
|
* Tue Sep 19 2023 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-19
|
|
|
|
|
- Package tests
|
|
|
|
|
|
|
|
|
|
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-18
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Wed Jul 12 2023 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-17
|
|
|
|
|
- Perl 5.38 re-rebuild of bootstrapped packages
|
|
|
|
|
|
|
|
|
|
* Tue Jul 11 2023 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-16
|
|
|
|
|
- Perl 5.38 rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-15
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-14
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jun 03 2022 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-13
|
|
|
|
|
- Perl 5.36 re-rebuild of bootstrapped packages
|
|
|
|
|
|
|
|
|
|
* Tue May 31 2022 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-12
|
|
|
|
|
- Perl 5.36 rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-11
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-10
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Mon May 24 2021 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-9
|
|
|
|
|
- Perl 5.34 re-rebuild of bootstrapped packages
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 1.643-8
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
* Fri May 21 2021 Jitka Plesnikova <jplesnik@redhat.com> - 1.643-8
|
|
|
|
|
- Perl 5.34 rebuild
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.643-7
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|