You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

42 lines
1.0 KiB

Index: src/updatedb.c
--- src/updatedb.c.orig 2012-03-23 19:00:48.000000000 +0100
+++ src/updatedb.c 2012-09-22 09:40:29.000000000 +0200
@@ -36,7 +36,9 @@
#include <sys/time.h>
#include <unistd.h>
+#ifdef __linux__
#include <mntent.h>
+#endif
#include "error.h"
#include "fwriteerror.h"
#include "obstack.h"
@@ -354,17 +356,20 @@
static bool
filesystem_is_excluded (const char *path)
{
+#ifdef __linux__
static char *type; /* = NULL; */
static size_t type_size; /* = 0; */
FILE *f;
struct mntent *me;
+#endif
bool res;
if (conf_debug_pruning != false)
/* This is debuging output, don't mark anything for translation */
fprintf (stderr, "Checking whether filesystem `%s' is excluded:\n", path);
res = false;
+#ifdef __linux__
f = setmntent (MOUNT_TABLE_PATH, "r");
if (f == NULL)
goto err;
@@ -414,6 +419,7 @@
if (conf_debug_pruning != false)
/* This is debuging output, don't mark anything for translation */
fprintf (stderr, "...done\n");
+#endif
return res;
}