aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils/fusefs-fusexmp_fh
diff options
context:
space:
mode:
authorlwhsu <lwhsu@FreeBSD.org>2010-08-29 07:04:37 +0800
committerlwhsu <lwhsu@FreeBSD.org>2010-08-29 07:04:37 +0800
commit9384284c0500aace43d550c78a3632bb54b64fb2 (patch)
tree56edd6c9a0be9820926c19dd39431ee5913e973b /sysutils/fusefs-fusexmp_fh
parent16468dd5103805c48cfeddfa20e2f2bce2e4768f (diff)
downloadfreebsd-ports-gnome-9384284c0500aace43d550c78a3632bb54b64fb2.tar.gz
freebsd-ports-gnome-9384284c0500aace43d550c78a3632bb54b64fb2.tar.zst
freebsd-ports-gnome-9384284c0500aace43d550c78a3632bb54b64fb2.zip
- Fix build for FreeBSD-6 by importing libfuse-libs patches
Submitted by: <buganini AT gmail.com> (maintainer)
Diffstat (limited to 'sysutils/fusefs-fusexmp_fh')
-rw-r--r--sysutils/fusefs-fusexmp_fh/Makefile6
-rw-r--r--sysutils/fusefs-fusexmp_fh/files/patch-configure10
-rw-r--r--sysutils/fusefs-fusexmp_fh/files/patch-lib_helper.c72
-rw-r--r--sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_bsd.c10
-rw-r--r--sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.c23
-rw-r--r--sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.h7
6 files changed, 128 insertions, 0 deletions
diff --git a/sysutils/fusefs-fusexmp_fh/Makefile b/sysutils/fusefs-fusexmp_fh/Makefile
index 2323d8c553e7..efc528fd0668 100644
--- a/sysutils/fusefs-fusexmp_fh/Makefile
+++ b/sysutils/fusefs-fusexmp_fh/Makefile
@@ -6,6 +6,7 @@
PORTNAME= fusexmp_fh
PORTVERSION= 2.7.4
+PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= SF/fuse/fuse-2.X/${PORTVERSION}
PKGNAMEPREFIX= fusefs-
@@ -27,6 +28,11 @@ CONFIGURE_ARGS= --disable-kernel-module --prefix=${PREFIX} \
PLIST_FILES= bin/${PORTNAME}
+post-patch:
+ ${REINPLACE_CMD} -e 's,-lpthread,${PTHREAD_LIBS},' \
+ ${WRKSRC}/lib/Makefile.in \
+ ${WRKSRC}/example/Makefile.in
+
do-build:
cd ${WRKSRC}/lib \
&& ${MAKE}
diff --git a/sysutils/fusefs-fusexmp_fh/files/patch-configure b/sysutils/fusefs-fusexmp_fh/files/patch-configure
new file mode 100644
index 000000000000..d35406f06134
--- /dev/null
+++ b/sysutils/fusefs-fusexmp_fh/files/patch-configure
@@ -0,0 +1,10 @@
+--- configure.orig 2008-06-05 13:58:44.000000000 -0700
++++ configure 2008-06-05 14:00:32.000000000 -0700
+@@ -12201,6 +12201,7 @@
+ _ACEOF
+
+ fi
++ LIBICONV=$LTLIBICONV
+ if test "$am_cv_lib_iconv" = yes; then
+ { echo "$as_me:$LINENO: checking how to link with libiconv" >&5
+ echo $ECHO_N "checking how to link with libiconv... $ECHO_C" >&6; }
diff --git a/sysutils/fusefs-fusexmp_fh/files/patch-lib_helper.c b/sysutils/fusefs-fusexmp_fh/files/patch-lib_helper.c
new file mode 100644
index 000000000000..89f46a4595aa
--- /dev/null
+++ b/sysutils/fusefs-fusexmp_fh/files/patch-lib_helper.c
@@ -0,0 +1,72 @@
+--- lib/helper.c.orig 2007-12-12 09:33:35.000000000 -0500
++++ lib/helper.c 2008-02-04 00:22:51.000000000 -0500
+@@ -30,7 +30,7 @@
+ struct helper_opts {
+ int singlethread;
+ int foreground;
+- int nodefault_subtype;
++ int fsname;
+ char *mountpoint;
+ };
+
+@@ -41,8 +41,7 @@
+ FUSE_HELPER_OPT("debug", foreground),
+ FUSE_HELPER_OPT("-f", foreground),
+ FUSE_HELPER_OPT("-s", singlethread),
+- FUSE_HELPER_OPT("fsname=", nodefault_subtype),
+- FUSE_HELPER_OPT("subtype=", nodefault_subtype),
++ FUSE_HELPER_OPT("fsname=", fsname),
+
+ FUSE_OPT_KEY("-h", KEY_HELP),
+ FUSE_OPT_KEY("--help", KEY_HELP),
+@@ -52,7 +51,6 @@
+ FUSE_OPT_KEY("-d", FUSE_OPT_KEY_KEEP),
+ FUSE_OPT_KEY("debug", FUSE_OPT_KEY_KEEP),
+ FUSE_OPT_KEY("fsname=", FUSE_OPT_KEY_KEEP),
+- FUSE_OPT_KEY("subtype=", FUSE_OPT_KEY_KEEP),
+ FUSE_OPT_END
+ };
+
+@@ -122,24 +120,24 @@
+ }
+ }
+
+-static int add_default_subtype(const char *progname, struct fuse_args *args)
++static int add_default_fsname(const char *progname, struct fuse_args *args)
+ {
+ int res;
+- char *subtype_opt;
++ char *fsname_opt;
+ const char *basename = strrchr(progname, '/');
+ if (basename == NULL)
+ basename = progname;
+ else if (basename[1] != '\0')
+ basename++;
+
+- subtype_opt = (char *) malloc(strlen(basename) + 64);
+- if (subtype_opt == NULL) {
++ fsname_opt = (char *) malloc(strlen(basename) + 64);
++ if (fsname_opt == NULL) {
+ fprintf(stderr, "fuse: memory allocation failed\n");
+ return -1;
+ }
+- sprintf(subtype_opt, "-osubtype=%s", basename);
+- res = fuse_opt_add_arg(args, subtype_opt);
+- free(subtype_opt);
++ sprintf(fsname_opt, "-ofsname=%s", basename);
++ res = fuse_opt_add_arg(args, fsname_opt);
++ free(fsname_opt);
+ return res;
+ }
+
+@@ -155,8 +153,8 @@
+ if (res == -1)
+ return -1;
+
+- if (!hopts.nodefault_subtype) {
+- res = add_default_subtype(args->argv[0], args);
++ if (!hopts.fsname) {
++ res = add_default_fsname(args->argv[0], args);
+ if (res == -1)
+ goto err;
+ }
diff --git a/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_bsd.c b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_bsd.c
new file mode 100644
index 000000000000..8bc349838e47
--- /dev/null
+++ b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_bsd.c
@@ -0,0 +1,10 @@
+--- lib/mount_bsd.c.orig 2008-07-07 08:01:09.000000000 +0200
++++ lib/mount_bsd.c 2008-07-07 08:01:59.000000000 +0200
+@@ -10,6 +10,7 @@
+ #include "fuse_misc.h"
+ #include "fuse_opt.h"
+
++#include <sys/param.h>
+ #include <sys/stat.h>
+ #include <sys/wait.h>
+ #include <sys/sysctl.h>
diff --git a/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.c b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.c
new file mode 100644
index 000000000000..b81a34084aee
--- /dev/null
+++ b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.c
@@ -0,0 +1,23 @@
+--- lib/mount_util.c.orig 2008-02-04 00:23:30.000000000 -0500
++++ lib/mount_util.c 2008-02-04 00:23:58.000000000 -0500
+@@ -224,20 +224,3 @@
+ }
+ return 0;
+ }
+-
+-int fuse_mnt_check_fuseblk(void)
+-{
+- char buf[256];
+- FILE *f = fopen("/proc/filesystems", "r");
+- if (!f)
+- return 1;
+-
+- while (fgets(buf, sizeof(buf), f))
+- if (strstr(buf, "fuseblk\n")) {
+- fclose(f);
+- return 1;
+- }
+-
+- fclose(f);
+- return 0;
+-}
diff --git a/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.h b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.h
new file mode 100644
index 000000000000..836fdc133e9d
--- /dev/null
+++ b/sysutils/fusefs-fusexmp_fh/files/patch-lib_mount_util.h
@@ -0,0 +1,7 @@
+--- lib/mount_util.h.orig 2008-02-04 00:24:07.000000000 -0500
++++ lib/mount_util.h 2008-02-04 00:24:20.000000000 -0500
+@@ -14,4 +14,3 @@
+ char *fuse_mnt_resolve_path(const char *progname, const char *orig);
+ int fuse_mnt_check_empty(const char *progname, const char *mnt,
+ mode_t rootmode, off_t rootsize);
+-int fuse_mnt_check_fuseblk(void);