waf: disable-python - don't build python/
authorIan Stakenvicius <axs@gentoo.org>
Fri, 27 Jan 2017 21:38:36 +0000 (16:38 -0500)
committerAndrew Bartlett <abartlet@samba.org>
Fri, 10 Mar 2017 06:31:12 +0000 (07:31 +0100)
Signed-off-by: Ian Stakenvicius <axs@gentoo.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
python/wscript_build

index fa3b8b5de179ae69d7f3ea217c5afce9026c8392..87da26f710ffa8bd2c6f60b7ca973427a19083c1 100644 (file)
@@ -5,7 +5,8 @@ bld.SAMBA_LIBRARY('samba_python',
        deps='LIBPYTHON pytalloc-util pyrpc_util',
        grouping_library=True,
        private_library=True,
-       pyembed=True)
+       pyembed=True,
+       enabled=bld.PYTHON_BUILD_IS_ENABLED())
 
 bld.SAMBA_SUBSYSTEM('LIBPYTHON',
        source='modules.c',
@@ -13,7 +14,7 @@ bld.SAMBA_SUBSYSTEM('LIBPYTHON',
        init_function_sentinel='{NULL,NULL}',
        deps='talloc',
        pyext=True,
-       )
+       enabled=bld.PYTHON_BUILD_IS_ENABLED())
 
 for env in bld.gen_python_environments():
        pytalloc_util = bld.pyembed_libname('pytalloc-util')
@@ -25,7 +26,8 @@ for env in bld.gen_python_environments():
                realname='samba/_glue.so'
                )
 
-for env in bld.gen_python_environments():
+if bld.PYTHON_BUILD_IS_ENABLED():
+    for env in bld.gen_python_environments():
        # install out various python scripts for use by make test
        bld.SAMBA_SCRIPT('samba_python_files',
                         pattern='samba/**/*.py',