From cd8de1581919dc9df43f3e2c6e045447129f49bc Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 29 Mar 2010 17:12:04 +1100 Subject: s4-waf: added pydoctor and wafdocs targets these generate html documentation for the Samba python code You need a very recent version of pydoctor --- source4/wscript | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'source4') diff --git a/source4/wscript b/source4/wscript index e662d0db92..09ce8a3ccc 100644 --- a/source4/wscript +++ b/source4/wscript @@ -93,3 +93,23 @@ def ctags(ctx): def build(bld): '''build all targets''' pass + + +def pydoctor(ctx): + '''build python apidocs''' + cmd='LD_LIBRARY_PATH=bin/shared PYTHONPATH=bin/python pydoctor --project-name=Samba --project-url=http://www.samba.org --make-html --docformat=restructuredtext --add-package bin/python/samba' + print "Running: %s" % cmd + os.system(cmd) + +def wafdocs(ctx): + '''build wafsamba apidocs''' + from samba_utils import recursive_dirlist + os.system('pwd') + list = recursive_dirlist('../buildtools/wafsamba', '.', pattern='*.py') + + cmd='LD_LIBRARY_PATH=bin/shared PYTHONPATH=bin/python pydoctor --project-name=wafsamba --project-url=http://www.samba.org --make-html --docformat=restructuredtext' + print list + for f in list: + cmd += ' --add-module %s' % f + print "Running: %s" % cmd + os.system(cmd) -- cgit