3 --- lib/wiper/wiperPosix.c.orig 2008-08-08 02:01:55.000000000 -0500
4 +++ lib/wiper/wiperPosix.c
9 -#if !defined(__linux__) && !defined(sun) && !defined(__FreeBSD__) && !defined(__APPLE__)
10 +#if !defined(__linux__) && !defined(sun) && !defined(__FreeBSD__) && !defined(__APPLE__) && !defined(__NetBSD__)
11 #error This file should not be compiled on this platform.
16 #if defined(__linux__) || defined(sun)
18 -#elif defined(__FreeBSD__) || defined(__APPLE__)
19 +#elif defined(__FreeBSD__) || defined(__APPLE__) || defined(__NetBSD__)
20 # include <sys/param.h>
21 # include <sys/ucred.h>
22 # include <sys/mount.h>
24 -# if __FreeBSD_version >= 500000
25 +# if defined(__FreeBSD__) && __FreeBSD_version >= 500000
27 # endif /* __FreeBSD_version < 500000 */
31 #if defined(sun) || defined(__linux__)
32 # define PROCFS "proc"
33 -#elif defined(__FreeBSD__) || defined(__APPLE__)
34 +#elif defined(__FreeBSD__) || defined(__APPLE__) || defined(__NetBSD__)
35 # define PROCFS "procfs"
38 @@ -196,7 +196,7 @@ WiperIsDiskDevice(MNTINFO *mnt,
42 -#elif defined(__FreeBSD__) || defined(__APPLE__) /* } FreeBSD { */
43 +#elif defined(__FreeBSD__) || defined(__APPLE__) || defined(__NetBSD__) /* } FreeBSD { */
46 WiperIsDiskDevice(MNTINFO *mnt, // IN: file system being considered
47 @@ -210,7 +210,7 @@ WiperIsDiskDevice(MNTINFO *mnt,
48 * function, as a whole, does not even apply to OS X, so this caveat is
51 -#if __FreeBSD_version < 500000
52 +#if defined(__NetBSD__) || __FreeBSD_version < 500000
54 * Before FreeBSD 5, device nodes had static major/minor numbers.
55 * (FreeBSD 5 included devfs which got rid of this concept.) So
56 @@ -511,14 +511,14 @@ WiperSinglePartition_GetSpace(const Wipe
61 +#if defined(sun) || defined(__NetBSD__)
62 struct statvfs statfsbuf;
64 struct statfs statfsbuf;
69 +#if defined(sun) || defined(__NetBSD__)
70 if (statvfs(p->mountPoint, &statfsbuf) < 0) {
72 if (Posix_Statfs(p->mountPoint, &statfsbuf) < 0) {