~barry/ubuntu/natty/fuse/bug-697792

« back to all changes in this revision

Viewing changes to debian/patches/001-GNU_kFreeBSD

  • Committer: Colin Watson
  • Date: 2010-10-13 11:20:39 UTC
  • mfrom: (2.1.6 sid)
  • Revision ID: cjwatson@canonical.com-20101013112039-s5gzsxtbpqjl9km8
merge from Debian 2.8.4-1.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
 
7
7
@DPATCH@
8
8
 
9
 
diff -Nurd fuse-2.7.4.orig/lib/fuse.c fuse-2.7.4/lib/fuse.c
10
 
--- fuse-2.7.4.orig/lib/fuse.c  2008-07-25 20:17:21.000000000 +0200
11
 
+++ fuse-2.7.4/lib/fuse.c       2009-05-13 14:29:03.000000000 +0200
12
 
@@ -626,7 +626,7 @@
 
9
diff --git a/include/fuse_common.h b/include/fuse_common.h
 
10
index c263f6f..2d18346 100644
 
11
--- a/include/fuse_common.h
 
12
+++ b/include/fuse_common.h
 
13
@@ -261,7 +261,7 @@ void fuse_remove_signal_handlers(struct fuse_session *se);
 
14
  * ----------------------------------------------------------- */
 
15
 
 
16
 #if FUSE_USE_VERSION < 26
 
17
-#    ifdef __FreeBSD__
 
18
+#    if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
 
19
 #       if FUSE_USE_VERSION < 25
 
20
 #           error On FreeBSD API version 25 or greater must be used
 
21
 #       endif
 
22
diff --git a/include/fuse_compat.h b/include/fuse_compat.h
 
23
index 225276f..56b6c13 100644
 
24
--- a/include/fuse_compat.h
 
25
+++ b/include/fuse_compat.h
 
26
@@ -65,7 +65,7 @@ struct fuse *fuse_setup_compat25(int argc, char *argv[],
 
27
 
 
28
 void fuse_teardown_compat22(struct fuse *fuse, int fd, char *mountpoint);
 
29
 
 
30
-#ifndef __FreeBSD__
 
31
+#if !defined(__FreeBSD__) && !defined(__FreeBSD_kernel__)
 
32
 #include <sys/statfs.h>
 
33
 
 
34
 struct fuse_operations_compat22 {
 
35
diff --git a/include/fuse_lowlevel_compat.h b/include/fuse_lowlevel_compat.h
 
36
index aba45e6..d8c7108 100644
 
37
--- a/include/fuse_lowlevel_compat.h
 
38
+++ b/include/fuse_lowlevel_compat.h
 
39
@@ -72,7 +72,7 @@ size_t fuse_dirent_size(size_t namelen);
 
40
 char *fuse_add_dirent(char *buf, const char *name, const struct stat *stbuf,
 
41
                      off_t off);
 
42
 
 
43
-#ifndef __FreeBSD__
 
44
+#if !defined(__FreeBSD__) && !defined(__FreeBSD_kernel__)
 
45
 
 
46
 #include <sys/statfs.h>
 
47
 
 
48
diff --git a/lib/fuse.c b/lib/fuse.c
 
49
index 95cf50b..83c406c 100644
 
50
--- a/lib/fuse.c
 
51
+++ b/lib/fuse.c
 
52
@@ -954,7 +954,7 @@ static inline void fuse_prepare_interrupt(struct fuse *f, fuse_req_t req,
13
53
                fuse_do_prepare_interrupt(req, d);
14
54
 }
15
55
 
18
58
 
19
59
 static int fuse_compat_open(struct fuse_fs *fs, const char *path,
20
60
                            struct fuse_file_info *fi)
21
 
@@ -3107,7 +3107,7 @@
 
61
@@ -3721,7 +3721,7 @@ struct fuse *fuse_new_common(struct fuse_chan *ch, struct fuse_args *args,
22
62
        if (!f->conf.ac_attr_timeout_set)
23
63
                f->conf.ac_attr_timeout = f->conf.attr_timeout;
24
64
 
25
65
-#ifdef __FreeBSD__
26
 
+#if defined (__FreeBSD__) || defined (__FreeBSD_kernel__)
 
66
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
27
67
        /*
28
68
         * In FreeBSD, we always use these settings as inode numbers
29
69
         * are needed to make getcwd(3) work.
30
 
@@ -3280,7 +3280,7 @@
 
70
@@ -3897,7 +3897,7 @@ void fuse_register_module(struct fuse_module *mod)
31
71
        fuse_modules = mod;
32
72
 }
33
73
 
36
76
 
37
77
 static struct fuse *fuse_new_common_compat(int fd, const char *opts,
38
78
                                           const struct fuse_operations *op,
39
 
diff -Nurd fuse-2.7.4.orig/lib/fuse_lowlevel.c fuse-2.7.4/lib/fuse_lowlevel.c
40
 
--- fuse-2.7.4.orig/lib/fuse_lowlevel.c 2008-02-19 20:51:26.000000000 +0100
41
 
+++ fuse-2.7.4/lib/fuse_lowlevel.c      2009-05-13 14:29:03.000000000 +0200
42
 
@@ -1728,13 +1728,13 @@
43
 
 /*
44
 
  * This is currently not implemented on other than Linux...
45
 
  */
46
 
-int fuse_req_getgroups(fuse_req_t req, int size, gid_t list[]);
47
 
+int fuse_req_getgroups(fuse_req_t req, int size, gid_t list[])
48
 
 {
49
 
        return -ENOSYS;
 
79
diff --git a/lib/fuse_lowlevel.c b/lib/fuse_lowlevel.c
 
80
index c519bfb..40d7293 100644
 
81
--- a/lib/fuse_lowlevel.c
 
82
+++ b/lib/fuse_lowlevel.c
 
83
@@ -1734,7 +1734,7 @@ int fuse_req_getgroups(fuse_req_t req, int size, gid_t list[])
50
84
 }
51
85
 #endif
52
86
 
55
89
 
56
90
 static void fill_open_compat(struct fuse_open_out *arg,
57
91
                             const struct fuse_file_info_compat *f)
58
 
diff -Nurd fuse-2.7.4.orig/lib/helper.c fuse-2.7.4/lib/helper.c
59
 
--- fuse-2.7.4.orig/lib/helper.c        2008-02-19 20:51:27.000000000 +0100
60
 
+++ fuse-2.7.4/lib/helper.c     2009-05-13 14:29:03.000000000 +0200
61
 
@@ -356,7 +356,7 @@
 
92
diff --git a/lib/fuse_session.c b/lib/fuse_session.c
 
93
index 3758627..dd1311f 100644
 
94
--- a/lib/fuse_session.c
 
95
+++ b/lib/fuse_session.c
 
96
@@ -200,6 +200,6 @@ void fuse_chan_destroy(struct fuse_chan *ch)
 
97
        free(ch);
 
98
 }
 
99
 
 
100
-#ifndef __FreeBSD__
 
101
+#if !defined(__FreeBSD__) && !defined(__FreeBSD_kernel__)
 
102
 FUSE_SYMVER(".symver fuse_chan_new_compat24,fuse_chan_new@FUSE_2.4");
 
103
 #endif
 
104
diff --git a/lib/helper.c b/lib/helper.c
 
105
index 3d0db4a..107174e 100644
 
106
--- a/lib/helper.c
 
107
+++ b/lib/helper.c
 
108
@@ -357,7 +357,7 @@ int fuse_version(void)
62
109
 
63
110
 #include "fuse_compat.h"
64
111