Fix build error on DragonFlyBSD (sync with other *BSD) (#240)
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Wed, 28 Mar 2018 19:32:59 +0000 (04:32 +0900)
committerNikolaus Rath <Nikolaus@rath.org>
Wed, 28 Mar 2018 19:32:59 +0000 (20:32 +0100)
DragonFlyBSD has no "bsd" in uname, so add 'dragonfly' to conditionals.

-- e.g. uname(1) in DragonFlyBSD
[root@ ~]# uname
DragonFly
[root@ ~]# python -c "import sys; print(sys.platform)"
dragonfly5

doc/meson.build
example/meson.build
meson.build
test/util.py

index d95a344da322b66555a73dd494d45516578e96f6..23c8e9af1af10b9102a63a997cde36f5da57a6c2 100644 (file)
@@ -1,4 +1,4 @@
-if not platform.endswith('bsd')
+if not platform.endswith('bsd') and platform != 'dragonfly'
   install_man('fusermount3.1', 'mount.fuse.8')
 endif
 
index 673982cd28c76df33eec5ea3962c9a55206c6973..7349977e192dae54c3ed41638a2ae6f6e9dba80f 100644 (file)
@@ -3,7 +3,7 @@ examples = [ 'passthrough', 'passthrough_fh',
              'ioctl_client', 'poll_client', 'ioctl',
              'cuse', 'cuse_client' ]
 
-if not platform.endswith('bsd')
+if not platform.endswith('bsd') and platform != 'dragonfly'
     examples += 'passthrough_ll'
 
     # According to Conrad Meyer <cem@freebsd.org>, FreeBSD doesn't
index 53a34258352f4fe8a4b11c953018b74d2379b3ae..b16c51ba061b6e07831a6414b6e52ace7df7abd9 100644 (file)
@@ -93,7 +93,7 @@ thread_dep = dependency('threads')
 # Read build files from sub-directories
 #
 subdirs = [ 'lib', 'include', 'example', 'doc', 'test' ]
-if not platform.endswith('bsd')
+if not platform.endswith('bsd') and platform != 'dragonfly'
   subdirs += 'util'
 endif
 foreach n : subdirs
index c15476bcf7d5bf2104ad6d2f24e975627f02f52c..b9c1b0cb179120b252e54934bf569c9d5dd8660b 100644 (file)
@@ -46,7 +46,7 @@ def wait_for_mount(mount_process, mnt_dir,
 def cleanup(mnt_dir):
     # Don't bother trying Valgrind if things already went wrong
 
-    if 'bsd' in sys.platform:
+    if 'bsd' in sys.platform or 'dragonfly' in sys.platform:
         cmd = [ 'umount', '-f', mnt_dir ]
     else:
         cmd = [pjoin(basename, 'util', 'fusermount3'),
@@ -56,7 +56,7 @@ def cleanup(mnt_dir):
 
 def umount(mount_process, mnt_dir):
 
-    if 'bsd' in sys.platform:
+    if 'bsd' in sys.platform or 'dragonfly' in sys.platform:
         cmdline = [ 'umount', mnt_dir ]
     else:
         # fusermount3 will be setuid root, so we can only trace it with
@@ -109,7 +109,7 @@ def fuse_test_marker():
 
     skip = lambda x: pytest.mark.skip(reason=x)
 
-    if 'bsd' in sys.platform:
+    if 'bsd' in sys.platform or 'dragonfly' in sys.platform:
         return pytest.mark.uses_fuse()
 
     with subprocess.Popen(['which', 'fusermount3'], stdout=subprocess.PIPE,