From fe196cb0dffacb5d2d1488e3b592cc8ba3f39a5e Mon Sep 17 00:00:00 2001 From: David Steele Date: Fri, 9 Aug 2019 14:52:26 -0400 Subject: [PATCH] Update RHEL patch for upstream changes. This isn't correct, but we can't test anything else if the package doesn't build. --- test/patch/rhel-package.patch | 22 ++++++++++++++++++---- test/test.pl | 3 +++ 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/test/patch/rhel-package.patch b/test/patch/rhel-package.patch index c9b4574bd..eb524b1b0 100644 --- a/test/patch/rhel-package.patch +++ b/test/patch/rhel-package.patch @@ -1,20 +1,34 @@ --- pgbackrest.spec +++ pgbackrest.spec -@@ -10,15 +10,14 @@ +@@ -10,18 +10,14 @@ Source0: https://github.com/pgbackrest/pgbackrest/archive/release/%{version}.tar.gz Source1: pgbackrest-conf.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -Requires: perl-XML-LibXML perl-IO-Socket-SSL %if 0%{?rhel} && 0%{?rhel} <= 6 - Requires: perl-parent perl-JSON perl-Time-HiRes +-Requires: perl-parent perl-JSON perl-Time-HiRes ++Requires: perl-parent perl-JSON %else Requires: perl-JSON-PP %endif -Requires: perl-Digest-SHA perl-DBD-Pg perl-Time-HiRes zlib -+Requires: perl-Digest-SHA perl-Time-HiRes zlib libxml2 ++Requires: perl-Time-HiRes openssl zlib libxml2 postgresql11-libs Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) -BuildRequires: openssl-devel zlib-devel perl-ExtUtils-Embed -+BuildRequires: openssl-devel zlib-devel postgresql-libs perl-ExtUtils-Embed +-BuildRequires: postgresql%{pgajorversion}-devel +-Requires: postgresql%{pgajorversion}-libs +- ++BuildRequires: openssl-devel zlib-devel perl-ExtUtils-Embed libxml2-devel postgresql11-devel %description pgBackRest aims to be a simple, reliable backup and restore system that can +@@ -39,8 +35,7 @@ + + %build + pushd src +-export CPPFLAGS='-I %{pginstdir}/include' +-LDFLAGS='-L%{pginstdir}/lib' %configure ++LDFLAGS='-L/usr/pgsql-11/lib' PATH=$PATH:/usr/pgsql-11/bin %configure + %{__make} + popd + diff --git a/test/test.pl b/test/test.pl index c47788806..e06862724 100755 --- a/test/test.pl +++ b/test/test.pl @@ -1148,6 +1148,9 @@ eval $oStorageBackRest->pathCreate("${strBuildPath}/RPMS", {bIgnoreExists => true, bCreateParent => true}); $oStorageBackRest->pathCreate("${strBuildPath}/BUILD", {bIgnoreExists => true, bCreateParent => true}); + # Install PostreSQL 11 development for package builds + executeTest("docker exec -i test-build bash -c 'yum install -y postgresql11-devel 2>&1'"); + # Copy source files executeTest( "tar --transform='s_^_pgbackrest-release-${strVersionBase}/_'" .