Remove bundled subunit.
[vlendec/samba-autobuild/.git] / lib / wscript_build
1 #!/usr/bin/env python
2
3 import os, Options
4
5 # work out what python external libraries we need to install
6 external_libs = {
7     "testtools": "testtools/testtools",
8     "extras": "extras/extras",
9     "mimeparse": "mimeparse/mimeparse",
10     }
11
12 list = []
13
14 for module, package in external_libs.items():
15     try:
16         __import__(module)
17     except ImportError:
18         list.append(package)
19
20 for e in list:
21     bld.INSTALL_WILDCARD('${PYTHONARCHDIR}/samba/external', e + '/**/*', flat=False,
22                          exclude='*.pyc', trim_path=os.path.dirname(e))
23
24 bld.SAMBA_GENERATOR('external_init_py',
25                     rule='touch ${TGT}',
26                     target='empty_file')
27
28 bld.INSTALL_FILES('${PYTHONARCHDIR}/samba/external', 'empty_file', destname='__init__.py')
29
30 # a grouping library for event and socket related subsystems
31 bld.SAMBA_LIBRARY('samba-sockets',
32                   source=[],
33                   private_library=True,
34                   grouping_library=True,
35                   deps='LIBTSOCKET samba_socket tevent-util')