Permalink
Browse files

Compile on NetBSD

1 parent 687a71c commit b75ffaaccb4c5bfd864bad186199a797ad2d66ee @vasi committed Apr 5, 2012
Showing with 8 additions and 3 deletions.
  1. +2 −0 TODO
  2. +2 −2 configure.ac
  3. +3 −0 nonstd-internal.h
  4. +1 −1 nonstd-stat.c
View
2 TODO
@@ -52,6 +52,8 @@ Testing
Ubuntu Lucid amd64
CentOS 3.9 i386 (FUSE 2.5)
FreeBSD 9.0 amd64
+ Known bad
+ Solaris 11 - No fuse_lowlevel
Todo
NetBSD 6 with libperfuse
Solaris 11? OpenIndiana?
View
@@ -45,7 +45,7 @@ AC_DEFUN([SQ_NONSTD_DEFINE],[
AS_VAR_PUSHDEF([sq_cache],[sq_cv_decl_nonstd_$1])
AC_CACHE_VAL([sq_cache],[
AS_VAR_SET([sq_cache],[no])
- for def in none _DARWIN_C_SOURCE _XOPEN_SOURCE _BSD_SOURCE _GNU_SOURCE _POSIX_C_SOURCE
+ for def in none _DARWIN_C_SOURCE _NETBSD_SOURCE _XOPEN_SOURCE _BSD_SOURCE _GNU_SOURCE _POSIX_C_SOURCE
do
AS_IF([test "x$def" = "x_POSIX_C_SOURCE"],[op=undef],[op=define])
AS_IF([test "x$def" = "x_XOPEN_SOURCE"],[val=500],[val=1])
@@ -90,7 +90,7 @@ SQ_NONSTD_DEFINE(makedev,[
#endif
],[makedev(0,0)])
SQ_NONSTD_DEFINE(pread,[#include <unistd.h>],[(void)pread;])
-SQ_NONSTD_DEFINE(S_IFDIR,[#include <sys/stat.h>],[mode_t m = S_IFDIR;])
+SQ_NONSTD_DEFINE(S_IFSOCK,[#include <sys/stat.h>],[mode_t m = S_IFSOCK;])
SQ_NONSTD_DEFINE(ENOATTR,[
#ifdef HAVE_ATTR_XATTR_H
#include <sys/types.h>
View
@@ -27,9 +27,12 @@
#define CHANGE_BSD_SOURCE 3
#define CHANGE_GNU_SOURCE 4
#define CHANGE_POSIX_C_SOURCE 5
+#define CHANGE_NETBSD_SOURCE 6
#if SQFEATURE == CHANGE_XOPEN_SOURCE
#define _XOPEN_SOURCE 500
+#elif SQFEATURE == CHANGE_NETBSD_SOURCE
+ #define _NETBSD_SOURCE
#elif SQFEATURE == CHANGE_DARWIN_C_SOURCE
#define _DARWIN_C_SOURCE
#elif SQFEATURE == CHANGE_BSD_SOURCE
View
@@ -24,7 +24,7 @@
*/
#include "config.h"
-#define SQFEATURE NONSTD_S_IFDIR_DEF
+#define SQFEATURE NONSTD_S_IFSOCK_DEF
#include "nonstd-internal.h"
#include <sys/stat.h>

0 comments on commit b75ffaa

Please sign in to comment.