]> arthur.barton.de Git - bup.git/commitdiff
Don't compile bup_get_Linux_file_attr on systems without FS_IOC_GETFLAGS.
authorDickon Reed <dickon@cantab.net>
Thu, 24 Mar 2011 09:24:01 +0000 (09:24 +0000)
committerAvery Pennarun <apenwarr@gmail.com>
Thu, 24 Mar 2011 10:41:22 +0000 (03:41 -0700)
lib/bup/_helpers.c

index b60b11a3c3e3478f60b9c5aae12489248a624d53..61b73f7c11a155e797f2d0febffea7b22e50abdf 100644 (file)
@@ -630,7 +630,7 @@ static PyObject *fadvise_done(PyObject *self, PyObject *args)
 }
 
 
-#ifdef linux
+#if defined(linux) && defined(FS_IOC_GETFLAGS)
 static PyObject *bup_get_linux_file_attr(PyObject *self, PyObject *args)
 {
     int rc;
@@ -899,7 +899,7 @@ static PyMethodDef helper_methods[] = {
        "open() the given filename for read with O_NOATIME if possible" },
     { "fadvise_done", fadvise_done, METH_VARARGS,
        "Inform the kernel that we're finished with earlier parts of a file" },
-#ifdef linux
+#if defined(linux) && defined(FS_IOC_GETFLAGS)
     { "get_linux_file_attr", bup_get_linux_file_attr, METH_VARARGS,
       "Return the Linux attributes for the given file." },
     { "set_linux_file_attr", bup_set_linux_file_attr, METH_VARARGS,