aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Miklos Szeredi <miklos@szeredi.hu>2002-12-03 18:45:21 +0000
committerGravatar Miklos Szeredi <miklos@szeredi.hu>2002-12-03 18:45:21 +0000
commit5f0548192fc4df56e8b21c239f8f75479147e34a (patch)
tree816b8836046826e4db2213166a96cba0c59aca91
parent6bf8b68e0ee6596e8b5f0e53656a078bc5e579ba (diff)
fixes
-rw-r--r--ChangeLog5
-rw-r--r--configure.in17
-rw-r--r--include/fuse.h3
-rw-r--r--util/fusermount.c17
4 files changed, 23 insertions, 19 deletions
diff --git a/ChangeLog b/ChangeLog
index 62a859a..9b21b59 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2002-12-03 Miklos Szeredi <mszeredi@inf.bme.hu>
+
+ * Added _FILE_OFFSET_BITS=64 define to fuse.h. Note, that this is
+ an incompatible interface change.
+
2002-10-28 Miklos Szeredi <mszeredi@inf.bme.hu>
* Portablility fix (bug reported by C. Chris Erway)
diff --git a/configure.in b/configure.in
index 2238b60..dff58c6 100644
--- a/configure.in
+++ b/configure.in
@@ -21,6 +21,8 @@ AC_ARG_ENABLE(util,
AC_ARG_ENABLE(example,
[ --enable-example Compile with examples ])
+subdirs="include patch"
+
if test "$enable_kernel_module" != "no"; then
AC_MSG_CHECKING([kernel source directory])
kernelsrc=
@@ -40,16 +42,7 @@ if test "$enable_kernel_module" != "no"; then
fi
fi
AC_MSG_RESULT([$kernelsrc])
-fi
-
-oldcc=$CC
-oldcross_compiling=$cross_compiling
-if test "$cross_compiling" = yes; then
- CC=gcc
- cross_compiling=no
-fi
-if test "$enable_kernel_module" != "no"; then
AC_MSG_CHECKING([kernel source version])
kernsrcver=`sed -ne '/^VERSION = \(.*\)/{s//\1/;p;q;}' $kernelsrc/Makefile`
kernsrcver="$kernsrcver.`sed -ne '/^PATCHLEVEL = \(.*\)/{s//\1/;p;q;}' $kernelsrc/Makefile`"
@@ -63,13 +56,7 @@ if test "$enable_kernel_module" != "no"; then
*** configure the kernel before running this script])
fi
AC_MSG_RESULT([$kernsrcver])
-fi
-CC=$oldcc
-cross_compiling=$oldcross_compiling
-subdirs="include patch"
-
-if test "$enable_kernel_module" != "no"; then
KERNINCLUDE=$kernelsrc/include
AC_SUBST(KERNINCLUDE)
kmoduledir=/lib/modules/$kernsrcver
diff --git a/include/fuse.h b/include/fuse.h
index c4cfbc4..68f8eec 100644
--- a/include/fuse.h
+++ b/include/fuse.h
@@ -11,6 +11,9 @@
/* This file defines the library interface of FUSE */
+/* Now and forever: this interface uses 64 bit off_t */
+#define _FILE_OFFSET_BITS 64
+
#include <sys/types.h>
#include <sys/stat.h>
#include <utime.h>
diff --git a/util/fusermount.c b/util/fusermount.c
index ac464d2..b76c819 100644
--- a/util/fusermount.c
+++ b/util/fusermount.c
@@ -384,10 +384,19 @@ static char *resolve_path(const char *orig, int unmount)
{
char buf[PATH_MAX];
- /* Resolving at unmount can only be done very carefully, not touching
- the mountpoint... So for the moment it's not done. */
- if(unmount)
- return strdup(orig);
+ if(unmount) {
+ /* Resolving at unmount can only be done very carefully, not touching
+ the mountpoint... So for the moment it's not done.
+
+ Just remove trailing slashes instead.
+ */
+ char *dst = strdup(orig);
+ char *end;
+ for(end = dst + strlen(dst) - 1; end > dst && *end == '/'; end --)
+ *end = '\0';
+
+ return dst;
+ }
if(realpath(orig, buf) == NULL) {
fprintf(stderr, "%s: Bad mount point %s: %s\n", progname, orig,