Fix FTBFS in Rawhide
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
This commit is contained in:
parent
9b29002ab7
commit
4c68cb8651
18
fuse.spec
18
fuse.spec
@ -1,6 +1,6 @@
|
||||
Name: fuse
|
||||
Version: 2.9.9
|
||||
Release: 12%{?dist}
|
||||
Release: 13%{?dist}
|
||||
Summary: File System in Userspace (FUSE) v2 utilities
|
||||
License: GPL+
|
||||
URL: http://fuse.sf.net
|
||||
@ -16,6 +16,13 @@ Patch3: fuse2-0003-make-buffer-size-match-kernel-max-transfer-size.patch
|
||||
# https://github.com/libfuse/libfuse/pull/392
|
||||
# backported for fuse2
|
||||
Patch4: fuse2-0004-Whitelist-SMB2-found-on-some-NAS-devices.patch
|
||||
# cherry-picked from upstream
|
||||
Patch5: fuse2-0005-Whitelist-UFSD-backport-to-2.9-branch-452.patch
|
||||
# cherry-picked from upstream
|
||||
Patch6: fuse2-0006-Correct-errno-comparison-571.patch
|
||||
# cherry-picked from upstream
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1984776
|
||||
Patch7: fuse2-0007-util-ulockmgr_server.c-conditionally-define-closefro.patch
|
||||
|
||||
Requires: which
|
||||
Conflicts: filesystem < 3
|
||||
@ -52,15 +59,11 @@ userspace program. This package contains development files (headers,
|
||||
pgk-config) to develop FUSE v2 based applications/filesystems.
|
||||
|
||||
%prep
|
||||
%setup
|
||||
%autosetup -p 1
|
||||
|
||||
# ./makeconf.sh
|
||||
#disable device creation during build/install
|
||||
sed -i 's|mknod|echo Disabled: mknod |g' util/Makefile.in
|
||||
%patch1 -p1 -b .add_parentheses
|
||||
%patch2 -p1 -b .conflictfix
|
||||
%patch3 -p1 -b .buffer_size
|
||||
%patch4 -p1 -b .smb2_whitelist
|
||||
|
||||
%build
|
||||
# Can't pass --disable-static here, or else the utils don't build
|
||||
@ -123,6 +126,9 @@ rm -f %{buildroot}/%{_libdir}/*.a
|
||||
%{_includedir}/fuse
|
||||
|
||||
%changelog
|
||||
* Tue Jul 27 2021 Peter Lemenkov <lemenkov@gmail.com> - 2.9.9-13
|
||||
- Fix FTBFS in Rawhide (rhbz#1984776)
|
||||
|
||||
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.9.9-12
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||
|
||||
|
31
fuse2-0005-Whitelist-UFSD-backport-to-2.9-branch-452.patch
Normal file
31
fuse2-0005-Whitelist-UFSD-backport-to-2.9-branch-452.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From: tenzap <46226844+tenzap@users.noreply.github.com>
|
||||
Date: Sun, 15 Sep 2019 17:57:08 +0200
|
||||
Subject: [PATCH] Whitelist UFSD (backport to 2.9 branch) (#452)
|
||||
|
||||
|
||||
diff --git a/ChangeLog b/ChangeLog
|
||||
index 13a369f..5574f20 100644
|
||||
--- a/ChangeLog
|
||||
+++ b/ChangeLog
|
||||
@@ -1,3 +1,9 @@
|
||||
+Unreleased Changes
|
||||
+==================
|
||||
+
|
||||
+* Added UFSD to whitelist (so users can now mount FUSE filesystems
|
||||
+ on mountpoints within UFSD filesystems).
|
||||
+
|
||||
FUSE 2.9.9 (2019-01-04)
|
||||
=======================
|
||||
|
||||
diff --git a/util/fusermount.c b/util/fusermount.c
|
||||
index ef9d1ed..63a69dc 100644
|
||||
--- a/util/fusermount.c
|
||||
+++ b/util/fusermount.c
|
||||
@@ -1050,6 +1050,7 @@ static int check_perm(const char **mntp, struct stat *stbuf, int *mountpoint_fd)
|
||||
0x73717368 /* SQUASHFS_MAGIC */,
|
||||
0x01021994 /* TMPFS_MAGIC */,
|
||||
0x24051905 /* UBIFS_SUPER_MAGIC */,
|
||||
+ 0x736675005346544e /* UFSD */,
|
||||
0x58465342 /* XFS_SB_MAGIC */,
|
||||
0x2FC12FC1 /* ZFS_SUPER_MAGIC */,
|
||||
};
|
18
fuse2-0006-Correct-errno-comparison-571.patch
Normal file
18
fuse2-0006-Correct-errno-comparison-571.patch
Normal file
@ -0,0 +1,18 @@
|
||||
From: Andrew Gaul <gaul@google.com>
|
||||
Date: Mon, 14 Dec 2020 19:16:05 +0900
|
||||
Subject: [PATCH] Correct errno comparison (#571)
|
||||
|
||||
|
||||
diff --git a/lib/fuse.c b/lib/fuse.c
|
||||
index ca1709c..896aa24 100644
|
||||
--- a/lib/fuse.c
|
||||
+++ b/lib/fuse.c
|
||||
@@ -4348,7 +4348,7 @@ static int fuse_session_loop_remember(struct fuse *f)
|
||||
|
||||
res = poll(&fds, 1, timeout * 1000);
|
||||
if (res == -1) {
|
||||
- if (errno == -EINTR)
|
||||
+ if (errno == EINTR)
|
||||
continue;
|
||||
else
|
||||
break;
|
@ -0,0 +1,55 @@
|
||||
From: Sam James <sam@gentoo.org>
|
||||
Date: Sat, 24 Jul 2021 22:02:45 +0100
|
||||
Subject: [PATCH] util/ulockmgr_server.c: conditionally define closefrom (fix
|
||||
glibc-2.34+)
|
||||
|
||||
closefrom(3) has joined us in glibc-land from *BSD and Solaris. Since
|
||||
it's available in glibc 2.34+, we want to detect it and only define our
|
||||
fallback if the libc doesn't provide it.
|
||||
|
||||
Bug: https://bugs.gentoo.org/803923
|
||||
Signed-off-by: Sam James <sam@gentoo.org>
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 9946a0e..a2d481a 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -55,6 +55,7 @@ fi
|
||||
|
||||
AC_CHECK_FUNCS([fork setxattr fdatasync splice vmsplice utimensat])
|
||||
AC_CHECK_FUNCS([posix_fallocate])
|
||||
+AC_CHECK_FUNCS([closefrom])
|
||||
AC_CHECK_MEMBERS([struct stat.st_atim])
|
||||
AC_CHECK_MEMBERS([struct stat.st_atimespec])
|
||||
|
||||
diff --git a/util/ulockmgr_server.c b/util/ulockmgr_server.c
|
||||
index 273c7d9..a04dac5 100644
|
||||
--- a/util/ulockmgr_server.c
|
||||
+++ b/util/ulockmgr_server.c
|
||||
@@ -22,6 +22,10 @@
|
||||
#include <sys/socket.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
+#ifdef HAVE_CONFIG_H
|
||||
+ #include "config.h"
|
||||
+#endif
|
||||
+
|
||||
struct message {
|
||||
unsigned intr : 1;
|
||||
unsigned nofd : 1;
|
||||
@@ -124,6 +128,7 @@ static int receive_message(int sock, void *buf, size_t buflen, int *fdp,
|
||||
return res;
|
||||
}
|
||||
|
||||
+#if !defined(HAVE_CLOSEFROM)
|
||||
static int closefrom(int minfd)
|
||||
{
|
||||
DIR *dir = opendir("/proc/self/fd");
|
||||
@@ -141,6 +146,7 @@ static int closefrom(int minfd)
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
+#endif
|
||||
|
||||
static void send_reply(int cfd, struct message *msg)
|
||||
{
|
Loading…
Reference in New Issue
Block a user