From 696d36e7c577872f745fe17bcc69bc7da1168a33 Mon Sep 17 00:00:00 2001 From: Weisson Date: Mon, 22 Jul 2024 15:49:59 +0800 Subject: [PATCH] Add sw_64 xattr syscall support. Signed-off-by: Weisson --- 1002-dump-add-sw_64-xattr-support.patch | 29 +++++++++++++++++++++++++ dump.spec | 7 +++++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 1002-dump-add-sw_64-xattr-support.patch diff --git a/1002-dump-add-sw_64-xattr-support.patch b/1002-dump-add-sw_64-xattr-support.patch new file mode 100644 index 0000000..074e1dd --- /dev/null +++ b/1002-dump-add-sw_64-xattr-support.patch @@ -0,0 +1,29 @@ +From 9e186975f39b07d0e0fa5c753b700e4b8ae5aafc Mon Sep 17 00:00:00 2001 +From: Weisson +Date: Mon, 22 Jul 2024 15:35:36 +0800 +Subject: [PATCH] Add sw_64 xattr syscall support. + +Signed-off-by: Weisson +--- + restore/xattr.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/restore/xattr.c b/restore/xattr.c +index 0c1b547..5caba38 100644 +--- a/restore/xattr.c ++++ b/restore/xattr.c +@@ -180,6 +180,11 @@ struct ext2_xattr_entry { + # define __NR_lsetxattr 224 + # define __NR_lgetxattr 227 + # define __NR_llistxattr 230 ++#elif defined (__sw_64__) ++# define HAVE_XATTR_SYSCALLS 1 ++# define __NR_lsetxattr 383 ++# define __NR_lgetxattr 386 ++# define __NR_llistxattr 389 + #else + # warning "Extended attribute syscalls undefined for this architecture" + # define HAVE_XATTR_SYSCALLS 0 +-- +2.43.5 + diff --git a/dump.spec b/dump.spec index c04fbb8..f9b7d60 100644 --- a/dump.spec +++ b/dump.spec @@ -1,4 +1,4 @@ -%define anolis_release .0.3 +%define anolis_release .0.4 %define PREVER b46 %define DUMP_VERSION 0.4%{PREVER} @@ -28,6 +28,7 @@ Provides: dump-static Patch0: dump-buildfix.patch Patch1: dump-remove-lzo.patch Patch1001: 1001-add-arm-support-in-restore.patch +Patch1002: 1002-dump-add-sw_64-xattr-support.patch %description The dump package contains both dump and restore. Dump examines files @@ -55,6 +56,7 @@ Doc pages for %{name}. %patch0 -p1 -b .buildfix %patch1 -p1 -b .remove-lzo %patch1001 -p1 +%patch1002 -p1 -b .add-sw_64-xattr-support for i in MAINTAINERS COPYING ChangeLog; do iconv -f iso-8859-1 -t utf-8 $i -o $i.new @@ -123,6 +125,9 @@ rm -rf %{buildroot} %doc dump.lsm %changelog +* Wed Feb 12 2025 Weisson - 0.4-0.36.b46.0.4 +- Add sw_64 xattr syscall support. + * Fri Jan 24 2025 happy_orange - 0.4-0.36.b46.0.3 - add aarch64 support in restore -- Gitee