summaryrefslogtreecommitdiff
path: root/third_party/wscript
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2020-08-17 17:14:25 +1200
committerAndrew Bartlett <abartlet@samba.org>2020-08-20 22:49:26 +0000
commit091e11260d66a6a038aee08f2fed4fc1711aa03b (patch)
tree5536fd432845aa14c86887a52adef37e34aee921 /third_party/wscript
parent0573c13da2c7f4ac67f4b17c278fa42d65ac857b (diff)
downloadsamba-091e11260d66a6a038aee08f2fed4fc1711aa03b.tar.gz
Remove pyiso8601 from third_party
The trend has been to remove widely available packages from third_party/ This module is both widely available, and only needed for --enable-selftest It is, strangely enough, a BuildDependes in the RHEL/Fedora packages just to stop it being installed in third_party. The check for iso8601 being available is moved to python/wscript Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: David Mulder <dmulder@suse.com>
Diffstat (limited to 'third_party/wscript')
-rw-r--r--third_party/wscript64
1 files changed, 1 insertions, 63 deletions
diff --git a/third_party/wscript b/third_party/wscript
index 3185f90b796..1f4bc1ce1d7 100644
--- a/third_party/wscript
+++ b/third_party/wscript
@@ -1,51 +1,8 @@
#!/usr/bin/env python
-import os
-import sys
-import samba_git
-from waflib import Options, Errors
-
-# work out what python external libraries we need to install
-external_pkgs = {
- "iso8601": "pyiso8601/iso8601",
- }
-
-
-def find_third_party_module(conf, module, package):
- conf.COMPOUND_START("Checking for third party Python module %s" % module)
- try:
- __import__(module)
- except ImportError:
- pass
- else:
- # Installed on the system
- conf.COMPOUND_END("system")
-
- old_path = sys.path
- try:
- sys.path.append(os.path.join(conf.path.abspath(), os.path.dirname(package)))
- try:
- __import__(module)
- except ImportError:
- if samba_git.has_submodules(conf.srcnode.abspath()):
- raise Errors.WafError("""\
-Unable to find Python module '%s'. Please install the system package or check \
-out the relevant submodule by running 'git submodule update --init'.
-""" % module)
- else:
- raise Errors.WafError("""\
-Unable to find Python module '%s'. Please install the system package or place a copy in
-%s.
-""" % (module, package))
- else:
- conf.COMPOUND_END("bundled")
- finally:
- sys.path = old_path
-
+from waflib import Options
def configure(conf):
- for module, package in external_pkgs.items():
- find_third_party_module(conf, module, package)
conf.RECURSE('cmocka')
conf.RECURSE('popt')
conf.RECURSE('aesni-intel')
@@ -59,25 +16,6 @@ def configure(conf):
def build(bld):
- if not bld.env.disable_python:
- list = []
-
- for module, package in external_pkgs.items():
- try:
- __import__(module)
- except ImportError:
- list.append(package)
-
- for e in list:
- bld.INSTALL_WILDCARD('${PYTHONARCHDIR}/samba/third_party', e + '/**/*', flat=False,
- exclude='*.pyc', trim_path=os.path.dirname(e))
-
- bld.SAMBA_GENERATOR('third_party_init_py',
- rule='touch ${TGT}',
- target='empty_file')
-
- bld.INSTALL_FILES('${PYTHONARCHDIR}/samba/third_party', 'empty_file', destname='__init__.py')
-
bld.RECURSE('cmocka')
bld.RECURSE('popt')
bld.RECURSE('aesni-intel')