diff -uNr ext2fuse-src-0.8.1/Makefile ext2fuse-src-0.8.1-fbsd/Makefile --- ext2fuse-src-0.8.1/configure.ac 2008-06-26 06:34:50.000000000 +0100 +++ ext2fuse-src-0.8.1-fbsd/configure.ac 2008-12-05 09:48:06.000000000 +0000 @@ -14,6 +14,17 @@ AC_PROG_RANLIB AC_PROG_INSTALL AC_PATH_PROG(CHMOD, chmod, :) +AC_PATH_PROG(PKG_CONFIG, pkg-config, no) + +# Libraries often install their metadata .pc files in directories +# not searched by pkg-config. Let's workaround this. +export PKG_CONFIG_PATH=${PKG_CONFIG_PATH}:/lib/pkgconfig:/usr/lib/pkgconfig:/opt/gnome/lib/pkgconfig:/usr/share/pkgconfig:/usr/local/lib/pkgconfig:$prefix/lib/pkgconfig:/opt/gnome/share/pkgconfig:/usr/local/share/pkgconfig + +# Check for fuse package. +PKG_CHECK_MODULES([FUSE_MODULE],[fuse >= 2.6.0], , +[ + AC_MSG_ERROR([FUSE >= 2.6.0 was not found. Either older FUSE is still present, or FUSE is not fully installed (e.g. fuse, libfuse, libfuse2, libfuse-dev, etc packages). Source code: http://fuse.sf.net]) +]) # Checks for libraries. AC_CHECK_LIB([fuse], [fuse_mount]) --- ext2fuse-src-0.8.1/lib/ext2fs/tdb.c 2008-06-26 06:34:50.000000000 +0100 +++ ext2fuse-src-0.8.1-fbsd/lib/ext2fs/tdb.c 2008-12-05 09:19:27.000000000 +0000 @@ -41,6 +41,18 @@ #endif #define _XOPEN_SOURCE 500 +#include +#include +#ifndef __FreeBSD__ +#include +#endif +#include +#include +#include +#ifdef HAVE_SYS_MMAN_H +#include +#endif + #include #include #include @@ -48,21 +60,12 @@ #include #include #include -#include -#include -#include #include #ifdef HAVE_UTIME_H #include #endif -#include -#include #include -#ifdef HAVE_SYS_MMAN_H -#include -#endif - #ifndef MAP_FILE #define MAP_FILE 0 #endif --- ext2fuse-src-0.8.1/src/Makefile.am 2008-06-26 06:34:50.000000000 +0100 +++ ext2fuse-src-0.8.1-fbsd/src/Makefile.am 2008-12-05 09:49:31.000000000 +0000 @@ -1,5 +1,33 @@ -bin_PROGRAMS = ext2fuse -ext2fuse_SOURCES = ext2fs.c mkdir.c readdir.c symlink.c wipe_block.c fuse-ext2fs.c perms.c rename.c truncate.c ext2fs.h readdir.h symlink.h truncate.h wipe_block.h -ext2fuse_CFLAGS = -I/usr/include/fuse -I/usr/local/include/fuse -I../lib -I../lib/et -I../lib/ext2fs -D_FILE_OFFSET_BITS=64 -ext2fuse_LDADD = ../lib/et/libcom_err.a ../lib/ext2fs/libext2fs.a +FUSE_LIBS = $(FUSE_MODULE_LIBS) +FUSE_CFLAGS = $(FUSE_MODULE_CFLAGS) +bin_PROGRAMS = ext2fuse + +ext2fuse_SOURCES = \ + ext2fs.c \ + mkdir.c \ + readdir.c \ + symlink.c \ + wipe_block.c \ + fuse-ext2fs.c \ + perms.c \ + rename.c \ + truncate.c \ + ext2fs.h \ + readdir.h \ + symlink.h \ + truncate.h \ + wipe_block.h + +ext2fuse_CFLAGS = \ + $(AM_CFLAGS) \ + -DFUSE_USE_VERSION=26 \ + $(FUSE_CFLAGS) \ + -I/usr/include/fuse \ + -I/usr/local/include/fuse \ + -I../lib -I../lib/et -I../lib/ext2fs + +ext2fuse_LDADD = \ + ../lib/et/libcom_err.a \ + ../lib/ext2fs/libext2fs.a \ + $(FUSE_LIBS) --- ext2fuse-src-0.8.1/src/ext2fs.c 2008-06-26 06:34:50.000000000 +0100 +++ ext2fuse-src-0.8.1-fbsd/src/ext2fs.c 2008-12-05 09:23:23.000000000 +0000 @@ -5,11 +5,14 @@ * or any later version. See the file COPYING. */ +#include +#include +#include + #include #include #include #include -#include #include #include