pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/filesystems/fuse-httpfs
Module Name: pkgsrc
Committed By: pho
Date: Sat Jan 22 18:41:21 UTC 2022
Modified Files:
pkgsrc/filesystems/fuse-httpfs: Makefile distinfo
pkgsrc/filesystems/fuse-httpfs/patches: patch-aa
Log Message:
Conditionalise workarounds for old NetBSD librefuse
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 pkgsrc/filesystems/fuse-httpfs/Makefile
cvs rdiff -u -r1.5 -r1.6 pkgsrc/filesystems/fuse-httpfs/distinfo
cvs rdiff -u -r1.1 -r1.2 pkgsrc/filesystems/fuse-httpfs/patches/patch-aa
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/filesystems/fuse-httpfs/Makefile
diff -u pkgsrc/filesystems/fuse-httpfs/Makefile:1.4 pkgsrc/filesystems/fuse-httpfs/Makefile:1.5
--- pkgsrc/filesystems/fuse-httpfs/Makefile:1.4 Wed Oct 3 16:08:32 2012
+++ pkgsrc/filesystems/fuse-httpfs/Makefile Sat Jan 22 18:41:21 2022
@@ -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@localhost
HOMEPAGE= http://httpfs.sourceforge.net/
COMMENT= FUSE HTTP filesystem
+LICENSE= gnu-gpl-v2
DIST_VER= 2.06.08.26
Index: pkgsrc/filesystems/fuse-httpfs/distinfo
diff -u pkgsrc/filesystems/fuse-httpfs/distinfo:1.5 pkgsrc/filesystems/fuse-httpfs/distinfo:1.6
--- pkgsrc/filesystems/fuse-httpfs/distinfo:1.5 Tue Oct 26 10:25:27 2021
+++ pkgsrc/filesystems/fuse-httpfs/distinfo Sat Jan 22 18:41:21 2022
@@ -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
Index: pkgsrc/filesystems/fuse-httpfs/patches/patch-aa
diff -u pkgsrc/filesystems/fuse-httpfs/patches/patch-aa:1.1 pkgsrc/filesystems/fuse-httpfs/patches/patch-aa:1.2
--- pkgsrc/filesystems/fuse-httpfs/patches/patch-aa:1.1 Mon Aug 3 13:50:39 2009
+++ pkgsrc/filesystems/fuse-httpfs/patches/patch-aa Sat Jan 22 18:41:21 2022
@@ -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
/*
* 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) {
Home |
Main Index |
Thread Index |
Old Index