2016-05-04 04:32:15 +02:00
|
|
|
#
|
|
|
|
# spec file for package pgbackrest
|
|
|
|
#
|
2021-02-25 11:27:42 +01:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
|
|
|
# Copyright (c) 2019-2021 Ioda-Net Sàrl, Charmoille, Switzerland.
|
2016-05-04 04:32:15 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2018-10-29 08:01:08 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2016-05-04 04:32:15 +02:00
|
|
|
#
|
|
|
|
|
2019-02-11 11:39:47 +01:00
|
|
|
|
2018-07-12 10:01:33 +02:00
|
|
|
%if ! %{defined make_build}
|
2019-02-11 11:39:47 +01:00
|
|
|
# Temporary fix for Leap 42.3
|
|
|
|
%define make_build %{_bindir}/make %{?_smp_mflags}
|
2018-07-12 10:01:33 +02:00
|
|
|
%endif
|
2016-05-04 04:32:15 +02:00
|
|
|
Name: pgbackrest
|
2021-07-27 18:30:18 +02:00
|
|
|
Version: 2.34
|
2016-05-04 04:32:15 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Reliable PostgreSQL Backup & Restore
|
2018-03-10 21:11:23 +01:00
|
|
|
License: MIT
|
2016-05-04 04:32:15 +02:00
|
|
|
Group: Productivity/Databases/Tools
|
2019-02-11 11:39:47 +01:00
|
|
|
URL: http://www.pgbackrest.org
|
2020-03-24 16:08:48 +01:00
|
|
|
Source: https://github.com/pgbackrest/pgbackrest/archive/release/%{version}/%{name}-%{version}.tar.gz
|
2018-02-05 18:37:50 +01:00
|
|
|
Source1: pgbackrest-conf.patch
|
2019-08-26 03:23:36 +02:00
|
|
|
Patch0: libpq-fe.h_localisation.patch
|
2018-02-05 18:37:50 +01:00
|
|
|
BuildRequires: openssl-devel
|
2019-12-04 17:52:04 +01:00
|
|
|
BuildRequires: pkgconfig
|
2020-05-30 16:10:16 +02:00
|
|
|
BuildRequires: pkgconfig(bzip2)
|
2020-05-01 18:28:44 +02:00
|
|
|
BuildRequires: pkgconfig(liblz4)
|
2021-02-25 11:27:42 +01:00
|
|
|
BuildRequires: pkgconfig(libpq)
|
2020-03-24 16:08:48 +01:00
|
|
|
BuildRequires: pkgconfig(libxml-2.0)
|
2016-05-04 04:32:15 +02:00
|
|
|
|
|
|
|
%description
|
2019-02-21 09:59:16 +01:00
|
|
|
pgBackRest aims to be a simple, reliable backup and restore system for
|
|
|
|
PostgreSQL that can seamlessly scale up to the largest databases and
|
|
|
|
workloads.
|
2016-05-04 04:32:15 +02:00
|
|
|
|
2019-02-21 09:59:16 +01:00
|
|
|
The following features are available:
|
|
|
|
- Parallel backup & restore
|
|
|
|
- Local or remote operation
|
|
|
|
- Full, incremental, differential backups
|
|
|
|
- Backup rotation & archive expiration
|
|
|
|
- Backup integrity
|
|
|
|
- Page checksums
|
|
|
|
- Backup resume
|
|
|
|
- Streaming compression & checksums
|
|
|
|
- Delta restore
|
|
|
|
- Parallel, asynchronous WAL push & get
|
|
|
|
- Tablespace & link support
|
|
|
|
- Amazon S3 support
|
|
|
|
- Encryption
|
|
|
|
- Compatibility with PostgreSQL >= 8.3
|
2016-05-04 04:32:15 +02:00
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n %{name}-release-%{version}
|
2020-03-24 16:08:48 +01:00
|
|
|
%autopatch -p1
|
2019-08-26 03:23:36 +02:00
|
|
|
pushd src
|
|
|
|
%configure
|
|
|
|
popd
|
2016-05-04 04:32:15 +02:00
|
|
|
|
|
|
|
%build
|
2018-07-14 18:30:33 +02:00
|
|
|
# TODO upstream doesn't care about RPM_OPT_FLAGS
|
2019-08-26 03:23:36 +02:00
|
|
|
export CFLAGS="%optflags"
|
2018-03-10 21:11:23 +01:00
|
|
|
pushd src
|
2018-05-28 11:56:30 +02:00
|
|
|
%make_build
|
2018-03-10 21:11:23 +01:00
|
|
|
popd
|
|
|
|
|
2016-05-04 04:32:15 +02:00
|
|
|
%install
|
2018-03-10 21:11:23 +01:00
|
|
|
install -D -d -m 0700 %{buildroot}/%{_localstatedir}/lib/%{name}
|
|
|
|
install -D -d -m 0700 %{buildroot}%{_localstatedir}/log/%{name}
|
|
|
|
install -D -d -m 0700 %{buildroot}%{_localstatedir}/spool/%{name}
|
|
|
|
install -D -d -m 0755 %{buildroot}%{_sysconfdir}
|
|
|
|
install %{SOURCE1} %{buildroot}/%{_sysconfdir}/%{name}.conf
|
2019-08-26 03:23:36 +02:00
|
|
|
make install -C src DESTDIR=%{buildroot}
|
2018-02-05 18:37:50 +01:00
|
|
|
|
|
|
|
%check
|
2018-07-14 18:30:33 +02:00
|
|
|
# Tests are only available with Vagrant
|
|
|
|
# We just test that the binary works.
|
2019-02-21 09:59:16 +01:00
|
|
|
%{buildroot}/%{_bindir}/%{name} version || exit 1
|
2018-02-05 18:37:50 +01:00
|
|
|
|
2018-07-14 18:30:33 +02:00
|
|
|
%files
|
2016-05-04 04:32:15 +02:00
|
|
|
%defattr(-,root,root)
|
2018-02-05 18:37:50 +01:00
|
|
|
%doc README.md
|
2018-03-10 21:11:23 +01:00
|
|
|
%license LICENSE
|
2018-02-05 18:37:50 +01:00
|
|
|
%config(noreplace) %attr (644,root,root) %{_sysconfdir}/%{name}.conf
|
|
|
|
# We still can do that as postgres user is system fixed
|
2018-03-10 21:11:23 +01:00
|
|
|
%attr(-,postgres,postgres) %{_localstatedir}/log/%{name}
|
2018-02-05 18:37:50 +01:00
|
|
|
%attr(-,postgres,postgres) %{_localstatedir}/lib/%{name}
|
2018-03-10 21:11:23 +01:00
|
|
|
%attr(-,postgres,postgres) %{_localstatedir}/spool/%{name}
|
2018-07-14 18:30:33 +02:00
|
|
|
%{_bindir}/%{name}
|
2018-02-05 18:37:50 +01:00
|
|
|
|
2018-03-10 21:11:23 +01:00
|
|
|
%changelog
|