ctdb-build: Improve platform check
authorAmitay Isaacs <amitay@gmail.com>
Mon, 15 Sep 2014 05:55:27 +0000 (15:55 +1000)
committerMartin Schwenke <martins@samba.org>
Wed, 17 Sep 2014 05:29:10 +0000 (07:29 +0200)
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
ctdb/wscript

index b615eb0fdea0eeee52e73733c8b9e7302c75f213..8cb70a3f0efd8f5f219775c7b0079271f0f0806c 100755 (executable)
@@ -217,11 +217,11 @@ def build(bld):
                         includes='include include/internal',
                         deps='replace tevent tdb')
 
-    if sys.platform == 'linux2':
+    if sys.platform.startswith('linux'):
         CTDB_SYSTEM_SRC = bld.SUBDIR('common', 'system_linux.c')
-    elif sys.platform == 'aix':
+    elif sys.platform.startswith('aix'):
         CTDB_SYSTEM_SRC = bld.SUBDIR('common', 'system_aix.c')
-    elif sys.platform == 'freebsd':
+    elif sys.platform.startswith('freebsd'):
         CTDB_SYSTEM_SRC = bld.SUBDIR('common', 'system_freebsd.c')
     elif sys.platform == 'kfreebsd':
         CTDB_SYSTEM_SRC = bld.SUBDIR('common', 'system_kfreebsd.c')