--- /dev/null
+#!/usr/bin/env python
+
+import os
+
+# work out what python external libraries we need to install
+external_libs = {
+ "dns.resolver": "dnspython/dns",
+ "iso8601": "pyiso8601/iso8601",
+ }
+
+
+def configure(conf):
+ conf.RECURSE('popt')
+ conf.RECURSE('zlib')
+
+
+def build(bld):
+ list = []
+
+ for module, package in external_libs.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('zlib')
+ bld.RECURSE('popt')
+++ /dev/null
-#!/usr/bin/env python
-
-import os
-
-# work out what python external libraries we need to install
-external_libs = {
- "dns.resolver": "dnspython/dns",
- "iso8601": "pyiso8601",
- }
-
-list = []
-
-for module, package in external_libs.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('zlib')
-bld.RECURSE('popt')
conf.RECURSE('dynconfig')
if conf.CHECK_FOR_THIRD_PARTY():
- conf.RECURSE('third_party/zlib')
- conf.RECURSE('third_party/popt')
+ conf.RECURSE('third_party')
else:
if not conf.CHECK_ZLIB():
raise Utils.WafError('zlib development packages have not been found.\nIf third_party is installed, check that it is in the proper place.')