diff options
Diffstat (limited to 'filesystems/fuse-ext2/patches')
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-aa | 31 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-ab | 37 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-ac | 19 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-ad | 25 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-ae | 17 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-af | 20 | ||||
-rw-r--r-- | filesystems/fuse-ext2/patches/patch-ag | 20 |
7 files changed, 169 insertions, 0 deletions
diff --git a/filesystems/fuse-ext2/patches/patch-aa b/filesystems/fuse-ext2/patches/patch-aa new file mode 100644 index 00000000000..3872cd80a9d --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-aa @@ -0,0 +1,31 @@ +$NetBSD: patch-aa,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Add NetBSD support. + +--- configure.ac.orig 2009-12-24 12:38:06.000000000 +0000 ++++ configure.ac 2011-07-09 13:54:03.000000000 +0100 +@@ -15,6 +15,7 @@ + case $target_os in + *linux*) arch=linux;; + *darwin*) arch=darwin;; ++ *netbsd*) arch=netbsd;; + *) arch=unknown;; + esac + +@@ -137,7 +138,7 @@ + ]) + + # Checks for libraries +-AC_CHECK_LIB([fuse], [fuse_main], [FUSE_LIBS="-lfuse"], [AC_MSG_ERROR([Can't find libfuse, please install it])]) ++AC_CHECK_LIB([fuse], [fuse_exit], [FUSE_LIBS="-lfuse"], [AC_MSG_ERROR([Can't find libfuse, please install it])]) + + AC_MSG_CHECKING([if FUSE on this system is too new for us]) + AC_EGREP_CPP([fuse_version_yes], [ +@@ -193,6 +194,7 @@ + + AM_CONDITIONAL(LINUX, test "$arch" = linux) + AM_CONDITIONAL(DARWIN, test "$arch" = darwin) ++AM_CONDITIONAL(NETBSD, test "$arch" = netbsd) + + AC_CONFIG_FILES([ + fuse-ext2.pc diff --git a/filesystems/fuse-ext2/patches/patch-ab b/filesystems/fuse-ext2/patches/patch-ab new file mode 100644 index 00000000000..8d1ae41c3bd --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-ab @@ -0,0 +1,37 @@ +$NetBSD: patch-ab,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Add NetBSD support to autotools files. + +--- fuse-ext2/Makefile.am.orig 2009-11-09 16:31:37.000000000 +0000 ++++ fuse-ext2/Makefile.am 2011-07-09 14:17:19.000000000 +0100 +@@ -39,6 +39,17 @@ + -lfuse \ + -lext2fs + endif ++if NETBSD ++fuse_ext2_probe_CFLAGS = \ ++ -Wall \ ++ -DHAVE_CONFIG_H \ ++ -I$(top_srcdir)/e2fsprogs-1.41.9 ++ ++fuse_ext2_probe_LDADD = \ ++ ../e2fsprogs-1.41.9/ext2fs/libext2fs.a \ ++ ../e2fsprogs-1.41.9/et/libcom_err.a \ ++ -lrefuse ++endif + + fuse_ext2_SOURCES = \ + fuse-ext2.h \ +@@ -183,6 +194,12 @@ + -lfuse \ + -lext2fs + endif ++if NETBSD ++fuse_ext2_LDADD = \ ++ ../e2fsprogs-1.41.9/ext2fs/libext2fs.a \ ++ ../e2fsprogs-1.41.9/et/libcom_err.a \ ++ -lrefuse ++endif + + install-data-hook: + cd "$(DESTDIR)/$(moddir)" && rm -f $(mod_LTLIBRARIES) diff --git a/filesystems/fuse-ext2/patches/patch-ac b/filesystems/fuse-ext2/patches/patch-ac new file mode 100644 index 00000000000..005cc6efa68 --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-ac @@ -0,0 +1,19 @@ +$NetBSD: patch-ac,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Fix build under NetBSD, based on "pkgsrc/sysutils/e2fsprogs/patches/patch-af". + +--- e2fsprogs-1.41.9/ext2fs/ismounted.c.orig 2010-05-18 03:04:39.000000000 +0000 ++++ e2fsprogs-1.41.9/ext2fs/ismounted.c +@@ -198,7 +198,11 @@ static errcode_t check_mntent(const char + static errcode_t check_getmntinfo(const char *file, int *mount_flags, + char *mtpt, int mtlen) + { +- struct statfs *mp; ++#if defined(__NetBSD__) && __NetBSD_Version__ >= 299000900 ++ struct statvfs *mp; ++#else ++ struct statfs *mp; ++#endif + int len, n; + const char *s1; + char *s2; diff --git a/filesystems/fuse-ext2/patches/patch-ad b/filesystems/fuse-ext2/patches/patch-ad new file mode 100644 index 00000000000..35106a9dd68 --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-ad @@ -0,0 +1,25 @@ +$NetBSD: patch-ad,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Avoid NULL pointer access with "librefuse" under NetBSD. + +--- fuse-ext2/fuse-ext2.h.orig 2009-11-09 16:31:37.000000000 +0000 ++++ fuse-ext2/fuse-ext2.h 2011-07-09 16:15:41.000000000 +0100 +@@ -71,12 +71,17 @@ + { + struct fuse_context *mycontext=fuse_get_context(); + struct extfs_data *e2data=mycontext->private_data; ++ ext2_filsys e2fs = e2data->e2fs; ++ if (e2fs == NULL) { ++ return NULL; ++ } ++ + time_t now=time(NULL); + if ((now - e2data->last_flush) > FLUSH_BITMAPS_TIMEOUT) { + ext2fs_write_bitmaps(e2data->e2fs); + e2data->last_flush=now; + } +- return (ext2_filsys) e2data->e2fs; ++ return e2fs; + } + + #if ENABLE_DEBUG diff --git a/filesystems/fuse-ext2/patches/patch-ae b/filesystems/fuse-ext2/patches/patch-ae new file mode 100644 index 00000000000..4afc6b2a319 --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-ae @@ -0,0 +1,17 @@ +$NetBSD: patch-ae,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Avoid NULL pointer access with "librefuse" under NetBSD. + +--- fuse-ext2/op_getattr.c.orig 2009-10-19 20:19:42.000000000 +0100 ++++ fuse-ext2/op_getattr.c 2011-07-09 16:12:35.000000000 +0100 +@@ -27,6 +27,10 @@ + struct ext2_vnode *vnode; + ext2_filsys e2fs = current_ext2fs(); + ++ if (e2fs == NULL) { ++ return -EIO; ++ } ++ + debugf("enter"); + debugf("path = %s", path); + diff --git a/filesystems/fuse-ext2/patches/patch-af b/filesystems/fuse-ext2/patches/patch-af new file mode 100644 index 00000000000..1bfe1160a8a --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-af @@ -0,0 +1,20 @@ +$NetBSD: patch-af,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Fix build under NetBSD. + +--- fuse-ext2/fuse-ext2.c.orig 2009-11-09 15:28:02.000000000 +0000 ++++ fuse-ext2/fuse-ext2.c 2011-07-09 12:52:23.000000000 +0100 +@@ -78,6 +78,13 @@ + return 0; + } + ++#ifdef __NetBSD__ ++static int fuse_version (void) ++{ ++ return FUSE_VERSION; ++} ++#endif ++ + static void usage (void) + { + printf(usage_msg, PACKAGE, VERSION, fuse_version(), PACKAGE, HOME); diff --git a/filesystems/fuse-ext2/patches/patch-ag b/filesystems/fuse-ext2/patches/patch-ag new file mode 100644 index 00000000000..d95afba8840 --- /dev/null +++ b/filesystems/fuse-ext2/patches/patch-ag @@ -0,0 +1,20 @@ +$NetBSD: patch-ag,v 1.1.1.1 2011/07/09 15:27:11 tron Exp $ + +Fix build under NetBSD. + +--- fuse-ext2/fuse-ext2.probe.c.orig 2009-11-03 13:50:57.000000000 +0000 ++++ fuse-ext2/fuse-ext2.probe.c 2011-07-09 14:05:33.000000000 +0100 +@@ -35,6 +35,13 @@ + "%s\n" + "\n"; + ++#ifdef __NetBSD__ ++static int fuse_version (void) ++{ ++ return FUSE_VERSION; ++} ++#endif ++ + static void usage (void) + { + printf(usage_msg, PACKAGE, VERSION, fuse_version(), PACKAGE, HOME); |