summaryrefslogtreecommitdiffstats
path: root/doc/SConscript
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2002-04-04 09:07:00 (GMT)
committerSteven Knight <knight@baldmt.com>2002-04-04 09:07:00 (GMT)
commit6603cc0d6643e529da45fef6f85fcc1a0fc02ea4 (patch)
tree4a27de7c3fd70e5af0f257ccc73aab38e343f156 /doc/SConscript
parenta7669bc6a02999a3375c7e732a27ded5f9bb9935 (diff)
downloadSCons-6603cc0d6643e529da45fef6f85fcc1a0fc02ea4.zip
SCons-6603cc0d6643e529da45fef6f85fcc1a0fc02ea4.tar.gz
SCons-6603cc0d6643e529da45fef6f85fcc1a0fc02ea4.tar.bz2
Fix --debug=tree for directory targets (Anthony Roach)
Diffstat (limited to 'doc/SConscript')
-rw-r--r--doc/SConscript40
1 files changed, 16 insertions, 24 deletions
diff --git a/doc/SConscript b/doc/SConscript
index f0cc97f..898f370 100644
--- a/doc/SConscript
+++ b/doc/SConscript
@@ -71,7 +71,7 @@ format_re = re.compile(r'<(?:graphic|imagedata)\s+fileref="([^"]*)"(?:\s+format=
# defined as a SYSTEM entity is, in fact, a file included
# somewhere in the document.
#
-def scansgml(node, env, argument = None):
+def scansgml(node, env, target):
includes = []
contents = node.get_contents()
@@ -83,12 +83,22 @@ def scansgml(node, env, argument = None):
file, format = m
if format and file[-len(format):] != format:
file = file + format
- if argument and not os.path.isabs(file):
- file = os.path.join(argument, file)
+ if not os.path.isabs(file):
+ a = []
+ f = file
+ while 1:
+ f, tail = os.path.split(f)
+ if tail == 'doc':
+ break
+ a = [tail] + a
+ file = apply(os.path.join, a, {})
includes.append(file)
return includes
+s = Scanner(name = 'sgml', function = scansgml, skeys = ['.sgml', '.mod'])
+env = env.Copy(SCANNERS = [s])
+
if jw:
#
# Always create a version.sgml file containing the version information
@@ -119,9 +129,6 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT.
'ps' : 1,
'pdf' : 1,
'text' : 0,
- 'scan' : Scanner(name = 'design',
- function = scansgml,
- argument = 'design'),
},
'python10' : {
'htmlindex' : 't1.html',
@@ -130,19 +137,13 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT.
'pdf' : 0,
'text' : 0,
'graphics' : [ 'arch', 'builder', 'job-task', 'node', 'scanner', 'sig' ],
- 'scan' : Scanner(name = 'python10',
- function = scansgml,
- argument = 'python10'),
},
'user' : {
'htmlindex' : 'book1.html',
- 'html' : 0,
- 'ps' : 0,
- 'pdf' : 0,
+ 'html' : 1,
+ 'ps' : 1,
+ 'pdf' : 1,
'text' : 0,
- 'scan' : Scanner(name = 'user',
- function = scansgml,
- argument = 'user'),
},
}
@@ -155,11 +156,6 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT.
'copyright.sgml',
]
- s = Scanner(name = 'sgml', function = scansgml)
-
- for sgml in included_sgml:
- File(sgml).scanner_set(s)
-
#
# For each document, build the document itself in HTML, Postscript,
# and PDF formats.
@@ -175,10 +171,6 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT.
pdf = os.path.join('PDF', 'scons-%s.pdf' % doc)
text = os.path.join('TEXT', 'scons-%s.txt' % doc)
- s = docs[doc].get('scan')
- if s:
- File(main).scanner_set(s)
-
if docs[doc].get('html') and jade:
cmds = [
"rm -f ${TARGET.dir}/*.html",