Compare commits

...

No commits in common. "c9-beta" and "c10s" have entirely different histories.

12 changed files with 225 additions and 23 deletions

1
.fmf/version Normal file
View File

@ -0,0 +1 @@
1

2
.gitignore vendored
View File

@ -1 +1 @@
SOURCES/dump-0.4b47.tar.gz /dump-0.4b47.tar.gz

View File

@ -1 +0,0 @@
16f1c6c69e920b640f25acf24dbb2a875018e06a SOURCES/dump-0.4b47.tar.gz

133
dump-glibc_xattr.patch Normal file
View File

@ -0,0 +1,133 @@
From 996ac7b862d598ab77436bdff750718d00c714a9 Mon Sep 17 00:00:00 2001
From: Vaclav Dolezal <vdolezal@redhat.com>
Date: Wed, 6 Mar 2019 11:37:50 +0100
Subject: [PATCH] Use xattr functions from libc
Signed-off-by: Vaclav Dolezal <vdolezal@redhat.com>
---
restore/xattr.c | 95 +------------------------------------------------
1 file changed, 1 insertion(+), 94 deletions(-)
diff --git a/restore/xattr.c b/restore/xattr.c
index 0c1b547..9f80da6 100644
--- a/restore/xattr.c
+++ b/restore/xattr.c
@@ -30,6 +30,7 @@
#include <config.h>
#include <compaterr.h>
#include <sys/types.h>
+#include <sys/xattr.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -118,82 +119,6 @@ struct ext2_xattr_entry {
(entry)->e_value_offs + sizeof(struct ext3_xattr_ibody_header) : \
(entry)->e_value_offs))
-/*
- * xattr syscalls do not exist yet in libc, get our own copy here,
- * taken from libattr.
- */
-#if defined (__i386__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 227
-# define __NR_lgetxattr 230
-# define __NR_llistxattr 233
-#elif defined (__sparc__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 170
-# define __NR_lgetxattr 173
-# define __NR_llistxattr 179
-#elif defined (__ia64__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 1218
-# define __NR_lgetxattr 1221
-# define __NR_llistxattr 1224
-#elif defined (__powerpc__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 210
-# define __NR_lgetxattr 213
-# define __NR_llistxattr 216
-#elif defined (__x86_64__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 189
-# define __NR_lgetxattr 192
-# define __NR_llistxattr 195
-#elif defined (__s390__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 225
-# define __NR_lgetxattr 228
-# define __NR_llistxattr 231
-#elif defined (__arm__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_SYSCALL_BASE 0x900000
-# define __NR_lsetxattr (__NR_SYSCALL_BASE+227)
-# define __NR_lgetxattr (__NR_SYSCALL_BASE+230)
-# define __NR_llistxattr (__NR_SYSCALL_BASE+233)
-#elif defined (__mips64__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_Linux 5000
-# define __NR_lsetxattr (__NR_Linux + 218)
-# define __NR_lgetxattr (__NR_Linux + 221)
-# define __NR_llistxattr (__NR_Linux + 224)
-#elif defined (__mips__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_Linux 4000
-# define __NR_lsetxattr (__NR_Linux + 225)
-# define __NR_lgetxattr (__NR_Linux + 228)
-# define __NR_llistxattr (__NR_Linux + 231)
-#elif defined (__alpha__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 383
-# define __NR_lgetxattr 386
-# define __NR_llistxattr 389
-#elif defined (__mc68000__)
-# define HAVE_XATTR_SYSCALLS 1
-# define __NR_lsetxattr 224
-# define __NR_lgetxattr 227
-# define __NR_llistxattr 230
-#else
-# warning "Extended attribute syscalls undefined for this architecture"
-# define HAVE_XATTR_SYSCALLS 0
-#endif
-
-#if HAVE_XATTR_SYSCALLS
-# define SYSCALL(args...) syscall(args)
-#else
-# define SYSCALL(args...) ( errno = ENOSYS, -1 )
-#endif
-
-static int lsetxattr (const char *, const char *, void *, size_t, int);
-static ssize_t lgetxattr (const char *, const char *, void *, size_t);
-static ssize_t llistxattr (const char *, char *, size_t);
static int xattr_cb_list (char *, char *, int, int, void *);
static int xattr_cb_set (char *, char *, int, int, void *);
static int xattr_cb_compare (char *, char *, int, int, void *);
@@ -201,24 +126,6 @@ static int xattr_verify (char *);
static int xattr_count (char *, int *);
static int xattr_walk (char *, int (*)(char *, char *, int, int, void *), void *);
-static int
-lsetxattr(const char *path, const char *name, void *value, size_t size, int flags)
-{
- return SYSCALL(__NR_lsetxattr, path, name, value, size, flags);
-}
-
-static ssize_t
-lgetxattr(const char *path, const char *name, void *value, size_t size)
-{
- return SYSCALL(__NR_lgetxattr, path, name, value, size);
-}
-
-static ssize_t
-llistxattr(const char *path, char *list, size_t size)
-{
- return SYSCALL(__NR_llistxattr, path, list, size);
-}
-
#define POSIX_ACL_XATTR_VERSION 0x0002
#define ACL_UNDEFINED_ID (-1)
--
2.20.1

View File

@ -1,14 +1,6 @@
diff -urNp a/common/dumprmt.c b/common/dumprmt.c diff -urNp a/common/dumprmt.c b/common/dumprmt.c
--- a/common/dumprmt.c 2021-02-08 13:23:33.366826516 +0100 --- a/common/dumprmt.c 2021-02-08 13:23:33.366826516 +0100
+++ b/common/dumprmt.c 2021-02-08 13:26:13.725243819 +0100 +++ b/common/dumprmt.c 2021-02-08 13:26:13.725243819 +0100
@@ -83,7 +83,6 @@
#endif
#include <pathnames.h>
-#include "dump.h" /* for X_STARTUP, X_ABORT etc */
#define TS_CLOSED 0
#define TS_OPEN 1
@@ -150,7 +149,7 @@ rmtconnaborted(UNUSED(int signo)) @@ -150,7 +149,7 @@ rmtconnaborted(UNUSED(int signo))
} }
} }

View File

@ -12,8 +12,8 @@ Name: dump
%endif %endif
Epoch: 1 Epoch: 1
Version: 0.4 Version: 0.4
Release: 0.51.%{PREVER}%{?dist} Release: 0.59.%{PREVER}%{?dist}
License: BSD License: BSD-3-Clause
URL: https://sourceforge.net/projects/dump/ URL: https://sourceforge.net/projects/dump/
Source: http://downloads.sourceforge.net/dump/dump-%{DUMP_VERSION}.tar.gz Source: http://downloads.sourceforge.net/dump/dump-%{DUMP_VERSION}.tar.gz
BuildRequires: e2fsprogs-devel >= 1.18, readline-devel >= 4.2 BuildRequires: e2fsprogs-devel >= 1.18, readline-devel >= 4.2
@ -34,10 +34,10 @@ Patch0: dump-buildfix.patch
Patch1: dump-remove-lzo.patch Patch1: dump-remove-lzo.patch
Patch2: dump-apath.patch Patch2: dump-apath.patch
%if 0%{?rhel}
# No dump package in RHEL (restore remains) # No dump package in RHEL (restore remains)
Patch101: dump-replacement.patch Patch101: dump-replacement.patch
%if 0%{?rhel}
%description %description
The restore command performs the inverse function of dump; it can The restore command performs the inverse function of dump; it can
restore a full backup of a filesystem. Subsequent incremental backups restore a full backup of a filesystem. Subsequent incremental backups
@ -63,13 +63,13 @@ restoring filesystems after backups.
%prep %prep
%setup -q -n dump-%{DUMP_VERSION} %setup -q -n dump-%{DUMP_VERSION}
%patch0 -p1 -b .buildfix %patch 0 -p1 -b .buildfix
%patch1 -p1 -b .remove-lzo %patch 1 -p1 -b .remove-lzo
%patch2 -p1 -b .apath %patch 2 -p1 -b .apath
%if 0%{?rhel} %if 0%{?rhel}
rm -rf dump rm -rf dump/*.c
%patch101 -p1 %patch 101 -p1
%endif %endif
%build %build
@ -131,11 +131,43 @@ popd
%{_mandir}/man8/rrestore.8* %{_mandir}/man8/rrestore.8*
%changelog %changelog
* Tue Aug 17 2021 Josef Ridky <jridky@redhat.com> - 1:0.4-0.51.b47 * Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 1:0.4-0.59.b47
- rename spec file to restore - Bump release for October 2024 mass rebuild:
- add gating.yaml Resolves: RHEL-64018
- changes between .47 and .51 had to be stripped due of wrong sync
between centos and dist-git * Wed Jun 26 2024 Josef Ridky <jridky@redhat.com> - 1:0.4-0.58.b47
- Add gating.yaml file
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 1:0.4-0.57.b47
- Bump release for June 2024 mass rebuild
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.56.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.55.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Mon Oct 16 2023 Stephen Gallagher <sgallagh@redhat.com> - 1:0.4-0.54.b47
- Fixes for -WError=implicit-function-declaration on RHEL
- Reinstates the dump headers without compiling the implementations
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.53.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Tue May 02 2023 Josef Ridky <jridky@redhat.com> - 1:0.4-0.52.b47
- move to SPDX license format
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.51.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.50.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.49.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1:0.4-0.48.b47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Wed Feb 10 2021 Josef Ridky <jridky@redhat.com> - 1:0.4-0.47.b47 * Wed Feb 10 2021 Josef Ridky <jridky@redhat.com> - 1:0.4-0.47.b47
- remove dump from RHEL environment - remove dump from RHEL environment

7
gating.yaml Normal file
View File

@ -0,0 +1,7 @@
--- !Policy
product_versions:
- rhel-10
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

37
plans/tier1.fmf Normal file
View File

@ -0,0 +1,37 @@
---
summary: Tier1 plan for restore
discover:
how: fmf
url: https://pkgs.devel.redhat.com/git/tests/restore
ref: master
filter: tier:1
prepare:
# Enable beaker-tasks repository
- how: shell
script: |
set -euxo pipefail
ENABLE_REPO_CMD="yum-config-manager --enable"
if command -v dnf >/dev/null 2>&1; then
ENABLE_REPO_CMD="dnf config-manager --set-enabled"
fi
${ENABLE_REPO_CMD} beaker-tasks || :
# Enable buildroot repository
- how: shell
script: |
set -exuo pipefail
if [[ -f /etc/os-release ]]; then
. /etc/os-release
if [[ "${ID:-}" == "rhel" && "${VERSION_ID%%.*}" -ge 8 ]]; then
dnf config-manager --enable rhel-CRB
fi
fi
execute:
how: tmt

1
sources Normal file
View File

@ -0,0 +1 @@
SHA512 (dump-0.4b47.tar.gz) = e9c567fe2ffad196b9657c551d83f7607758f3704cad6cb407514bbe2bc765c16968997dc3a5bc92b9eb5900fa5bd6e7cebc92c81afff53339fca92891a5259d