[PATCH 29] Re: Disabling Python Modules

Stefan Metzmacher metze at samba.org
Wed Jan 25 08:29:05 UTC 2017


Hi Ian,

> I can't be certain, but I think that may indeed be the last of them.
> All wscript_build files that contain modules with deps= including
> py*util, and LIBPYTHON, are now all covered.

I know I'm late in the discussion, but is there a chance
that we could avoid all changes like this:

-bld.SAMBA3_PYTHON('pys3param',
+if not bld.env.disable_python:
+    bld.SAMBA3_PYTHON('pys3param',

And just to that globally within SAMBA_PYTHON()
instead of changing each caller?
The same applies to CHECK_BUNDLED_SYSTEM_PYTHON()
and SAMBA_CHECK_PYTHON_HEADERS()

For all others we should use something like
enabled=bld.PYTHON_BUILD_IS_ENABLED(),
see git grep 'enabled=' for examples.

I think we should also have the --disable-python option
near to the --extra-python option within
buildtools/wafsamba/wscript, so that it is also available
for the standalone builds of talloc, tevent, tdb and ldb.

For the samba build I think --disable-python give an error
unless --without-ad-dc is also given as an ad-dc really requires
python bindings.

And finally we need this checked in script/autobuild.py in order
to prevent future regressions, maybe more or less a copy of
the "samba-libs" task (as "samba-nopython")
just with other configure options, e.g.

samba_nopython_configure_libs = samba_libs_envvars + " ./configure
--abi-check --enable-debug --picky-developer -C ${PREFIX} --disable-python"
samba_nopython_configure_samba = samba_nopython_configure_libs + "
--without-ad-dc"

I hope the changes make some sense to you and don't cause to much pain.

Thanks!
metze

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20170125/759ed1a5/signature.sig>


More information about the samba-technical mailing list