mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
- Fix build on CURRENT
Submitted by: rnoland@ Approved by: Anish Mistry <amistry@am-productions.biz>
This commit is contained in:
parent
8181033ff5
commit
7d7c6fb4c7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=220853
5 changed files with 102 additions and 3 deletions
|
@ -7,7 +7,7 @@
|
|||
|
||||
PORTNAME= fusefs
|
||||
DISTVERSION= 0.3.9-pre1.20080208
|
||||
PORTREVISION= 2
|
||||
PORTREVISION= 3
|
||||
CATEGORIES= sysutils kld
|
||||
MASTER_SITES= http://mercurial.creo.hu/repos/fuse4bsd-hg/index.cgi/archive/
|
||||
PKGNAMESUFFIX= -kmod
|
||||
|
|
17
sysutils/fusefs-kmod/files/patch-fuse_module__fuse.h
Normal file
17
sysutils/fusefs-kmod/files/patch-fuse_module__fuse.h
Normal file
|
@ -0,0 +1,17 @@
|
|||
--- fuse_module/fuse.h.orig 2008-09-26 12:40:20.000000000 -0400
|
||||
+++ fuse_module/fuse.h 2008-09-26 12:41:54.000000000 -0400
|
||||
@@ -49,6 +49,14 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
+#ifndef VOP_GETATTR_TAKES_THREAD
|
||||
+#if __FreeBSD_version >= 800046
|
||||
+#define VOP_GETATTR_TAKES_THREAD 0
|
||||
+#else
|
||||
+#define VOP_GETATTR_TAKES_THREAD 1
|
||||
+#endif
|
||||
+#endif
|
||||
+
|
||||
#ifndef USE_PRIVILEGE_API
|
||||
/*
|
||||
* __FreeBSD_version bump was omitted for introduction of
|
28
sysutils/fusefs-kmod/files/patch-fuse_module__fuse_io.c
Normal file
28
sysutils/fusefs-kmod/files/patch-fuse_module__fuse_io.c
Normal file
|
@ -0,0 +1,28 @@
|
|||
--- fuse_module/fuse_io.c.orig 2008-02-05 00:25:57.000000000 -0500
|
||||
+++ fuse_module/fuse_io.c 2008-09-26 13:15:56.000000000 -0400
|
||||
@@ -157,7 +157,11 @@
|
||||
goto out;
|
||||
|
||||
if (uio->uio_rw == UIO_WRITE && fp->f_flag & O_APPEND) {
|
||||
- if ((err = VOP_GETATTR(vp, &va, cred, td)))
|
||||
+ if ((err = VOP_GETATTR(vp, &va, cred
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
+ , td
|
||||
+#endif
|
||||
+ )))
|
||||
goto out;
|
||||
uio->uio_offset = va.va_size;
|
||||
} else if ((flags & FOF_OFFSET) == 0)
|
||||
@@ -823,7 +827,11 @@
|
||||
#if FUSELIB_CONFORM_BIOREAD
|
||||
struct vattr va;
|
||||
|
||||
- if ((err = VOP_GETATTR(vp, &va, cred, curthread)))
|
||||
+ if ((err = VOP_GETATTR(vp, &va, cred
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
+ , curthread
|
||||
+#endif
|
||||
+ )))
|
||||
goto out;
|
||||
#endif
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
--- fuse_module/fuse_vfsops.c.orig 2008-04-11 11:34:04.000000000 +0900
|
||||
+++ fuse_module/fuse_vfsops.c 2008-04-11 11:34:24.000000000 +0900
|
||||
--- fuse_module/fuse_vfsops.c.orig 2008-02-05 00:25:57.000000000 -0500
|
||||
+++ fuse_module/fuse_vfsops.c 2008-09-26 12:53:33.000000000 -0400
|
||||
@@ -18,6 +18,7 @@
|
||||
#include <sys/namei.h>
|
||||
#include <sys/mount.h>
|
||||
|
@ -8,3 +8,16 @@
|
|||
|
||||
#include "fuse.h"
|
||||
#include "fuse_session.h"
|
||||
@@ -667,7 +668,11 @@
|
||||
if (vp->v_type == VNON) {
|
||||
struct vattr va;
|
||||
|
||||
- (void)VOP_GETATTR(vp, &va, td->td_ucred, td);
|
||||
+ (void)VOP_GETATTR(vp, &va, td->td_ucred
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
+ , td
|
||||
+#endif
|
||||
+ );
|
||||
}
|
||||
*vpp = vp;
|
||||
#if _DEBUG2G
|
||||
|
|
41
sysutils/fusefs-kmod/files/patch-fuse_module__fuse_vnops.c
Normal file
41
sysutils/fusefs-kmod/files/patch-fuse_module__fuse_vnops.c
Normal file
|
@ -0,0 +1,41 @@
|
|||
--- fuse_module/fuse_vnops.c.orig 2008-09-26 13:08:03.000000000 -0400
|
||||
+++ fuse_module/fuse_vnops.c 2008-09-26 13:14:36.000000000 -0400
|
||||
@@ -799,8 +799,11 @@
|
||||
struct vnode *vp = ap->a_vp;
|
||||
struct vattr *vap = ap->a_vap;
|
||||
struct ucred *cred = ap->a_cred;
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
struct thread *td = ap->a_td;
|
||||
-
|
||||
+#else
|
||||
+ struct thread *td = curthread;
|
||||
+#endif
|
||||
struct fuse_dispatcher fdi;
|
||||
struct timespec uptsp;
|
||||
int err = 0;
|
||||
@@ -946,7 +949,11 @@
|
||||
/* We are to do the check in-kernel */
|
||||
|
||||
if (! (facp->facc_flags & FACCESS_VA_VALID)) {
|
||||
- err = VOP_GETATTR(vp, VTOVA(vp), cred, td);
|
||||
+ err = VOP_GETATTR(vp, VTOVA(vp), cred
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
+ , td
|
||||
+#endif
|
||||
+ );
|
||||
if (err)
|
||||
return (err);
|
||||
facp->facc_flags |= FACCESS_VA_VALID;
|
||||
@@ -3005,8 +3012,11 @@
|
||||
struct vattr *vap = ap->a_vap;
|
||||
struct vnode *vp = ap->a_vp;
|
||||
struct ucred *cred = ap->a_cred;
|
||||
+#if VOP_GETATTR_TAKES_THREAD
|
||||
struct thread *td = ap->a_td;
|
||||
-
|
||||
+#else
|
||||
+ struct thread *td = curthread;
|
||||
+#endif
|
||||
int err = 0;
|
||||
struct fuse_dispatcher fdi;
|
||||
struct fuse_setattr_in *fsai;
|
Loading…
Add table
Reference in a new issue