2011-09-10 11:13:51 +02:00
|
|
|
#!/usr/bin/env python
|
|
|
|
# encoding: utf-8
|
|
|
|
# Jérôme Carretero, 2010 (zougloub)
|
|
|
|
|
|
|
|
import sys, os
|
|
|
|
from waflib.Utils import subprocess
|
|
|
|
|
|
|
|
"""
|
|
|
|
"""
|
|
|
|
|
|
|
|
top = '.'
|
|
|
|
out = 'build'
|
|
|
|
|
|
|
|
def options(opt):
|
|
|
|
opt.load('daemon', tooldir=['../../playground/daemon/'])
|
|
|
|
|
|
|
|
def configure(cfg):
|
|
|
|
cfg.find_program('dot', var='DOT')
|
|
|
|
cfg.find_program('convert', var='CONVERT')
|
|
|
|
cfg.load('daemon', tooldir=['../../playground/daemon/'])
|
|
|
|
cfg.find_program("sphinx-build", var="SPHINX_BUILD")
|
2015-04-26 21:00:15 +02:00
|
|
|
cfg.env.SPHINX_ARGS = ['-W']
|
2011-09-10 11:13:51 +02:00
|
|
|
|
|
|
|
def build(bld):
|
2015-04-26 21:00:15 +02:00
|
|
|
bld.path.make_node('_static').mkdir()
|
2011-09-10 11:13:51 +02:00
|
|
|
bld(
|
2015-04-26 21:00:15 +02:00
|
|
|
rule = "${SPHINX_BUILD} ${SPHINX_ARGS} -b html -d %s . %s" % (os.path.join(out, "doctrees"), os.path.join(out, "html")),
|
2016-01-16 13:03:09 +01:00
|
|
|
cwd = bld.path,
|
2011-09-10 11:13:51 +02:00
|
|
|
source = bld.path.parent.parent.find_dir('waflib').ant_glob('**/*.py')
|
|
|
|
+ bld.path.ant_glob('**/*.rst')
|
|
|
|
+ bld.path.ant_glob('_templates/indexcontent.html')
|
|
|
|
+ bld.path.ant_glob('conf.py'),
|
|
|
|
target = bld.path.find_or_declare('html/index.html')
|
2015-04-26 21:00:15 +02:00
|
|
|
)
|
2011-09-10 11:13:51 +02:00
|
|
|
|