summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--filesystems/fuse-httpfs/Makefile4
-rw-r--r--filesystems/fuse-httpfs/distinfo4
-rw-r--r--filesystems/fuse-httpfs/patches/patch-aa79
-rw-r--r--filesystems/fuse-obexfs/Makefile8
-rw-r--r--filesystems/fuse-obexfs/distinfo4
-rw-r--r--filesystems/fuse-obexfs/patches/patch-aa29
-rw-r--r--filesystems/fuse-pod/Makefile5
-rw-r--r--filesystems/fuse-pod/distinfo4
-rw-r--r--filesystems/fuse-pod/patches/patch-aa16
-rw-r--r--filesystems/fuse-sshfs/Makefile4
-rw-r--r--filesystems/fuse-sshfs/distinfo7
-rw-r--r--filesystems/fuse-sshfs/patches/patch-cache.c36
-rw-r--r--filesystems/fuse-sshfs/patches/patch-meson.build19
-rw-r--r--filesystems/fuse-sshfs/patches/patch-sshfs.c117
-rw-r--r--filesystems/fuse-wdfs/Makefile5
-rw-r--r--filesystems/fuse-wdfs/distinfo4
-rw-r--r--filesystems/fuse-wdfs/patches/patch-aa43
17 files changed, 212 insertions, 176 deletions
diff --git a/filesystems/fuse-httpfs/Makefile b/filesystems/fuse-httpfs/Makefile
index 184671a2bef..091bb29d0bf 100644
--- a/filesystems/fuse-httpfs/Makefile
+++ b/filesystems/fuse-httpfs/Makefile
@@ -1,14 +1,16 @@
-# $NetBSD: Makefile,v 1.4 2012/10/03 16:08:32 asau Exp $
+# $NetBSD: Makefile,v 1.5 2022/01/22 18:41:21 pho Exp $
#
DISTNAME= httpfs_with_static_binaries_${DIST_VER}
PKGNAME= fuse-httpfs-${DIST_VER}
+PKGREVISION= 1
CATEGORIES= filesystems
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=httpfs/}
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://httpfs.sourceforge.net/
COMMENT= FUSE HTTP filesystem
+LICENSE= gnu-gpl-v2
DIST_VER= 2.06.08.26
diff --git a/filesystems/fuse-httpfs/distinfo b/filesystems/fuse-httpfs/distinfo
index 4fe7de7a400..32a1f0e154b 100644
--- a/filesystems/fuse-httpfs/distinfo
+++ b/filesystems/fuse-httpfs/distinfo
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.5 2021/10/26 10:25:27 nia Exp $
+$NetBSD: distinfo,v 1.6 2022/01/22 18:41:21 pho Exp $
BLAKE2s (httpfs_with_static_binaries_2.06.08.26.tar.gz) = 92ffd4710d5d14a13eb94799df2ec2b8ead531dacc80c2af6e81a007388c3e87
SHA512 (httpfs_with_static_binaries_2.06.08.26.tar.gz) = 49620221d7dac0e831670666772d35f63e3a153d1fb75156f1825d72b158a1492eed7f4db3441807aec4a7fa86408d05f1adef03b8075d0889a7d8f685676fd2
Size (httpfs_with_static_binaries_2.06.08.26.tar.gz) = 115384 bytes
-SHA1 (patch-aa) = 6dc82d997847f2bb5e6618f59736d5bee5d97eb1
+SHA1 (patch-aa) = 2e3932c89211268cfe6ec696c8b3f9013813e3e6
diff --git a/filesystems/fuse-httpfs/patches/patch-aa b/filesystems/fuse-httpfs/patches/patch-aa
index 4cff32d7cc2..6b25836f829 100644
--- a/filesystems/fuse-httpfs/patches/patch-aa
+++ b/filesystems/fuse-httpfs/patches/patch-aa
@@ -1,6 +1,21 @@
-$NetBSD: patch-aa,v 1.1 2009/08/03 13:50:39 joerg Exp $
+$NetBSD: patch-aa,v 1.2 2022/01/22 18:41:21 pho Exp $
---- httpfs.c.orig 2009-08-03 15:46:22.000000000 +0200
+Hunk #0:
+ Be explicit about the API version it wants to use.
+
+Hunk #1, #2, #3, #5:
+ httpfs performs a weird hack that obtains a reference to the
+ directory it is going to be mounted on, and then tries to call
+ statvfs(2) and opendir(3) on that directory in respective
+ filesystem callbacks. On Linux this can somehow avoid deadlocks it
+ seems (possibly due to the way how Linux vfs is implemented?), but
+ on NetBSD it can't. Don't try to do that.
+
+Hunk #4:
+ Workaround for NetBSD librefuse that had an API incompatible with
+ FUSE. Already fixed in HEAD.
+
+--- httpfs.c.orig 2006-08-26 06:29:28.000000000 +0000
+++ httpfs.c
@@ -1,3 +1,5 @@
+#define FUSE_USE_VERSION 25
@@ -8,12 +23,66 @@ $NetBSD: patch-aa,v 1.1 2009/08/03 13:50:39 joerg Exp $
/*
* HTTPFS: import a file from a web server to local file system
* the main use is, to mount an iso on a web server with loop device
-@@ -802,7 +804,7 @@ static int httpfs_fsync(const char *path
+@@ -550,6 +552,9 @@ static int httpfs_readlink(const char *p
+
+ static int httpfs_readdir(const char *path, void *buf, fuse_fill_dir_t filler,
+ off_t offset, struct fuse_file_info *fi) {
++#if defined(__NetBSD__)
++ filler(buf, httpfs_path + 1, NULL, 0);
++#else
+ DIR *dp;
+ struct dirent *de;
+ (void) offset;
+@@ -574,6 +579,7 @@ static int httpfs_readdir(const char *pa
+ }
+
+ closedir(dp);
++#endif
+
+ return 0;
+ }
+@@ -778,11 +784,15 @@ static int httpfs_statfs(const char *pat
+ int res;
+ (void) path;
+
++#if defined(__NetBSD__)
++ return -ENOSYS;
++#else
+ res = statvfs(".", stbuf);
+ if (res == -1)
+ return -errno;
+
return 0;
++#endif
}
--static void *httpfs_init(void) {
-+static void *httpfs_init(struct fuse_conn_info *arg) {
+ static int httpfs_release(const char *path, struct fuse_file_info *fi) {
+@@ -802,7 +812,11 @@ static int httpfs_fsync(const char *path
+ return 0;
+ }
+
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
++static void *httpfs_init(struct fuse_conn_info *conn) {
++#else
+ static void *httpfs_init(void) {
++#endif
fchdir(targetFd); /* that's the catch */
return NULL;
}
+@@ -924,11 +938,15 @@ int main(int argc, char *argv[]) {
+ (void) fprintf(stderr, "%s: %s is not a directory\n", argv0, argv2);
+ return 1;
+ }
+-
++
++#if defined(__NetBSD__)
++ targetFd = open("/", 0); /* Unused */
++#else
+ if ((targetFd = open(argv2, 0)) == -1) {
+ (void) fprintf(stderr, "%s: open %s failed\n", argv0, argv2);
+ return 1;
+ }
++#endif
+
+ ri = rindex(file_name, '/');
+ if (ri == (char *) 0) {
diff --git a/filesystems/fuse-obexfs/Makefile b/filesystems/fuse-obexfs/Makefile
index ebce4890923..c23bfd65b64 100644
--- a/filesystems/fuse-obexfs/Makefile
+++ b/filesystems/fuse-obexfs/Makefile
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.9 2017/08/01 16:47:38 wiz Exp $
+# $NetBSD: Makefile,v 1.10 2022/01/22 18:43:19 pho Exp $
#
DISTNAME= obexfs-0.8
PKGNAME= fuse-${DISTNAME}
-PKGREVISION= 1
+PKGREVISION= 2
CATEGORIES= filesystems
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=openobex/}
@@ -15,10 +15,6 @@ LICENSE= gnu-gpl-v2
GNU_CONFIGURE= yes
USE_TOOLS+= autoconf gmake pkg-config
-CPPFLAGS.NetBSD+= -D_KERNTYPES
-
-BUILDLINK_API_DEPENDS.openobex+= openobex>=1.3nb2
-
pre-configure:
cd ${WRKSRC} && autoconf
diff --git a/filesystems/fuse-obexfs/distinfo b/filesystems/fuse-obexfs/distinfo
index d6ee3daedef..af1c183d108 100644
--- a/filesystems/fuse-obexfs/distinfo
+++ b/filesystems/fuse-obexfs/distinfo
@@ -1,8 +1,8 @@
-$NetBSD: distinfo,v 1.5 2021/10/26 10:25:28 nia Exp $
+$NetBSD: distinfo,v 1.6 2022/01/22 18:43:19 pho Exp $
BLAKE2s (obexfs-0.8.tar.gz) = f8e0463c0199df63e4c5111e3b947e56a594f159b2eea75e9f79ff82efb1472a
SHA512 (obexfs-0.8.tar.gz) = 3fdca66b52315c8d119dd7ee3f48e974cc3b0834531dd99f8cdd61b8d7558a9899e4f25fef29461d5a9fc8c9dd1fdaccbf8af43521d75ddd413a45f48a26a73d
Size (obexfs-0.8.tar.gz) = 76393 bytes
-SHA1 (patch-aa) = beef802678c5839fe37fa84288bb545934001ef2
+SHA1 (patch-aa) = 2e607af6ee2cd4a57091e4cce9ca799ca0fd5dcf
SHA1 (patch-ab) = 63936898afa0cbf1c2e972d9aef9a6681de65f20
SHA1 (patch-ac) = 42a1f77900e49f7e3afc9b3e935d66443b92ad69
diff --git a/filesystems/fuse-obexfs/patches/patch-aa b/filesystems/fuse-obexfs/patches/patch-aa
index 0e130cb2e15..56f1b6fa058 100644
--- a/filesystems/fuse-obexfs/patches/patch-aa
+++ b/filesystems/fuse-obexfs/patches/patch-aa
@@ -1,16 +1,27 @@
-$NetBSD: patch-aa,v 1.2 2007/05/16 11:02:12 xtraeme Exp $
+$NetBSD: patch-aa,v 1.3 2022/01/22 18:43:20 pho Exp $
---- fuse/obexfs.c.orig 2006-01-19 15:46:43.000000000 +0100
-+++ fuse/obexfs.c 2007-05-16 12:52:58.000000000 +0200
-@@ -26,6 +26,8 @@
+* Use the correct API version: opendir() appeared on FUSE 2.3, not
+ 2.2.
+
+* Work around an API incompatibility in the past versions of NetBSD
+ librefuse: it had a wrong prototype for the callback
+ statfs(). Already fixed in HEAD.
+
+--- fuse/obexfs.c.orig 2006-01-19 14:46:43.000000000 +0000
++++ fuse/obexfs.c
+@@ -26,8 +26,10 @@
/* strndup */
#define _GNU_SOURCE
+-/* at least fuse v 2.2 is needed */
+-#define FUSE_USE_VERSION 22
+#include "config.h"
+
- /* at least fuse v 2.2 is needed */
- #define FUSE_USE_VERSION 22
++/* at least fuse v 2.3 is needed */
++#define FUSE_USE_VERSION 23
#include <fuse.h>
+ #include <stdio.h>
+ #include <stdlib.h>
@@ -37,7 +39,11 @@
#include <fcntl.h>
#include <dirent.h>
@@ -31,11 +42,11 @@ $NetBSD: patch-aa,v 1.2 2007/05/16 11:02:12 xtraeme Exp $
#ifdef DEBUGOUPUT
#define DEBUG(...) fprintf(stderr, __VA_ARGS__)
#else
-@@ -412,12 +417,20 @@
+@@ -412,12 +417,20 @@ static int ofs_release(const char *path,
return 0;
}
-+#if HAVE_SYS_STATVFS_H
++#if HAVE_SYS_STATVFS_H && defined(__NetBSD__) && FUSE_H_ < 20211204
+static int ofs_statfs(const char *UNUSED(label), struct statvfs *st)
+#else
static int ofs_statfs(const char *UNUSED(label), struct statfs *st)
@@ -44,7 +55,7 @@ $NetBSD: patch-aa,v 1.2 2007/05/16 11:02:12 xtraeme Exp $
int res;
int size, free;
-+#if HAVE_SYS_STATVFS_H
++#if HAVE_SYS_STATVFS_H && defined(__NetBSD__) && FUSE_H_ < 20211204
+ memset(st, 0, sizeof(struct statvfs));
+#else
memset(st, 0, sizeof(struct statfs));
diff --git a/filesystems/fuse-pod/Makefile b/filesystems/fuse-pod/Makefile
index 3d8aeb8b2e9..3c21fe671f8 100644
--- a/filesystems/fuse-pod/Makefile
+++ b/filesystems/fuse-pod/Makefile
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.43 2021/12/08 16:04:21 adam Exp $
+# $NetBSD: Makefile,v 1.44 2022/01/22 18:45:13 pho Exp $
#
DISTNAME= fusepod-0.5.1
PKGNAME= fuse-pod-0.5.1
-PKGREVISION= 37
+PKGREVISION= 38
CATEGORIES= filesystems
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=fusepod/}
EXTRACT_SUFX= .tar.bz2
@@ -11,6 +11,7 @@ EXTRACT_SUFX= .tar.bz2
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://fusepod.sourceforge.net/
COMMENT= FUSE-based filesystem for iPod
+LICENSE= gnu-gpl-v2
GNU_CONFIGURE= yes
USE_LANGUAGES+= c c++03
diff --git a/filesystems/fuse-pod/distinfo b/filesystems/fuse-pod/distinfo
index 41f48c4f073..d6547e18cf7 100644
--- a/filesystems/fuse-pod/distinfo
+++ b/filesystems/fuse-pod/distinfo
@@ -1,8 +1,8 @@
-$NetBSD: distinfo,v 1.5 2021/10/26 10:25:28 nia Exp $
+$NetBSD: distinfo,v 1.6 2022/01/22 18:45:13 pho Exp $
BLAKE2s (fusepod-0.5.1.tar.bz2) = 761fcac8d17829efc153b43e1b38337a346c3f48e0219a0a00f6870bf65ffcf6
SHA512 (fusepod-0.5.1.tar.bz2) = 3a4d526bdd2cd7f2cc28458898399fc2c50aca989a19d2bc2d9921eaf841195eaa0f9f6a86ac5ebccc8ab56117464a64081e510afef1456817297eebcd7465f8
Size (fusepod-0.5.1.tar.bz2) = 78547 bytes
-SHA1 (patch-aa) = cb2aceb2aefaa8b99dc95fce70835edb85ab1a92
+SHA1 (patch-aa) = a2897d44503c6018c7aec02773a0aeee307197ea
SHA1 (patch-ab) = 923f7f7449c85d2ea537845b779aebec6aede1e8
SHA1 (patch-src_fusepod__util.h) = 71485be8dfdecc1f2be61d1c5c08ac9d3447c0c5
diff --git a/filesystems/fuse-pod/patches/patch-aa b/filesystems/fuse-pod/patches/patch-aa
index b6df182b917..04916361f23 100644
--- a/filesystems/fuse-pod/patches/patch-aa
+++ b/filesystems/fuse-pod/patches/patch-aa
@@ -1,13 +1,19 @@
-$NetBSD: patch-aa,v 1.1.1.1 2007/05/04 23:48:33 agc Exp $
+$NetBSD: patch-aa,v 1.2 2022/01/22 18:45:13 pho Exp $
---- src/fusepod.cpp 2007/05/04 23:21:09 1.1
-+++ src/fusepod.cpp 2007/05/04 23:23:52
-@@ -672,7 +672,7 @@
+NetBSD librefuse used to have a wrong prototype for init() in FUSE 2.5
+API. Already fixed in HEAD.
+
+--- src/fusepod.cpp.orig 2006-08-07 14:39:18.000000000 +0000
++++ src/fusepod.cpp
+@@ -672,7 +672,11 @@ static vector<string> get_string_desc ()
return paths;
}
--void * fusepod_init () {
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+void * fusepod_init (fuse_conn_info *connection) {
++#else
+ void * fusepod_init () {
++#endif
syncing = false;
syncing_file = "";
diff --git a/filesystems/fuse-sshfs/Makefile b/filesystems/fuse-sshfs/Makefile
index 5e9b507e5c3..3a780ed7f88 100644
--- a/filesystems/fuse-sshfs/Makefile
+++ b/filesystems/fuse-sshfs/Makefile
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.6 2021/12/20 07:09:07 nia Exp $
+# $NetBSD: Makefile,v 1.7 2022/01/22 18:48:04 pho Exp $
#
DISTNAME= sshfs-3.7.2
PKGNAME= fuse-${DISTNAME}
-PKGREVISION= 1
+PKGREVISION= 2
CATEGORIES= filesystems
MASTER_SITES= ${MASTER_SITE_GITHUB:=libfuse/}
GITHUB_PROJECT= sshfs
diff --git a/filesystems/fuse-sshfs/distinfo b/filesystems/fuse-sshfs/distinfo
index 763ec2be66d..ea1c8abbe93 100644
--- a/filesystems/fuse-sshfs/distinfo
+++ b/filesystems/fuse-sshfs/distinfo
@@ -1,9 +1,8 @@
-$NetBSD: distinfo,v 1.5 2021/12/02 07:28:40 pho Exp $
+$NetBSD: distinfo,v 1.6 2022/01/22 18:48:04 pho Exp $
BLAKE2s (sshfs-3.7.2.tar.xz) = a770780be6c0d5b26ebb9b7b43c35c8a689e226a619f03cdaee847598c81d025
SHA512 (sshfs-3.7.2.tar.xz) = 1612d515869a8b38c0bc3d79eaf80e8b4da1a9710c9668e6ec23e6b77313063ae0bee66ab9e9e0f70d98eaa1334425b2087dd93cc4618af3ac6ac191acf7f838
Size (sshfs-3.7.2.tar.xz) = 53160 bytes
-SHA1 (patch-cache.c) = 9a089852ab3ad77d2b77c4323c5d65ed9f05036a
-SHA1 (patch-meson.build) = dd9549c3d099a4137089757bd743c8c0bbb63b35
-SHA1 (patch-sshfs.c) = 4f06a3c945de2f4b3b8e5935b28c6fca0d50a355
+SHA1 (patch-cache.c) = 570525d7cae09055537b00e3eeadb639c6f1fa5b
+SHA1 (patch-sshfs.c) = 95e0b5bf01c36b803d1ea0c3b71b8740be98506b
SHA1 (patch-utils_install__helper.sh) = 7e31f031ecf40731acb4a96b0c23543b7015c290
diff --git a/filesystems/fuse-sshfs/patches/patch-cache.c b/filesystems/fuse-sshfs/patches/patch-cache.c
index 5f0221c8faf..7bf94bd15bc 100644
--- a/filesystems/fuse-sshfs/patches/patch-cache.c
+++ b/filesystems/fuse-sshfs/patches/patch-cache.c
@@ -1,10 +1,8 @@
-$NetBSD: patch-cache.c,v 1.1 2021/12/02 07:28:40 pho Exp $
+$NetBSD: patch-cache.c,v 1.2 2022/01/22 18:48:04 pho Exp $
-Impedance adjustment with librefuse. Never send this to the
-upstream. It's our code that needs to be fixed, not theirs!
-
-TODO: This patch should *really* be gone, except for one thing (see
-comments). Update librefuse.
+Impedance adjustment with librefuse which used to provide an old API
+incompatible with FUSE 3.1. This patch can go away when NetBSD 9
+reaches its EOL, except for one thing (see comments).
--- cache.c.orig 2021-06-08 08:52:08.000000000 +0000
+++ cache.c
@@ -12,7 +10,7 @@ comments). Update librefuse.
return res;
}
-+#if defined(__NetBSD__) && FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static void *cache_init(struct fuse_conn_info *conn __attribute__((__unused__)))
+{
+ return cache.next_oper->init(NULL);
@@ -27,7 +25,7 @@ comments). Update librefuse.
}
+#endif
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_getattr(const char *path, struct stat *stbuf)
+#else
static int cache_getattr(const char *path, struct stat *stbuf,
@@ -37,7 +35,7 @@ comments). Update librefuse.
int err = cache_get_attr(path, stbuf);
if (err) {
uint64_t wrctr = cache_get_write_ctr();
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ err = cache.next_oper->getattr(path, stbuf);
+#else
err = cache.next_oper->getattr(path, stbuf, fi);
@@ -49,7 +47,7 @@ comments). Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_dirfill (void *buf, const char *name,
+ const struct stat *stbuf, off_t off)
+#else
@@ -62,7 +60,7 @@ comments). Update librefuse.
struct readdir_handle *ch;
ch = (struct readdir_handle*) buf;
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ err = ch->filler(ch->buf, name, stbuf, off);
+#else
err = ch->filler(ch->buf, name, stbuf, off, flags);
@@ -74,7 +72,7 @@ comments). Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_readdir(const char *path, void *buf, fuse_fill_dir_t filler,
+ off_t offset, struct fuse_file_info *fi)
+#else
@@ -89,7 +87,7 @@ comments). Update librefuse.
if (node->dir_valid - now >= 0) {
for(dir = node->dir; *dir != NULL; dir++)
// FIXME: What about st_mode?
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ filler(buf, *dir, NULL, 0);
+#else
filler(buf, *dir, NULL, 0, 0);
@@ -101,7 +99,7 @@ comments). Update librefuse.
ch.filler = filler;
ch.dir = g_ptr_array_new();
ch.wrctr = cache_get_write_ctr();
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ err = cache.next_oper->readdir(path, &ch, cache_dirfill, offset, fi);
+#else
err = cache.next_oper->readdir(path, &ch, cache_dirfill, offset, fi, flags);
@@ -121,7 +119,7 @@ comments). Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_rename(const char *from, const char *to)
+{
+ int err = cache.next_oper->rename(from, to);
@@ -145,7 +143,7 @@ comments). Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_chmod(const char *path, mode_t mode)
+{
+ int err = cache.next_oper->chmod(path, mode);
@@ -163,7 +161,7 @@ comments). Update librefuse.
}
+#endif
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_chown(const char *path, uid_t uid, gid_t gid)
+{
+ int err = cache.next_oper->chown(path, uid, gid);
@@ -181,7 +179,7 @@ comments). Update librefuse.
}
+#endif
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_utimens(const char *path, const struct timespec tv[2])
+{
+ int err = cache.next_oper->utimens(path, tv);
@@ -205,7 +203,7 @@ comments). Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int cache_truncate(const char *path, off_t size)
+{
+ int err = cache.next_oper->truncate(path, size);
diff --git a/filesystems/fuse-sshfs/patches/patch-meson.build b/filesystems/fuse-sshfs/patches/patch-meson.build
deleted file mode 100644
index fa753175f87..00000000000
--- a/filesystems/fuse-sshfs/patches/patch-meson.build
+++ /dev/null
@@ -1,19 +0,0 @@
-$NetBSD: patch-meson.build,v 1.1 2021/12/02 07:28:40 pho Exp $
-
-Impedance adjustment with librefuse. Never send this to the
-upstream. It's our code that needs to be fixed, not theirs!
-
-TODO: This patch should *really* be gone. Update librefuse.
-
---- meson.build.orig 2021-12-01 17:06:20.555815467 +0000
-+++ meson.build
-@@ -44,7 +44,8 @@ endif
- configure_file(output: 'config.h',
- configuration : cfg)
-
--sshfs_deps = [ dependency('fuse3', version: '>= 3.1.0'),
-+sshfs_deps = [ dependency('fuse3', version: '>= 3.1.0', required: false),
-+ dependency('fuse' , version: '>= 2.6.0', required: false),
- dependency('glib-2.0'),
- dependency('gthread-2.0') ]
-
diff --git a/filesystems/fuse-sshfs/patches/patch-sshfs.c b/filesystems/fuse-sshfs/patches/patch-sshfs.c
index 6c14b656114..9ca06ad1223 100644
--- a/filesystems/fuse-sshfs/patches/patch-sshfs.c
+++ b/filesystems/fuse-sshfs/patches/patch-sshfs.c
@@ -1,9 +1,8 @@
-$NetBSD: patch-sshfs.c,v 1.1 2021/12/02 07:28:40 pho Exp $
+$NetBSD: patch-sshfs.c,v 1.2 2022/01/22 18:48:04 pho Exp $
-Impedance adjustment with librefuse. Never send this to the
-upstream. It's our code that needs to be fixed, not theirs!
-
-TODO: This patch should *really* be gone. Update librefuse.
+Impedance adjustment with librefuse which used to provide an old API
+incompatible with FUSE 3.1. This patch can go away when NetBSD 9
+reaches its EOL.
--- sshfs.c.orig 2021-06-08 08:52:08.000000000 +0000
+++ sshfs.c
@@ -11,7 +10,7 @@ TODO: This patch should *really* be gone. Update librefuse.
S_ISLNK(stbuf.st_mode)) {
stbuf.st_mode = 0;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ filler(dbuf, name, &stbuf, 0);
+#else
filler(dbuf, name, &stbuf, 0, 0);
@@ -23,7 +22,7 @@ TODO: This patch should *really* be gone. Update librefuse.
return 0;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static void *sshfs_init(struct fuse_conn_info *conn __attribute__((__unused__)))
+{
+ sshfs.sync_read = 1;
@@ -53,7 +52,7 @@ TODO: This patch should *really* be gone. Update librefuse.
int err = 0;
if (mask & X_OK) {
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ err = sshfs.op->getattr(path, &stbuf);
+#else
err = sshfs.op->getattr(path, &stbuf, NULL);
@@ -66,7 +65,7 @@ TODO: This patch should *really* be gone. Update librefuse.
}
-static int sshfs_readdir(const char *path, void *dbuf, fuse_fill_dir_t filler,
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_readdir(const char *path __attribute__((__unused__)), void *dbuf, fuse_fill_dir_t filler,
+ off_t offset, struct fuse_file_info *fi)
+#else
@@ -84,7 +83,7 @@ TODO: This patch should *really* be gone. Update librefuse.
*str = '\0';
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_rename(const char *from, const char *to)
+#else
static int sshfs_rename(const char *from, const char *to, unsigned int flags)
@@ -93,7 +92,7 @@ TODO: This patch should *really* be gone. Update librefuse.
int err;
struct conntab_entry *ce;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if(flags != 0)
return -EINVAL;
+#endif
@@ -104,7 +103,7 @@ TODO: This patch should *really* be gone. Update librefuse.
return (struct sshfs_file *) (uintptr_t) fi->fh;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_chmod(const char *path, mode_t mode)
+#else
static int sshfs_chmod(const char *path, mode_t mode,
@@ -116,7 +115,7 @@ TODO: This patch should *really* be gone. Update librefuse.
struct buffer buf;
struct sshfs_file *sf = NULL;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (fi != NULL) {
sf = get_sshfs_file(fi);
if (!sshfs_file_is_conn(sf))
@@ -130,7 +129,7 @@ TODO: This patch should *really* be gone. Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_chown(const char *path, uid_t uid, gid_t gid)
+#else
static int sshfs_chown(const char *path, uid_t uid, gid_t gid,
@@ -142,7 +141,7 @@ TODO: This patch should *really* be gone. Update librefuse.
struct buffer buf;
struct sshfs_file *sf = NULL;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (fi != NULL) {
sf = get_sshfs_file(fi);
if (!sshfs_file_is_conn(sf))
@@ -156,7 +155,7 @@ TODO: This patch should *really* be gone. Update librefuse.
return err;
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_truncate_workaround(const char *path, off_t size);
+#else
static int sshfs_truncate_workaround(const char *path, off_t size,
@@ -169,7 +168,7 @@ TODO: This patch should *really* be gone. Update librefuse.
pthread_mutex_unlock(&sshfs.lock);
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_utimens(const char *path, const struct timespec tv[2])
+#else
static int sshfs_utimens(const char *path, const struct timespec tv[2],
@@ -184,7 +183,7 @@ TODO: This patch should *really* be gone. Update librefuse.
if (msec == 0)
msec = now.tv_sec;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (fi != NULL) {
sf = get_sshfs_file(fi);
if (!sshfs_file_is_conn(sf))
@@ -198,7 +197,7 @@ TODO: This patch should *really* be gone. Update librefuse.
return sshfs_open_common(path, mode, fi);
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_truncate(const char *path, off_t size)
+#else
static int sshfs_truncate(const char *path, off_t size,
@@ -209,7 +208,7 @@ TODO: This patch should *really* be gone. Update librefuse.
struct buffer buf;
struct sshfs_file *sf = NULL;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (fi != NULL) {
sf = get_sshfs_file(fi);
if (!sshfs_file_is_conn(sf))
@@ -219,7 +218,7 @@ TODO: This patch should *really* be gone. Update librefuse.
sshfs_inc_modifver();
if (sshfs.truncate_workaround)
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ return sshfs_truncate_workaround(path, size);
+#else
return sshfs_truncate_workaround(path, size, fi);
@@ -227,19 +226,18 @@ TODO: This patch should *really* be gone. Update librefuse.
buf_init(&buf, 0);
-@@ -3372,19 +3435,38 @@ static int sshfs_truncate(const char *pa
+@@ -3372,19 +3435,37 @@ static int sshfs_truncate(const char *pa
return err;
}
-+#if defined(__NetBSD__) && FUSE_MAJOR_VERSION < 3
-+/* Workaround for a librefuse issue. fuse_mount() calls
-+ * fuse_operations::getattr() before we are ready for that. The
-+ * resulting struct stat isn't even used apparently. librefuse really
-+ * shouldn't do that. */
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
++/* Workaround for an issue in the past versions of
++ * librefuse. fuse_mount() used to call fuse_operations::getattr()
++ * before we were ready for that. */
+static int sshfs_initialized = 0;
+#endif
+
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_getattr(const char *path, struct stat *stbuf)
+#else
static int sshfs_getattr(const char *path, struct stat *stbuf,
@@ -251,12 +249,12 @@ TODO: This patch should *really* be gone. Update librefuse.
struct buffer outbuf;
struct sshfs_file *sf = NULL;
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ if (!sshfs_initialized)
+ return -EIO;
+#endif
+
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (fi != NULL && !sshfs.fstat_workaround) {
sf = get_sshfs_file(fi);
if (!sshfs_file_is_conn(sf))
@@ -266,11 +264,11 @@ TODO: This patch should *really* be gone. Update librefuse.
buf_init(&buf, 0);
if(sf == NULL) {
-@@ -3508,15 +3590,23 @@ static int sshfs_truncate_extend(const c
+@@ -3508,15 +3589,23 @@ static int sshfs_truncate_extend(const c
* If new size is greater than current size, then write a zero byte to
* the new end of the file.
*/
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+static int sshfs_truncate_workaround(const char *path, off_t size)
+#else
static int sshfs_truncate_workaround(const char *path, off_t size,
@@ -282,7 +280,7 @@ TODO: This patch should *really* be gone. Update librefuse.
else {
struct stat stbuf;
int err;
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ err = sshfs_getattr(path, &stbuf);
+#else
err = sshfs_getattr(path, &stbuf, fi);
@@ -290,11 +288,11 @@ TODO: This patch should *really* be gone. Update librefuse.
if (err)
return err;
if (stbuf.st_size == size)
-@@ -3524,7 +3614,11 @@ static int sshfs_truncate_workaround(con
+@@ -3524,7 +3613,11 @@ static int sshfs_truncate_workaround(con
else if (stbuf.st_size > size)
return sshfs_truncate_shrink(path, size);
else
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ return sshfs_truncate_extend(path, size, NULL);
+#else
return sshfs_truncate_extend(path, size, fi);
@@ -302,21 +300,21 @@ TODO: This patch should *really* be gone. Update librefuse.
}
}
-@@ -4156,7 +4250,9 @@ int main(int argc, char *argv[])
+@@ -4156,7 +4249,9 @@ int main(int argc, char *argv[])
char *fsname;
const char *sftp_server;
struct fuse *fuse;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
struct fuse_session *se;
+#endif
int i;
#ifdef __APPLE__
-@@ -4216,7 +4312,11 @@ int main(int argc, char *argv[])
+@@ -4216,7 +4311,11 @@ int main(int argc, char *argv[])
if (sshfs.show_version) {
printf("SSHFS version %s\n", PACKAGE_VERSION);
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ printf("FUSE library version %d\n", fuse_version());
+#else
printf("FUSE library version %s\n", fuse_pkgversion());
@@ -324,11 +322,11 @@ TODO: This patch should *really* be gone. Update librefuse.
#if !defined(__CYGWIN__)
fuse_lowlevel_version();
#endif
-@@ -4225,7 +4325,11 @@ int main(int argc, char *argv[])
+@@ -4225,7 +4324,11 @@ int main(int argc, char *argv[])
if (sshfs.show_help) {
usage(args.argv[0]);
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ fuse_cmdline_help();
+#else
fuse_lib_help(&args);
@@ -336,11 +334,11 @@ TODO: This patch should *really* be gone. Update librefuse.
exit(0);
} else if (!sshfs.host) {
fprintf(stderr, "missing host\n");
-@@ -4359,20 +4463,16 @@ int main(int argc, char *argv[])
+@@ -4359,20 +4462,16 @@ int main(int argc, char *argv[])
sizeof(struct fuse_operations), NULL);
if(fuse == NULL)
exit(1);
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
se = fuse_get_session(fuse);
res = fuse_set_signal_handlers(se);
if (res != 0) {
@@ -356,11 +354,11 @@ TODO: This patch should *really* be gone. Update librefuse.
- }
-
-#if !defined(__CYGWIN__)
-+#if !defined(__CYGWIN__) && FUSE_MAJOR_VERSION >= 3
++#if !defined(__CYGWIN__) && (!defined(__NetBSD__) || FUSE_H_ >= 20211204)
res = fcntl(fuse_session_fd(se), F_SETFD, FD_CLOEXEC);
if (res == -1)
perror("WARNING: failed to set FD_CLOEXEC on fuse device");
-@@ -4384,29 +4484,55 @@ int main(int argc, char *argv[])
+@@ -4384,29 +4483,58 @@ int main(int argc, char *argv[])
*/
res = ssh_connect();
if (res == -1) {
@@ -369,7 +367,7 @@ TODO: This patch should *really* be gone. Update librefuse.
exit(1);
}
-+#if FUSE_MAJOR_VERSION < 3
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ if (!sshfs.foreground)
+ res = fuse_daemonize(fuse);
+#else
@@ -381,24 +379,27 @@ TODO: This patch should *really* be gone. Update librefuse.
exit(1);
}
-+ /* NetBSD librefuse (actually libpuffs) requires that
-+ * applications call fuse_daemonize() before calling
-+ * fuse_mount(), otherwise the daemonizing parent process will
-+ * deadlock. FUSE on the other hand defines no specific order
-+ * of calling these two functions. pho@ thinks puffs_daemon()
-+ * waiting for the completion of fuse_mount() is actually
-+ * helpful and not a bug to be fixed, but it should at least
-+ * not deadlock. That is, fuse_daemonize() should immediately
-+ * kill the parent if the filesystem is already mounted. Until
-+ * the change is made, we reorder function calls here. */
++ /* NetBSD librefuse (actually libpuffs) used to require that user
++ * code calls fuse_daemonize() before calling fuse_mount(),
++ * otherwise the daemonizing parent process would deadlock. FUSE
++ * on the other hand defines no specific order of calling these
++ * two functions. pho@ thought puffs_daemon() waiting for the
++ * completion of fuse_mount() was actually helpful and not a bug
++ * to be fixed, but it should at least not deadlock. That is,
++ * fuse_daemonize() should immediately kill the parent if the
++ * filesystem is already mounted. The change has already been made
++ * in HEAD. */
+ res = fuse_mount(fuse, sshfs.mountpoint);
+ if (res != 0) {
+ fuse_destroy(fuse);
+ exit(1);
+ }
+
++#if defined(__NetBSD__) && FUSE_H_ < 20211204
+ sshfs_initialized = 1;
-+#if FUSE_MAJOR_VERSION >= 3
++#endif
++
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
if (sshfs.singlethread)
res = fuse_loop(fuse);
else
@@ -412,7 +413,7 @@ TODO: This patch should *really* be gone. Update librefuse.
else
res = 0;
-+#if FUSE_MAJOR_VERSION >= 3
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
fuse_remove_signal_handlers(se);
+#endif
fuse_unmount(fuse);
diff --git a/filesystems/fuse-wdfs/Makefile b/filesystems/fuse-wdfs/Makefile
index bc7d6c4e12f..b4fcaf932b4 100644
--- a/filesystems/fuse-wdfs/Makefile
+++ b/filesystems/fuse-wdfs/Makefile
@@ -1,15 +1,16 @@
-# $NetBSD: Makefile,v 1.22 2021/12/08 16:04:21 adam Exp $
+# $NetBSD: Makefile,v 1.23 2022/01/22 18:50:23 pho Exp $
#
DISTNAME= wdfs-1.4.2
PKGNAME= fuse-${DISTNAME}
-PKGREVISION= 16
+PKGREVISION= 17
CATEGORIES= filesystems
MASTER_SITES= http://noedler.de/projekte/wdfs/
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://noedler.de/projekte/wdfs/
COMMENT= FUSE-based webdav filesystem
+LICENSE= gnu-gpl-v2
GNU_CONFIGURE= yes
USE_TOOLS+= pkg-config
diff --git a/filesystems/fuse-wdfs/distinfo b/filesystems/fuse-wdfs/distinfo
index dedb28426f8..d3c743f3599 100644
--- a/filesystems/fuse-wdfs/distinfo
+++ b/filesystems/fuse-wdfs/distinfo
@@ -1,7 +1,7 @@
-$NetBSD: distinfo,v 1.7 2021/10/26 10:25:29 nia Exp $
+$NetBSD: distinfo,v 1.8 2022/01/22 18:50:23 pho Exp $
BLAKE2s (wdfs-1.4.2.tar.gz) = 8048713564688dc8e4529a93d31612638065d346fdcec98e2329600cf6d2bb75
SHA512 (wdfs-1.4.2.tar.gz) = da7e16ed86cbe4746fabe5fce44c83b1d0cd0fbc19994eefe0ce2a75f3d8c77c3c341a76409150a3509be08f8c0d28b8a9650037edcbbf2aa60f4c8ea5407004
Size (wdfs-1.4.2.tar.gz) = 109315 bytes
-SHA1 (patch-aa) = 050b27b342e28419eeb63115ed90f16b246bc1e5
+SHA1 (patch-aa) = 1acb91eea14670c048eba39f48deb88a6c52d8cf
SHA1 (patch-ab) = 1237cdd4baf150899b4d9ea1073d399ffe925a64
diff --git a/filesystems/fuse-wdfs/patches/patch-aa b/filesystems/fuse-wdfs/patches/patch-aa
index 82d68535708..7da804a87f0 100644
--- a/filesystems/fuse-wdfs/patches/patch-aa
+++ b/filesystems/fuse-wdfs/patches/patch-aa
@@ -1,27 +1,17 @@
-$NetBSD: patch-aa,v 1.3 2008/02/16 01:24:39 bjs Exp $
+$NetBSD: patch-aa,v 1.4 2022/01/22 18:50:23 pho Exp $
-If refuse(3) ever supports -ho in option_list, the #ifndef __NetBSD__
-should be removed.
+refuse(3) used to not support -ho in option_list. Already fixed in
+HEAD.
---- src/wdfs-main.c.orig 2007-04-12 04:30:08.000000000 -0400
+--- src/wdfs-main.c.orig 2007-04-12 08:30:08.000000000 +0000
+++ src/wdfs-main.c
-@@ -131,14 +131,24 @@ static struct fuse_opt wdfs_opts[] = {
- FUSE_OPT_END
- };
-
-+#ifndef FUSE_USE_VERSION
-+#define FUSE_USE_VERSION FUSE_VERSION
-+#endif
-+
- static int wdfs_opt_proc(
- void *data, const char *option, int key, struct fuse_args *option_list)
- {
+@@ -137,8 +137,14 @@ static int wdfs_opt_proc(
switch (key) {
case KEY_HELP:
print_help();
-+#ifndef __NetBSD__
++#if !defined(__NetBSD__) || FUSE_H_ >= 20211204
+/*
-+ * XXX Using refuse(3), this results in abnormal program termination
++ * XXX Using refuse(3), this resulted in abnormal program termination
+ * with SIG_SEGV.
+ */
fuse_opt_add_arg(option_list, "-ho");
@@ -30,22 +20,3 @@ should be removed.
exit(1);
case KEY_VERSION:
-@@ -1213,7 +1223,8 @@ static int wdfs_statfs(const char *local
-
-
- /* just say hello when fuse takes over control. */
--#if FUSE_VERSION >= 26
-+
-+#if FUSE_USE_VERSION >= 26
- static void* wdfs_init(struct fuse_conn_info *conn)
- #else
- static void* wdfs_init()
-@@ -1308,7 +1319,7 @@ static void print_help()
- /* just a simple wrapper for fuse_main(), because the interface changed... */
- static int call_fuse_main(struct fuse_args *args)
- {
--#if FUSE_VERSION >= 26
-+#if FUSE_USE_VERSION >= 26
- return fuse_main(args->argc, args->argv, &wdfs_operations, NULL);
- #else
- return fuse_main(args->argc, args->argv, &wdfs_operations);