diff options
author | 2015-08-10 18:05:45 +0300 | |
---|---|---|
committer | 2015-08-10 18:05:45 +0300 | |
commit | be48c668a6c24c5c3d7b8a749719b508e855ced3 (patch) | |
tree | 78ba82c46b30dcd64e74ba7d902dbe08f612f679 /wscript | |
parent | a85c8d3d5247319c8e50ee62e19993d5ad9b5e31 (diff) |
added control plane build method
Diffstat (limited to 'wscript')
-rwxr-xr-x | wscript | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -10,6 +10,8 @@ VERSION='0.0.1' APPNAME='wafdocs' import os, re, shutil +import shlex +import subprocess top = '.' @@ -117,6 +119,19 @@ def do_visio(bld): for x in bld.path.ant_glob('visio\\*.vsd'): tg = bld(rule='${VIS} -i ${SRC} -o ${TGT} ', source=x, target=x.change_ext('.png')) +def build_cp_docs (trex_src_dir, dest_dir = "_build", builder = "html"): + build_doc_cmd = shlex.split("/usr/local/bin/sphinx-build -b {bld} {src} {dst}".format( + bld= builder, + src= ".", + dst= dest_dir) + ) + bld_path = os.path.abspath( os.path.join(trex_src_dir, 'automation', 'trex_control_plane', 'doc') ) + ret_val = subprocess.call(build_doc_cmd, cwd = bld_path) + if ret_val: + raise RuntimeError("Build operation of control plain docs failed with return value {ret}".format(ret= ret_val)) + return + + def build(bld): bld(rule=my_copy, target='symbols.lang') |