Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions deps-packaging/rsync/cfbuild-rsync.spec
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
%define rsync_version 3.4.2
%define rsync_version 3.4.3

Summary: CFEngine Build Automation -- rsync
Name: cfbuild-rsync
Version: %{version}
Release: 1
Source0: rsync-%{rsync_version}.tar.gz
Patch0: fix-sys-openat2-undeclared.patch
License: MIT
Group: Other
Url: https://cfengine.com
Expand All @@ -18,14 +19,16 @@ AutoReqProv: no
mkdir -p %{_builddir}
%setup -q -n rsync-%{rsync_version}

%patch -P 0 -p1

# liblz4, libxxhash, libzstd, and libssl give rsync extra compression
# algorithms, extra checksum algorithms, and allow use of openssl's crypto lib
# for (potentially) faster MD4/MD5 checksums.
./configure --prefix=%{prefix} --with-included-zlib=%{prefix} CPPFLAGS="-I%{prefix}/include" --disable-xxhash --disable-zstd --disable-lz4

%build

make
make

%install

Expand Down
2 changes: 2 additions & 0 deletions deps-packaging/rsync/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ build: build-stamp
build-stamp:
dh_testdir

patch -p1 < $(CURDIR)/fix-sys-openat2-undeclared.patch

# liblz4, libxxhash, libzstd, and libssl give rsync extra compression
# algorithms, extra checksum algorithms, and allow use of openssl's crypto
# lib for (potentially) faster MD4/MD5 checksums.
Expand Down
2 changes: 1 addition & 1 deletion deps-packaging/rsync/distfiles
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ff10aa2c151cd4b2dbbe6135126dbc854046113d2dfb49572a348233267eb315 rsync-3.4.2.tar.gz
c72e63ca3021cbc80ba86ec30102773f4c5631fbc492b52e773b3958f82a53d3 rsync-3.4.3.tar.gz
16 changes: 16 additions & 0 deletions deps-packaging/rsync/fix-sys-openat2-undeclared.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Fall back to defining SYS_openat2 when the running kernel-headers don't
export it from <asm/unistd.h>. See https://github.com/RsyncProject/rsync/issues/900.
The syscall number 437 is correct for all Linux architectures.

--- a/syscall.c
+++ b/syscall.c
@@ -37,6 +37,9 @@
#ifdef __linux__
#include <sys/syscall.h>
#include <linux/openat2.h>
+#ifndef SYS_openat2
+#define SYS_openat2 437
+#endif
#endif

#include "ifuncs.h"