diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2014-10-12 15:48:53 -0700 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2014-10-14 06:44:06 +0200 |
commit | 8bf60364828c7b3b1d8f6d79b6834bc5a8ed4339 (patch) | |
tree | aa59051df9365498f5015f2f9663a67374966d68 | |
parent | 2cdf55354593dd96120ea34929f4be7133f0e230 (diff) | |
download | samba-8bf60364828c7b3b1d8f6d79b6834bc5a8ed4339.tar.gz |
Fix pydoctor invocation.
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10754
Change-Id: I1ca311dcba52350dc284439119a8166dee1de50a
-rw-r--r-- | wscript | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -263,14 +263,18 @@ def pydoctor(ctx): '''build python apidocs''' bp = os.path.abspath('bin/python') mpaths = {} - for m in ['talloc', 'tdb', 'ldb', 'ntdb']: + modules = ['talloc', 'tdb', 'ldb', 'ntdb'] + for m in modules: f = os.popen("PYTHONPATH=%s python -c 'import %s; print %s.__file__'" % (bp, m, m), 'r') try: mpaths[m] = f.read().strip() finally: f.close() - cmd='PYTHONPATH=%s pydoctor --introspect-c-modules --project-name=Samba --project-url=http://www.samba.org --make-html --docformat=restructuredtext --add-package bin/python/samba --add-module %s --add-module %s --add-module %s' % ( - bp, mpaths['tdb'], mpaths['ldb'], mpaths['talloc'], mpaths['ntdb']) + mpaths['main'] = bp + cmd = ('PYTHONPATH=%(main)s pydoctor --introspect-c-modules --project-name=Samba ' + '--project-url=http://www.samba.org --make-html --docformat=restructuredtext ' + '--add-package bin/python/samba ' + ''.join('--add-module %s ' % n for n in modules)) + cmd = cmd % mpaths print("Running: %s" % cmd) status = os.system(cmd) if os.WEXITSTATUS(status): |