Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2009-04-20 01:26:29 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2009-04-20 01:26:29 +0400
commitfcdbbee208fb64e9f0696843a69726de3c0d36b8 (patch)
tree2878620435889c834da68545483f511ce0c7967f
parentf5fc4ebdd8ede5263f4b34f161ebe139d40466dc (diff)
SCons / epydoc support
* properly detect if epydoc is installed. patch by Brandano
-rw-r--r--SConstruct9
-rw-r--r--source/blender/python/api2_2x/doc/SConscript40
-rw-r--r--source/gameengine/PyDoc/SConscript40
3 files changed, 43 insertions, 46 deletions
diff --git a/SConstruct b/SConstruct
index 6cc3fcb811d..3cdb5aeace7 100644
--- a/SConstruct
+++ b/SConstruct
@@ -616,6 +616,11 @@ if not env['WITHOUT_BF_INSTALL']:
#------------ EPYDOC
if env['WITH_BF_DOCS']:
- SConscript('source/blender/python/api2_2x/doc/SConscript')
- SConscript('source/gameengine/PyDoc/SConscript')
+ try:
+ import epydoc
+ SConscript('source/blender/python/api2_2x/doc/SConscript')
+ SConscript('source/gameengine/PyDoc/SConscript')
+ except ImportError:
+ print "No epydoc install detected, Python API and Gameengine API Docs will not be generated "
+
diff --git a/source/blender/python/api2_2x/doc/SConscript b/source/blender/python/api2_2x/doc/SConscript
index eca5d9a615c..4e2c72ba502 100644
--- a/source/blender/python/api2_2x/doc/SConscript
+++ b/source/blender/python/api2_2x/doc/SConscript
@@ -3,26 +3,22 @@ Import ('env')
from optparse import OptionParser
-try:
- import epydoc
-except ImportError:
- print "No epydoc install detected, Python API Docs will not be generated "
-if epydoc:
- from epydoc.docbuilder import build_doc_index
- from epydoc import cli
- names = env.Glob("source/blender/python/api2_2x/doc/[A-Z]*.py")
- docindex = build_doc_index(names)
- optvalues = cli.OPTION_DEFAULTS
- optvalues["verbose"] = 1
- optvalues["target"] = env["BF_DOCDIR"]+"/BPY_API/"
- optvalues["url"] = "http://www.blender.org"
- optvalues["top"] = "API_intro"
- optvalues["name"] = "Blender"
- optvalues["noprivate"] = 1
- optvalues["noframes"] = 1
- optvalues["names"] = names
- optparser = OptionParser()
- optparser.set_defaults(**optvalues)
- (options, args) = optparser.parse_args([])
- cli.write_html(docindex, options)
+import epydoc
+from epydoc.docbuilder import build_doc_index
+from epydoc import cli
+names = env.Glob("source/blender/python/api2_2x/doc/[A-Z]*.py")
+docindex = build_doc_index(names)
+optvalues = cli.OPTION_DEFAULTS
+optvalues["verbose"] = 1
+optvalues["target"] = env["BF_DOCDIR"]+"/BPY_API/"
+optvalues["url"] = "http://www.blender.org"
+optvalues["top"] = "API_intro"
+optvalues["name"] = "Blender"
+optvalues["noprivate"] = 1
+optvalues["noframes"] = 1
+optvalues["names"] = names
+optparser = OptionParser()
+optparser.set_defaults(**optvalues)
+(options, args) = optparser.parse_args([])
+cli.write_html(docindex, options)
diff --git a/source/gameengine/PyDoc/SConscript b/source/gameengine/PyDoc/SConscript
index ac0b163d7bd..ab1fda8fa85 100644
--- a/source/gameengine/PyDoc/SConscript
+++ b/source/gameengine/PyDoc/SConscript
@@ -3,26 +3,22 @@ Import ('env')
from optparse import OptionParser
-try:
- import epydoc
-except ImportError:
- print "No epydoc install detected, Python API Docs will not be generated "
-if epydoc:
- from epydoc.docbuilder import build_doc_index
- from epydoc import cli
- names = env.Glob("source/gameengine/PyDoc/*.py")
- docindex = build_doc_index(names)
- optvalues = cli.OPTION_DEFAULTS
- optvalues["verbose"] = 1
- optvalues["target"] = env["BF_DOCDIR"]+"/BGE_API/"
- optvalues["url"] = "http://www.blender.org"
- optvalues["top"] = "Game Engine API"
- optvalues["name"] = "Blender"
- optvalues["noprivate"] = 1
- optvalues["noframes"] = 1
- optvalues["names"] = names
- optparser = OptionParser()
- optparser.set_defaults(**optvalues)
- (options, args) = optparser.parse_args([])
- cli.write_html(docindex, options)
+import epydoc
+from epydoc.docbuilder import build_doc_index
+from epydoc import cli
+names = env.Glob("source/gameengine/PyDoc/*.py")
+docindex = build_doc_index(names)
+optvalues = cli.OPTION_DEFAULTS
+optvalues["verbose"] = 1
+optvalues["target"] = env["BF_DOCDIR"]+"/BGE_API/"
+optvalues["url"] = "http://www.blender.org"
+optvalues["top"] = "Game Engine API"
+optvalues["name"] = "Blender"
+optvalues["noprivate"] = 1
+optvalues["noframes"] = 1
+optvalues["names"] = names
+optparser = OptionParser()
+optparser.set_defaults(**optvalues)
+(options, args) = optparser.parse_args([])
+cli.write_html(docindex, options)