mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
2c67d55614
Change-Id: I984c82acc0bc82a165e8ea17d8948c465c786905 Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Jelmer Vernooij <jelmer@samba.org> Autobuild-Date(master): Sat Nov 22 04:44:11 CET 2014 on sn-devel-104
37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
#!/usr/bin/env python
|
|
|
|
import os, Options
|
|
|
|
# work out what python external libraries we need to install
|
|
external_libs = {
|
|
"subunit": "subunit/python/subunit",
|
|
"testtools": "testtools/testtools",
|
|
"extras": "extras/extras",
|
|
"mimeparse": "mimeparse/mimeparse",
|
|
}
|
|
|
|
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/external', e + '/**/*', flat=False,
|
|
exclude='*.pyc', trim_path=os.path.dirname(e))
|
|
|
|
bld.SAMBA_GENERATOR('external_init_py',
|
|
rule='touch ${TGT}',
|
|
target='empty_file')
|
|
|
|
bld.INSTALL_FILES('${PYTHONARCHDIR}/samba/external', 'empty_file', destname='__init__.py')
|
|
|
|
# a grouping library for event and socket related subsystems
|
|
bld.SAMBA_LIBRARY('samba-sockets',
|
|
source=[],
|
|
private_library=True,
|
|
grouping_library=True,
|
|
deps='LIBTSOCKET samba_socket tevent-util')
|