diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2010-10-05 00:36:21 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2010-10-05 00:38:35 +0200 |
commit | 5548d3d41e3db378802e614656d3f708a3edd214 (patch) | |
tree | 0cdbf921f456f3f80c13a127246fb168ceac8e18 /source4/lib | |
parent | 6ea99a237d982827accd1e9befe133141083d9cb (diff) | |
download | samba-5548d3d41e3db378802e614656d3f708a3edd214.tar.gz samba-5548d3d41e3db378802e614656d3f708a3edd214.tar.bz2 samba-5548d3d41e3db378802e614656d3f708a3edd214.zip |
Add missing dependencies for com_err.
Diffstat (limited to 'source4/lib')
-rw-r--r-- | source4/lib/ldb/pyldb.c | 2 | ||||
-rwxr-xr-x | source4/lib/ldb/tests/python/api.py | 6 | ||||
-rw-r--r-- | source4/lib/ldb/wscript | 3 |
3 files changed, 10 insertions, 1 deletions
diff --git a/source4/lib/ldb/pyldb.c b/source4/lib/ldb/pyldb.c index 25f4661dce..fe7e8a1f3d 100644 --- a/source4/lib/ldb/pyldb.c +++ b/source4/lib/ldb/pyldb.c @@ -2744,4 +2744,6 @@ void initldb(void) PyModule_AddObject(m, "MessageElement", (PyObject *)&PyLdbMessageElement); PyModule_AddObject(m, "Module", (PyObject *)&PyLdbModule); PyModule_AddObject(m, "Tree", (PyObject *)&PyLdbTree); + + PyModule_AddObject(m, "__version__", PyString_FromString(PACKAGE_VERSION)); } diff --git a/source4/lib/ldb/tests/python/api.py b/source4/lib/ldb/tests/python/api.py index 76de853ac7..b8adbaaf54 100755 --- a/source4/lib/ldb/tests/python/api.py +++ b/source4/lib/ldb/tests/python/api.py @@ -611,6 +611,12 @@ class ModuleTests(unittest.TestCase): self.assertEquals(["init"], ops) +class VersionTests(unittest.TestCase): + + def test_version(self): + self.assertTrue(isinstance(ldb.__version__, str)) + + if __name__ == '__main__': import unittest unittest.TestProgram() diff --git a/source4/lib/ldb/wscript b/source4/lib/ldb/wscript index 226175778e..ddf12835aa 100644 --- a/source4/lib/ldb/wscript +++ b/source4/lib/ldb/wscript @@ -139,7 +139,8 @@ def build(bld): bld.SAMBA_PYTHON('pyldb', 'pyldb.c', deps='ldb pyldb_util', - realname='ldb.so') + realname='ldb.so', + cflags='-DPACKAGE_VERSION=\"%s\"' % VERSION) bld.SAMBA_MODULE('ldb_paged_results', 'modules/paged_results.c', |