From: stevenknight Date: Tue, 15 Feb 2005 13:55:44 +0000 (+0000) Subject: Accumulated documentation changes. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=310567c546721f070fd0266f56ffd343a4522fab;p=scons.git Accumulated documentation changes. git-svn-id: http://scons.tigris.org/svn/scons/trunk@1232 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- diff --git a/bin/SConsDoc.py b/bin/SConsDoc.py new file mode 100644 index 00000000..df28b76d --- /dev/null +++ b/bin/SConsDoc.py @@ -0,0 +1,241 @@ +#!/usr/bin/env python +# +# Module for handling SCons documentation processing. +# +import os.path +import imp +import sys +import xml.sax.handler + +class Item: + def __init__(self, name): + self.name = name + self.sort_name = name.lower() + if self.sort_name[0] == '_': + self.sort_name = self.sort_name[1:] + self.summary = [] + self.uses = None + def cmp_name(self, name): + if name[0] == '_': + name = name[1:] + return name.lower() + def __cmp__(self, other): + return cmp(self.sort_name, other.sort_name) + +class Builder(Item): + pass + +class Tool(Item): + def __init__(self, name): + Item.__init__(self, name) + self.entity = self.name.replace('+', 'X') + +class ConstructionVariable(Item): + pass + +class Chunk: + def __init__(self, tag, body=None): + self.tag = tag + if not body: + body = [] + self.body = body + def __str__(self): + body = ''.join(self.body) + return "<%s>%s\n" % (self.tag, body, self.tag) + def append(self, data): + self.body.append(data) + +class Summary: + def __init__(self): + self.body = [] + self.collect = [] + def append(self, data): + self.collect.append(data) + def end_para(self): + text = ''.join(self.collect) + paras = text.split('\n\n') + if paras == ['\n']: + return + if paras[0] == '': + self.body.append('\n') + paras = paras[1:] + paras[0] = '\n' + paras[0] + if paras[-1] == '': + paras = paras[:-1] + paras[-1] = paras[-1] + '\n' + last = '\n' + else: + last = None + sep = None + for p in paras: + c = Chunk("para", p) + if sep: + self.body.append(sep) + self.body.append(c) + sep = '\n' + if last: + self.body.append(last) + def begin_chunk(self, chunk): + self.end_para() + self.collect = chunk + def end_chunk(self): + self.body.append(self.collect) + self.collect = [] + +class SConsDocHandler(xml.sax.handler.ContentHandler, + xml.sax.handler.ErrorHandler): + def __init__(self): + self._start_dispatch = {} + self._end_dispatch = {} + keys = self.__class__.__dict__.keys() + start_tag_method_names = filter(lambda k: k[:6] == 'start_', keys) + end_tag_method_names = filter(lambda k: k[:4] == 'end_', keys) + for method_name in start_tag_method_names: + tag = method_name[6:] + self._start_dispatch[tag] = getattr(self, method_name) + for method_name in end_tag_method_names: + tag = method_name[4:] + self._end_dispatch[tag] = getattr(self, method_name) + self.stack = [] + self.collect = [] + self.current_object = [] + self.builders = {} + self.tools = {} + self.cvars = {} + + def startElement(self, name, attrs): + try: + start_element_method = self._start_dispatch[name] + except KeyError: + self.characters('<%s>' % name) + else: + start_element_method(attrs) + + def endElement(self, name): + try: + end_element_method = self._end_dispatch[name] + except KeyError: + self.characters('' % name) + else: + end_element_method() + + # + # + def characters(self, chars): + self.collect.append(chars) + + def begin_collecting(self, chunk): + self.collect = chunk + def end_collecting(self): + self.collect = [] + + def begin_chunk(self): + pass + def end_chunk(self): + pass + + # + # + # + + def begin_xxx(self, obj): + self.stack.append(self.current_object) + self.current_object = obj + def end_xxx(self): + self.current_object = self.stack.pop() + + # + # + # + def start_scons_doc(self, attrs): + pass + def end_scons_doc(self): + pass + + def start_builder(self, attrs): + name = attrs.get('name') + try: + builder = self.builders[name] + except KeyError: + builder = Builder(name) + self.builders[name] = builder + self.begin_xxx(builder) + def end_builder(self): + self.end_xxx() + + def start_tool(self, attrs): + name = attrs.get('name') + try: + tool = self.tools[name] + except KeyError: + tool = Tool(name) + self.tools[name] = tool + self.begin_xxx(tool) + def end_tool(self): + self.end_xxx() + + def start_cvar(self, attrs): + name = attrs.get('name') + try: + cvar = self.cvars[name] + except KeyError: + cvar = ConstructionVariable(name) + self.cvars[name] = cvar + self.begin_xxx(cvar) + def end_cvar(self): + self.end_xxx() + + def start_summary(self, attrs): + summary = Summary() + self.current_object.summary = summary + self.begin_xxx(summary) + self.begin_collecting(summary) + def end_summary(self): + self.current_object.end_para() + self.end_xxx() + + def start_example(self, attrs): + example = Chunk("programlisting") + self.current_object.begin_chunk(example) + def end_example(self): + self.current_object.end_chunk() + + def start_uses(self, attrs): + self.begin_collecting([]) + def end_uses(self): + self.current_object.uses = ''.join(self.collect).split() + self.end_collecting() + + # Stuff for the ErrorHandler portion. + def error(self, exception): + linenum = exception._linenum - self.preamble_lines + sys.stderr.write('%s:%d:%d: %s (error)\n' % (self.filename, linenum, exception._colnum, ''.join(exception.args))) + + def fatalError(self, exception): + linenum = exception._linenum - self.preamble_lines + sys.stderr.write('%s:%d:%d: %s (fatalError)\n' % (self.filename, linenum, exception._colnum, ''.join(exception.args))) + + def set_file_info(self, filename, preamble_lines): + self.filename = filename + self.preamble_lines = preamble_lines + +# lifted from Ka-Ping Yee's way cool pydoc module. +def importfile(path): + """Import a Python source file or compiled file given its path.""" + magic = imp.get_magic() + file = open(path, 'r') + if file.read(len(magic)) == magic: + kind = imp.PY_COMPILED + else: + kind = imp.PY_SOURCE + file.close() + filename = os.path.basename(path) + name, ext = os.path.splitext(filename) + file = open(path, 'r') + try: + module = imp.load_module(name, file, path, (ext, 'r', kind)) + except ImportError, e: + sys.stderr.write("Could not import %s: %s\n" % (path, e)) + return None + file.close() + return module diff --git a/bin/scons-proc.py b/bin/scons-proc.py new file mode 100644 index 00000000..809c3d04 --- /dev/null +++ b/bin/scons-proc.py @@ -0,0 +1,195 @@ +#!/usr/bin/env python +# +# Process a list of Python and/or XML files containing SCons documentation. +# +# Depending on the options, this script creates DocBook-formatted lists +# of the Builders, Tools or construction variables in generated SGML +# files containing the summary text and/or .mod files contining the +# ENTITY definitions for each item. +# +import getopt +import os.path +import re +import string +import StringIO +import sys +import xml.sax + +import SConsDoc + +base_sys_path = [os.getcwd() + '/build/test-tar-gz/lib/scons'] + sys.path + +helpstr = """\ +Usage: scons-varlist.py [-b .gen,.mod] [-t .gen,.mod] [-v .gen,.mod] [infile] +Options: + -m, --modfile .mod file to hold Builder entities +""" + +opts, args = getopt.getopt(sys.argv[1:], + "b:t:v:", + ['builders=', 'tools=', 'variables=']) + +buildersfiles = None +toolsfiles = None +variablesfiles = None + +for o, a in opts: + if o == '-b' or o == '--builders': + buildersfiles = a + elif o == '-t' or o == '--tools': + toolsfiles = a + elif o == '-v' or o == '--variables': + variablesfiles = a + +h = SConsDoc.SConsDocHandler() +saxparser = xml.sax.make_parser() +saxparser.setContentHandler(h) +saxparser.setErrorHandler(h) + +preamble = """\ + + +""" + +postamble = """\ + +""" + +for f in args: + _, ext = os.path.splitext(f) + if ext == '.py': + dir, _ = os.path.split(f) + if dir: + sys.path = [dir] + base_sys_path + module = SConsDoc.importfile(f) + h.set_file_info(f, len(preamble.split('\n'))) + try: + content = module.__scons_doc__ + except AttributeError: + content = None + else: + del module.__scons_doc__ + else: + h.set_file_info(f, len(preamble.split('\n'))) + content = open(f).read() + if content: + content = content.replace('&', '&') + input = preamble + content + postamble + try: + saxparser.parse(StringIO.StringIO(input)) + except: + sys.stderr.write("error in %s\n" % f) + raise + +Warning = """\ + +""" + +Regular_Entities_Header = """\ + +""" + +Link_Entities_Header = """\ + +""" + +class XXX: + def __init__(self, entries, **kw): + values = entries.values() + values.sort() + self.values = values + for k, v in kw.items(): + setattr(self, k, v) + def write_gen(self, filename): + if not filename: + return + f = open(filename, 'w') + for v in self.values: + f.write('\n\n' % + (self.prefix, self.idfunc(v.name))) + for term in self.termfunc(v.name): + f.write('<%s>%s\n' % + (self.tag, term, self.tag)) + f.write('\n') + for chunk in v.summary.body: + f.write(str(chunk)) + #if v.uses: + # u = map(lambda x, s: '&%slink-%s;' % (s.prefix, x), v.uses) + # f.write('\n') + # f.write('Uses: ' + ', '.join(u) + '.\n') + # f.write('\n') + f.write('\n') + f.write('\n') + def write_mod(self, filename): + if not filename: + return + f = open(filename, 'w') + f.write(Warning) + f.write('\n') + f.write(Regular_Entities_Header % self.description) + f.write('\n') + for v in self.values: + f.write('%s">\n' % + (self.prefix, self.idfunc(v.name), + self.tag, self.entityfunc(v.name), self.tag)) + f.write('\n') + f.write(Warning) + f.write('\n') + f.write(Link_Entities_Header % self.description) + f.write('\n') + for v in self.values: + f.write('<%s>%s\'>\n' % + (self.prefix, self.idfunc(v.name), + self.prefix, self.idfunc(v.name), + self.tag, self.entityfunc(v.name), self.tag)) + f.write('\n') + f.write(Warning) + +if buildersfiles: + g = XXX(h.builders, + description = 'builder', + prefix = 'b-', + tag = 'function', + idfunc = lambda x: x, + termfunc = lambda x: [x+'()', 'env.'+x+'()'], + entityfunc = lambda x: x) + + gen, mod = string.split(buildersfiles, ',') + g.write_gen(gen) + g.write_mod(mod) + +if toolsfiles: + g = XXX(h.tools, + description = 'tool', + prefix = 't-', + tag = 'literal', + idfunc = lambda x: string.replace(x, '+', 'X'), + termfunc = lambda x: [x], + entityfunc = lambda x: x) + + gen, mod = string.split(toolsfiles, ',') + g.write_gen(gen) + g.write_mod(mod) + +if variablesfiles: + g = XXX(h.cvars, + description = 'construction variable', + prefix = 'cv-', + tag = 'envar', + idfunc = lambda x: x, + termfunc = lambda x: [x], + entityfunc = lambda x: '$'+x) + + gen, mod = string.split(variablesfiles, ',') + g.write_gen(gen) + g.write_mod(mod) diff --git a/bin/sconsoutput.py b/bin/sconsoutput.py index 3ca8a32d..974646c4 100644 --- a/bin/sconsoutput.py +++ b/bin/sconsoutput.py @@ -23,7 +23,7 @@ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # -__revision__ = "src/sconsoutput.py 0.D003 2003/09/22 22:17:34 software" +__revision__ = "/home/scons/sconsoutput/branch.0/baseline/src/sconsoutput.py 0.4.D001 2004/11/27 18:44:37 knight" # # sconsoutput.py - an SGML preprocessor for capturing SCons output @@ -76,14 +76,14 @@ __revision__ = "src/sconsoutput.py 0.D003 2003/09/22 22:17:34 software" # SCons output is generated from the following sort of tag: # # -# scons -Q foo -# scons -Q foo +# scons -Q foo +# scons -Q foo # # -# You tell it which example to use with the "example" attribute, and -# then give it a list of tags to execute. You can also supply -# an "os" tag, which specifies the type of operating system this example -# is intended to show; if you omit this, default value is "posix". +# You tell it which example to use with the "example" attribute, and then +# give it a list of tags to execute. You can also +# supply an "os" tag, which specifies the type of operating system this +# example is intended to show; if you omit this, default value is "posix". # # The generated SGML will show the command line (with the appropriate # command-line prompt for the operating system), execute the command in @@ -194,7 +194,7 @@ import SCons.Action import SCons.Defaults import SCons.Node.FS -platform = '%s' +platform = '%(osname)s' Sep = { 'posix' : '/', @@ -263,6 +263,10 @@ class ToolSurrogate: env[v] = SCons.Action.Action(self.func, strfunction=strfunction, varlist=self.varlist) + def __repr__(self): + # This is for the benefit of printing the 'TOOLS' + # variable through env.Dump(). + return repr(self.tool) def Null(target, source, env): pass @@ -365,7 +369,12 @@ ToolList = { ], } -tools = map(lambda t: apply(ToolSurrogate, t), ToolList[platform]) +toollist = ToolList[platform] +filter_tools = string.split('%(tools)s') +if filter_tools: + toollist = filter(lambda x, ft=filter_tools: x[0] in ft, toollist) + +toollist = map(lambda t: apply(ToolSurrogate, t), toollist) def surrogate_spawn(sh, escape, cmd, args, env): pass @@ -375,7 +384,7 @@ def surrogate_pspawn(sh, escape, cmd, args, env, stdout, stderr): SCons.Defaults.ConstructionEnvironment.update({ 'PLATFORM' : platform, - 'TOOLS' : tools, + 'TOOLS' : toollist, 'SPAWN' : surrogate_spawn, 'PSPAWN' : surrogate_pspawn, }) @@ -384,7 +393,7 @@ SConscript('SConstruct') """ # "Commands" that we will execute in our examples. -def command_scons(args, c, test, osname): +def command_scons(args, c, test, dict): save_vals = {} delete_keys = [] try: @@ -403,7 +412,7 @@ def command_scons(args, c, test, osname): program = scons_py, arguments = '-f - ' + string.join(args), chdir = test.workpath('WORK'), - stdin = Stdin % osname) + stdin = Stdin % dict) os.environ.update(save_vals) for key in delete_keys: del(os.environ[key]) @@ -417,7 +426,7 @@ def command_scons(args, c, test, osname): # sys.stderr.write(err) return lines -def command_touch(args, c, test, osname): +def command_touch(args, c, test, dict): time.sleep(1) for file in args: if not os.path.isabs(file): @@ -427,7 +436,7 @@ def command_touch(args, c, test, osname): os.utime(file, None) return [] -def command_edit(args, c, test, osname): +def command_edit(args, c, test, dict): try: add_string = c.edit[:] except AttributeError: @@ -441,7 +450,7 @@ def command_edit(args, c, test, osname): open(file, 'wb').write(contents + add_string) return [] -def command_ls(args, c, test, osname): +def command_ls(args, c, test, dict): def ls(a): files = os.listdir(a) files = filter(lambda x: x[0] != '.', files) @@ -462,12 +471,12 @@ CommandDict = { 'ls' : command_ls, } -def ExecuteCommand(args, c, t, osname): +def ExecuteCommand(args, c, t, dict): try: func = CommandDict[args[0]] except KeyError: - func = lambda args, c, t, osname: [] - return func(args[1:], c, t, osname) + func = lambda args, c, t, dict: [] + return func(args[1:], c, t, dict) class MySGML(sgmllib.SGMLParser): """A subclass of the standard Python 2.2 sgmllib SGML parser. @@ -647,6 +656,7 @@ class MySGML(sgmllib.SGMLParser): o = Output() o.preserve = None o.os = 'posix' + o.tools = '' o.e = e # Locally-set. for name, value in attrs: @@ -706,11 +716,16 @@ class MySGML(sgmllib.SGMLParser): e = string.replace(c.data, '__ROOT__', t.workpath('ROOT')) args = string.split(e) - lines = ExecuteCommand(args, c, t, o.os) + lines = ExecuteCommand(args, c, t, {'osname':o.os, 'tools':o.tools}) + content = None if c.output: - sys.stdout.write(p + c.output + '\n') + content = c.output elif lines: - sys.stdout.write(p + string.join(lines, '\n' + p) + '\n') + content = string.join(lines, '\n' + p) + if content: + content = string.replace(content, '<', '<') + content = string.replace(content, '>', '>') + sys.stdout.write(p + content + '\n') if o.data[0] == '\n': o.data = o.data[1:] @@ -718,11 +733,11 @@ class MySGML(sgmllib.SGMLParser): delattr(self, 'o') self.afunclist = self.afunclist[:-1] - def start_command(self, attrs): + def start_scons_output_command(self, attrs): try: o = self.o except AttributeError: - self.error(" tag outside of ") + self.error(" tag outside of ") try: o.prefix except AttributeError: @@ -734,7 +749,7 @@ class MySGML(sgmllib.SGMLParser): o.commandlist.append(c) self.afunclist.append(c.afunc) - def end_command(self): + def end_scons_output_command(self): self.o.data = "" self.afunclist = self.afunclist[:-1] diff --git a/doc/SConscript b/doc/SConscript index 0dd41d1e..008f2058 100644 --- a/doc/SConscript +++ b/doc/SConscript @@ -31,6 +31,10 @@ import string Import('env', 'whereis') +env = env.Copy() + +env.TargetSignatures('content') + build = os.path.join('#build', 'doc') # @@ -97,8 +101,28 @@ def scansgml(node, env, target): return includes s = Scanner(name = 'sgml', function = scansgml, skeys = ['.sgml', '.mod']) + orig_env = env -env = orig_env.Copy(SCANNERS = [s]) +env = orig_env.Copy(SCANNERS = [s], + SCONS_PROC_PY = File('#bin/scons-proc.py').rfile(), + SCONSOUTPUT_PY = File('#bin/sconsoutput.py').rfile()) + +# Fetch the list of files in the build engine that contain +# SCons documentation XML for processing. +def chop(s): return s[:-1] + +# If we ever read doc from __scons_doc__ strings in *.py files again, +# here's how it's done: +#manifest_in = File('#src/engine/MANIFEST.in').rstr() +#manifest_xml_in = File('#src/engine/MANIFEST-xml.in').rstr() +#scons_doc_files = map(chop, open(manifest_in).readlines() +\ +# open(manifest_xml_in).readlines()) +#scons_doc_files = map(lambda x: '#src/engine/'+x, scons_doc_files) +#manifest_in = File('#src/engine/MANIFEST.in').rstr() + +manifest_xml_in = File('#src/engine/MANIFEST-xml.in').rstr() +scons_doc_files = map(chop, open(manifest_xml_in).readlines()) +scons_doc_files = map(lambda x: File('#src/engine/'+x).rstr(), scons_doc_files) if jw: # @@ -127,6 +151,20 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. """ % (date, ver, rev)) + builders_gen = os.path.join(build, 'user', 'builders.gen') + builders_mod = os.path.join(build, 'user', 'builders.mod') + tools_gen = os.path.join(build, 'user', 'tools.gen') + tools_mod = os.path.join(build, 'user', 'tools.mod') + variables_gen = os.path.join(build, 'user', 'variables.gen') + variables_mod = os.path.join(build, 'user', 'variables.mod') + + b = env.Command([builders_gen, builders_mod, + tools_gen, tools_mod, + variables_gen, variables_mod], + scons_doc_files, + "python $SCONS_PROC_PY -b ${TARGETS[0]},${TARGETS[1]} -t ${TARGETS[2]},${TARGETS[3]} -v ${TARGETS[4]},${TARGETS[5]} $SOURCES") + env.Depends(b, "$SCONS_PROC_PY") + # # Each document will live in its own subdirectory. List them here # as hash keys, with a hash of the info to control its build. @@ -138,21 +176,24 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. 'pdf' : 1, 'text' : 0, }, - 'python10' : { - 'htmlindex' : 't1.html', - 'html' : 1, - 'ps' : 1, - 'pdf' : 0, - 'text' : 0, - 'graphics' : [ - 'arch.fig', - 'builder.fig', - 'job-task.fig', - 'node.fig', - 'scanner.fig', - 'sig.fig' - ], - }, + # This doesn't build on all systems, and the document is old + # enough that there's reallyno need to build it every time any + # more, so just comment it out for now. + #'python10' : { + # 'htmlindex' : 't1.html', + # 'html' : 1, + # 'ps' : 1, + # 'pdf' : 0, + # 'text' : 0, + # 'graphics' : [ + # 'arch.fig', + # 'builder.fig', + # 'job-task.fig', + # 'node.fig', + # 'scanner.fig', + # 'sig.fig' + # ], + #}, 'reference' : { 'htmlindex' : 'book1.html', 'html' : 1, @@ -172,6 +213,7 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. 'SCons-win32-install-3.jpg', 'SCons-win32-install-4.jpg', ], + 'sconsoutput' : 1, }, } @@ -197,14 +239,20 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. manifest = File(os.path.join(doc, 'MANIFEST')).rstr() src_files = map(lambda x: x[:-1], open(manifest).readlines()) + build_doc = docs[doc].get('sconsoutput') and int(ARGUMENTS.get('BUILDDOC', 0)) for s in src_files: - base, ext = os.path.splitext(s) + doc_s = os.path.join(doc, s) + build_s = os.path.join(build, doc, s) + base, ext = os.path.splitext(doc_s) if ext in ['.fig', '.jpg']: - orig_env.Install(os.path.join(build, doc), os.path.join(doc, s)) + orig_env.InstallAs(build_s, doc_s) else: - orig_env.SCons_revision(os.path.join(build, doc, s), - os.path.join(doc, s)) - Local(os.path.join(build, doc, s)) + if build_doc and ext == '.sgml': + env.Command(doc_s, + base + '.in', + "python $SCONSOUTPUT_PY $SOURCE > $TARGET") + orig_env.SCons_revision(build_s, doc_s) + Local(build_s) main = os.path.join(build, doc, 'main.sgml') out = 'main.out' @@ -247,13 +295,18 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. tar_list.extend([html, htmldir]) for g in docs[doc].get('graphics', []): - if g[-4:] == '.fig' and fig2dev: - fig = os.path.join(build, doc, g) - jpg = os.path.join(htmldir, g[:-4] + '.jpg') - env.Command(jpg, fig, - "%s -L jpeg -q 100 $SOURCES $TARGET" % fig2dev) - env.Depends(html, jpg) - Local(jpg) + base, ext = os.path.splitext(g) + if ext == '.fig': + jpg = base + '.jpg' + htmldir_jpg = os.path.join(htmldir, jpg) + if fig2dev: + fig = os.path.join(build, doc, g) + env.Command(htmldir_jpg, fig, + "%s -L jpeg -q 100 $SOURCES $TARGET" % fig2dev) + else: + env.InstallAs(htmldir_jpg, jpg) + env.Depends(html, htmldir_jpg) + Local(htmldir_jpg) else: src = os.path.join(build, doc, g) Local(env.Install(htmldir, src)) @@ -273,12 +326,17 @@ THIS IS AN AUTOMATICALLY-GENERATED FILE. DO NOT EDIT. tar_list.append(ps) for g in docs[doc].get('graphics', []): - if g[-4:] == '.fig' and fig2dev: - fig = os.path.join(build, doc, g) - eps = os.path.join(build, 'PS', g[:-4] + '.eps') - env.Command(eps, fig, "%s -L eps $SOURCES $TARGET" % fig2dev) - env.Depends(ps, eps) - Local(eps) + base, ext = os.path.splitext(g) + if ext == '.fig': + eps = base + '.eps' + build_eps = os.path.join(build, 'PS', eps) + if fig2dev: + fig = os.path.join(build, doc, g) + env.Command(build_eps, fig, "%s -L eps $SOURCES $TARGET" % fig2dev) + else: + env.InstallAs(build_eps, eps) + env.Depends(ps, build_eps) + Local(build_eps) else: src = os.path.join(build, doc, g) Local(env.Install(htmldir, src)) diff --git a/doc/design/MANIFEST b/doc/design/MANIFEST index 72d78be4..3fb99f08 100644 --- a/doc/design/MANIFEST +++ b/doc/design/MANIFEST @@ -11,3 +11,4 @@ issues.sgml main.sgml native.sgml overview.sgml +scons.mod diff --git a/doc/design/copyright.sgml b/doc/design/copyright.sgml index 3f908a45..d73906e8 100644 --- a/doc/design/copyright.sgml +++ b/doc/design/copyright.sgml @@ -26,7 +26,7 @@
- Copyright (c) 2001, 2002, 2003 Steven Knight + Copyright (c) 2001 Steven Knight Portions of this document, by the same author, were previously published Copyright 2000 by CodeSourcery LLC, under the Software Carpentry diff --git a/doc/design/main.sgml b/doc/design/main.sgml index 6780d2cc..6246a73d 100644 --- a/doc/design/main.sgml +++ b/doc/design/main.sgml @@ -26,10 +26,24 @@ %version; - + --> + + + + + + %scons; diff --git a/doc/design/scons.mod b/doc/design/scons.mod new file mode 100644 index 00000000..58a6576a --- /dev/null +++ b/doc/design/scons.mod @@ -0,0 +1,428 @@ + + + + + + +Aegis"> +Ant"> +Autoconf"> +Automake"> +cc"> +Cons"> +cp"> +csh"> +gcc"> +Jam"> +jar"> +javac"> +javah"> +Make"> +Make++"> +Python"> +ranlib"> +rmic"> +SCons"> +scons"> +ScCons"> +tar"> +touch"> +zip"> + + + + +Action"> +ActionBase"> +CommandAction"> +FunctionAction"> +ListAction"> +Builder"> +BuilderBase"> +CompositeBuilder"> +MultiStepBuilder"> +Job"> +Jobs"> +Serial"> +Parallel"> +Node"> +Node.FS"> +Scanner"> +Sig"> +Signature"> +Taskmaster"> +TimeStamp"> +Walker"> +Wrapper"> + + + + + +--debug=explain"> +--implicit-cache"> +--implicit-deps-changed"> +--implicit-deps-unchanged"> +-Q"> + + + +implicit_cache"> +implicit_deps_changed"> +implicit_deps_unchanged"> + + + + + +build"> +Makefile"> +Makefiles"> +SConscript"> +SConstruct"> +Sconstruct"> +sconstruct"> +.sconsign"> +src"> + + + + + +Add"> +AddOptions"> +Alias"> +Aliases"> +Append"> +BoolOption"> +Build"> +CacheDir"> +Clean"> +Clone"> +Command"> +Configure"> +Copy"> +Default"> +DefaultRules"> +Depends"> +Dir"> +Entry"> +EnumOption"> +Environment"> +Export"> +File"> +Finish"> +GenerateHelpText"> +Help"> +Ignore"> +Import"> +Install"> +InstallAs"> +Link"> +ListOption"> +Local"> +Module"> +Objects"> +Options"> +PackageOption"> +PathOption"> +Precious"> +Prepend"> +Replace"> +Repository"> +Return"> +RuleSet"> +Salt"> +SetBuildSignatureType"> +SetContentSignatureType"> +SourceSignature"> +SourceSignatures"> +Split"> +TargetSignatures"> +Task"> + + +subst"> + + +Message"> +Result"> +CheckCHeader"> +CheckCXXHeader"> +CheckFunc"> +CheckHeader"> +CheckLib"> +CheckLibWithHeader"> +CheckType"> +TryAction"> +TryBuild"> +TryCompile"> +TryLink"> +TryRun"> + + +str"> +zipfile"> + + +Cache"> + + + + + +ARGUMENTS"> +BUILD_TARGETS"> +COMMAND_LINE_TARGETS"> +DEFAULT_TARGETS"> + + + + + +BUILDERMAP"> +BUILDERS"> +CC"> +CCFLAGS"> +CCCOM"> +COLOR"> +COLORS"> +CONFIG"> +CPPDEFINES"> +ENV"> +JAVACLASSDIR"> +LIBDIRPREFIX"> +LIBDIRSUFFIX"> +LIBLINKPREFIX"> +LIBLINKSUFFIX"> +LIBPATH"> +LIBS"> +LINK"> +LINKCOM"> +LINKFLAGS"> +RELEASE"> +RELEASE_BUILD"> +SCANNERMAP"> +SCANNERS"> +TARFLAGS"> +TARSUFFIX"> + + + + + +PATH"> +PYTHONPATH"> +SCONSFLAGS"> + + + + + +allowed_values"> +build_dir"> +map"> +ignorecase"> +options"> +exports"> +source"> +target"> + + + + + +all"> +none"> + + + + + +BuildDir"> +CFile"> +CXXFile"> +DVI"> +Jar"> +Java"> +JavaH"> +Library"> +Object"> +PCH"> +PDF"> +PostScript"> +Program"> +RES"> +RMIC"> +SharedLibrary"> +SharedObject"> +StaticLibrary"> +StaticObject"> +Tar"> +Zip"> + + +Make"> + + + + + +builder function"> +builder method"> + +Configure Contexts"> +configure context"> + +Construction Environment"> +Construction Environments"> +Construction environment"> +Construction environments"> +construction environment"> +construction environments"> + +Construction Variable"> +Construction Variables"> +Construction variable"> +Construction variables"> +construction variable"> +construction variables"> + +CPPPATH"> + +Dictionary"> + +Emitter"> +emitter"> +Generator"> +generator"> + +Nodes"> + +signature"> +build signature"> + +true"> +false"> + +typedef"> + + + +bar"> +common1.c"> +common2.c"> +custom.py"> +goodbye"> +goodbye.o"> +goodbye.obj"> +file.dll"> +file.in"> +file.lib"> +file.o"> +file.obj"> +file.out"> +foo"> +foo.o"> +foo.obj"> +hello"> +hello.c"> +hello.exe"> +hello.h"> +hello.o"> +hello.obj"> +libfile_a"> +libfile_so"> +new_hello"> +new_hello.exe"> +prog"> +prog1"> +prog2"> +prog.c"> +prog.exe"> +stdio.h"> + + + ++"> +#"> + + + +announce@scons.tigris.org"> +dev@scons.tigris.org"> +users@scons.tigris.org"> diff --git a/doc/man/scons.1 b/doc/man/scons.1 index 690803f6..d26abdcb 100644 --- a/doc/man/scons.1 +++ b/doc/man/scons.1 @@ -31,7 +31,7 @@ .fi .RE .. -.TH SCONS 1 "October 2004" +.TH SCONS 1 "January 2005" .SH NAME scons \- a software construction tool .SH SYNOPSIS @@ -1010,7 +1010,7 @@ have two functions: generate(env, **kw) and exists(env). The .B generate() function -modifies the passed in environment +modifies the passed-in environment to set up variables so that the tool can be executed; it may use any keyword arguments @@ -1293,7 +1293,7 @@ to add a specific flag when compiling one specific object file: .ES -bar_obj_list = env.StaticObject('bar.c', CCFLAGS='-DBAR') +bar_obj_list = env.StaticObject('bar.c', CPPDEFINES='-DBAR') env.Program(source = ['foo.c', bar_obj_list, 'main.c']) .EE @@ -1340,7 +1340,7 @@ by passing the Node to the Python-builtin function: .ES -bar_obj_list = env.StaticObject('bar.c', CCFLAGS='-DBAR') +bar_obj_list = env.StaticObject('bar.c', CPPDEFINES='-DBAR') print "The path to bar_obj is:", str(bar_obj_list[0]) .EE @@ -4998,6 +4998,10 @@ env = Environment(CXXCOMSTR = "Compiling static object $TARGET") .IP CXXFLAGS General options that are passed to the C++ compiler. +By default, this includes the value of $CCFLAGS, +so that setting $CCFLAGS affects both C and C++ compilation. +If you want to add C++-specific flags, +you must set or override the value of $CXXFLAGS. .IP CXXVERSION The version number of the C++ compiler. @@ -5582,7 +5586,7 @@ target being built. .IP FRAMEWORKSFLAGS On Mac OS X, -frameworks options to be addad at +frameworks options to be added at the end of a command line building a loadable module. @@ -5789,13 +5793,13 @@ General user options passed to the linker for building loadable modules. The prefix used for loadable module file names. On Mac OS X, this is null; on other systems, this is -the same $SHLIBPREFIX. +the same as $SHLIBPREFIX. .IP LDMODULESUFFIX The suffix used for loadable module file names. On Mac OS X, this is null; on other systems, this is -the same $SHLIBSUFFIX. +the same as $SHLIBSUFFIX. .IP LEX The lexical analyzer generator. @@ -5844,7 +5848,7 @@ for specifying libraries to be linked with the resulting target. The value of $_LIBFLAGS is created by appending $LIBLINKPREFIX and $LIBLINKSUFFIX to the beginning and end -of each directory in $LIBS. +of each filename in $LIBS. .IP LIBLINKPREFIX The prefix used to specify a library to link on the linker command line. @@ -5930,7 +5934,7 @@ appending the values of the $LIBLINKPREFIX and $LIBLINKSUFFIX construction variables to the beginning and end -of each directory in $LIBS. +of each filename in $LIBS. Any command lines you define that need the LIBS library list should include $_LIBFLAGS: @@ -5939,6 +5943,26 @@ include $_LIBFLAGS: env = Environment(LINKCOM="my_linker $_LIBDIRFLAGS $_LIBFLAGS -o $TARGET $SOURCE") .EE +.IP +If you add a +File +object to the +LIBS +list, the name of that file will be added to +$_LIBFLAGS, +and thus the link line, as is, without +$LIBLINKPREFIX +or +$LIBLINKSUFFIX. +For example: +.ES +env.Append(LIBS=File('/tmp/mylib.so')) +.EE + +.IP +In all cases, scons will add dependencies from the executable program to +all the libraries in this list. + .IP LIBSUFFIX The suffix used for (static) library file names. A default value is set for each platform @@ -7933,7 +7957,7 @@ which verifies that the specified path is an existing directory; and .BR PathOption.PathIsDirCreate , which verifies that the specified path is a directory, -and will create the specified directory if the path exist. +and will create the specified directory if the path does not exist. You may supply your own .I validator function, @@ -8219,6 +8243,15 @@ env.Append(BUILDERS = {'MakeDirectory':MakeDirectoryBuilder}) env.MakeDirectory('new_directory', []) .EE +Note that the call to the MakeDirectory Builder +needs to specify an empty source list +to make the string represent the builder's target; +without that, it would assume the argument is the source, +and would try to deduce the target name from it, +which in the absence of an automatically-added prefix or suffix +would lead to a matching target and source name +and a circular dependency. + .IP source_factory A factory function that the Builder will use to turn any sources specified as strings into SCons Nodes. @@ -9006,7 +9039,7 @@ ${TARGET.filebase} => file ${TARGET.suffix} => .x ${TARGET.abspath} => /top/dir/sub/dir/file.x -BuildDir('sub/dir','src') +SConscript('src/SConscript', build_dir='sub/dir') $SOURCE => sub/dir/file.x ${SOURCE.srcpath} => src/file.x ${SOURCE.srcdir} => src @@ -9620,36 +9653,32 @@ subdirectory/SConscript: .SS Building Multiple Variants From the Same Source -Use the BuildDir() method to establish +Use the build_dir keyword argument to +the SConscript function to establish one or more separate build directories for -a given source directory, -then use the SConscript() method -to specify the SConscript files -in the build directories: +a given source directory: .ES SConstruct: - ccflags = '-DFOO' - Export("ccflags") - BuildDir('foo', 'src') - SConscript('foo/SConscript') + cppdefines = ['FOO'] + Export("cppdefines") + SConscript('src/SConscript', build_dir='foo') - ccflags = '-DBAR' - Export("ccflags") - BuildDir('bar', 'src') - SConscript('bar/SConscript') + cppdefines = ['BAR'] + Export("cppdefines") + SConscript('src/SConscript', build_dir='bar') src/SConscript: - Import("ccflags") - env = Environment(CCFLAGS = ccflags) + Import("cppdefines") + env = Environment(CPPDEFINES = cppdefines) env.Program(target = 'src', source = 'src.c') .EE Note the use of the Export() method -to set the "ccflags" variable to a different -value for each variant build. +to set the "cppdefines" variable to a different +value each time we call the SConscript function. .SS Hierarchical Build of Two Libraries Linked With a Program diff --git a/doc/python10/MANIFEST b/doc/python10/MANIFEST index 56a94d46..e962e6a7 100644 --- a/doc/python10/MANIFEST +++ b/doc/python10/MANIFEST @@ -12,4 +12,5 @@ main.sgml node.fig process.sgml scanner.fig +scons.mod sig.fig diff --git a/doc/python10/arch.eps b/doc/python10/arch.eps new file mode 100644 index 00000000..1fdd51f4 --- /dev/null +++ b/doc/python10/arch.eps @@ -0,0 +1,134 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/arch.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 218 182 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 182 moveto 0 0 lineto 218 0 lineto 218 182 lineto closepath clip newpath +-215.3 324.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +/Courier-Bold ff 300.00 scf sf +3825 2925 m +gs 1 -1 sc (scons) col0 sh gr +/Times-Roman ff 300.00 scf sf +3825 3225 m +gs 1 -1 sc (Script) col0 sh gr +/Times-Roman ff 300.00 scf sf +5100 4875 m +gs 1 -1 sc (Build Engine) col0 sh gr +/Courier-Bold ff 300.00 scf sf +4200 4875 m +gs 1 -1 sc (SCons) col0 sh gr +% Polyline +7.500 slw +n 3600 4200 m 7200 4200 l 7200 5400 l 3600 5400 l + cp gs col0 s gr +/Courier-Bold ff 300.00 scf sf +4725 4050 m +gs 1 -1 sc (SCons) col0 sh gr +/Times-Roman ff 300.00 scf sf +5625 4050 m +gs 1 -1 sc (API) col0 sh gr +% Polyline +n 3600 2400 m 3600 2400 l 3600 2400 l 3600 2400 l + cp gs col0 s gr +% Polyline +n 3600 2400 m 4800 2400 l 4800 3600 l 3600 3600 l + cp gs col0 s gr +% Polyline +n 3600 3600 m 7200 3600 l 7200 4200 l 3600 4200 l + cp gs col0 s gr +% Polyline + [60] 0 sd +n 6000 3600 m 7200 3600 l 7200 2400 l 6000 2400 l + cp gs col0 s gr [] 0 sd +/Times-Italic ff 300.00 scf sf +6300 2925 m +gs 1 -1 sc (other) col0 sh gr +/Times-Italic ff 300.00 scf sf +6150 3225 m +gs 1 -1 sc (interface) col0 sh gr +$F2psEnd +rs diff --git a/doc/python10/arch.jpg b/doc/python10/arch.jpg new file mode 100644 index 00000000..4e69437b Binary files /dev/null and b/doc/python10/arch.jpg differ diff --git a/doc/python10/builder.eps b/doc/python10/builder.eps new file mode 100644 index 00000000..db87afca --- /dev/null +++ b/doc/python10/builder.eps @@ -0,0 +1,325 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/builder.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 668 290 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 290 moveto 0 0 lineto 668 0 lineto 668 290 lineto closepath clip newpath +-53.3 342.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/reencdict 12 dict def /ReEncode { reencdict begin +/newcodesandnames exch def /newfontname exch def /basefontname exch def +/basefontdict basefontname findfont def /newfont basefontdict maxlength dict def +basefontdict { exch dup /FID ne { dup /Encoding eq +{ exch dup length array copy newfont 3 1 roll put } +{ exch newfont 3 1 roll put } ifelse } { pop pop } ifelse } forall +newfont /FontName newfontname put newcodesandnames aload pop +128 1 255 { newfont /Encoding get exch /.notdef put } for +newcodesandnames length 2 idiv { newfont /Encoding get 3 1 roll put } repeat +newfontname newfont definefont pop end } def +/isovec [ +8#055 /minus 8#200 /grave 8#201 /acute 8#202 /circumflex 8#203 /tilde +8#204 /macron 8#205 /breve 8#206 /dotaccent 8#207 /dieresis +8#210 /ring 8#211 /cedilla 8#212 /hungarumlaut 8#213 /ogonek 8#214 /caron +8#220 /dotlessi 8#230 /oe 8#231 /OE +8#240 /space 8#241 /exclamdown 8#242 /cent 8#243 /sterling +8#244 /currency 8#245 /yen 8#246 /brokenbar 8#247 /section 8#250 /dieresis +8#251 /copyright 8#252 /ordfeminine 8#253 /guillemotleft 8#254 /logicalnot +8#255 /hyphen 8#256 /registered 8#257 /macron 8#260 /degree 8#261 /plusminus +8#262 /twosuperior 8#263 /threesuperior 8#264 /acute 8#265 /mu 8#266 /paragraph +8#267 /periodcentered 8#270 /cedilla 8#271 /onesuperior 8#272 /ordmasculine +8#273 /guillemotright 8#274 /onequarter 8#275 /onehalf +8#276 /threequarters 8#277 /questiondown 8#300 /Agrave 8#301 /Aacute +8#302 /Acircumflex 8#303 /Atilde 8#304 /Adieresis 8#305 /Aring +8#306 /AE 8#307 /Ccedilla 8#310 /Egrave 8#311 /Eacute +8#312 /Ecircumflex 8#313 /Edieresis 8#314 /Igrave 8#315 /Iacute +8#316 /Icircumflex 8#317 /Idieresis 8#320 /Eth 8#321 /Ntilde 8#322 /Ograve +8#323 /Oacute 8#324 /Ocircumflex 8#325 /Otilde 8#326 /Odieresis 8#327 /multiply +8#330 /Oslash 8#331 /Ugrave 8#332 /Uacute 8#333 /Ucircumflex +8#334 /Udieresis 8#335 /Yacute 8#336 /Thorn 8#337 /germandbls 8#340 /agrave +8#341 /aacute 8#342 /acircumflex 8#343 /atilde 8#344 /adieresis 8#345 /aring +8#346 /ae 8#347 /ccedilla 8#350 /egrave 8#351 /eacute +8#352 /ecircumflex 8#353 /edieresis 8#354 /igrave 8#355 /iacute +8#356 /icircumflex 8#357 /idieresis 8#360 /eth 8#361 /ntilde 8#362 /ograve +8#363 /oacute 8#364 /ocircumflex 8#365 /otilde 8#366 /odieresis 8#367 /divide +8#370 /oslash 8#371 /ugrave 8#372 /uacute 8#373 /ucircumflex +8#374 /udieresis 8#375 /yacute 8#376 /thorn 8#377 /ydieresis] def +/Times-Roman /Times-Roman-iso isovec ReEncode +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +% Polyline +7.500 slw +n 2700 1200 m 4500 1200 l 4500 1800 l 2700 1800 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +2925 1575 m +gs 1 -1 sc (Environment) col0 sh gr +% Polyline +n 2700 2400 m 4500 2400 l 4500 3000 l 2700 3000 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +3600 2775 m +gs 1 -1 sc (BuilderWrapper) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 2700 3600 m 4500 3600 l 4500 4200 l 2700 4200 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +3600 3975 m +gs 1 -1 sc (BuilderBase) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 8400 3600 m 9900 3600 l 9900 4200 l 8400 4200 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +9150 3975 m +gs 1 -1 sc (ActionBase) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +4650 5175 m +gs 1 -1 sc (MultiStep-) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +4650 5460 m +gs 1 -1 sc (Builder) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 3900 4800 m 5400 4800 l 5400 5700 l 3900 5700 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +2550 5175 m +gs 1 -1 sc (Composite-) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +2550 5460 m +gs 1 -1 sc (Builder) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 1800 4800 m 3300 4800 l 3300 5700 l 1800 5700 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +7050 5175 m +gs 1 -1 sc (Command) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +7050 5460 m +gs 1 -1 sc (Action) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 6300 4800 m 7800 4800 l 7800 5700 l 6300 5700 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +9150 5460 m +gs 1 -1 sc (Action) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +9150 5175 m +gs 1 -1 sc (Function) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 8400 4800 m 9900 4800 l 9900 5700 l 8400 5700 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +11250 5175 m +gs 1 -1 sc (List) dup sw pop 2 div neg 0 rm col0 sh gr +/Times-Roman-iso ff 240.00 scf sf +11250 5460 m +gs 1 -1 sc (Action) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 10500 4800 m 12000 4800 l 12000 5700 l 10500 5700 l + cp gs col0 s gr +% Polyline +n 900 2400 m 2100 2400 l 2100 3000 l 900 3000 l + cp gs col0 s gr +/Times-Roman-iso ff 240.00 scf sf +1500 2775 m +gs 1 -1 sc (Node) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 3600 4200 m 3525 4350 l 3675 4350 l + cp gs col0 s gr +% Polyline +n 3150 4800 m 3150 4500 l 4050 4500 l + 4050 4800 l gs col0 s gr +% Polyline +n 3600 4350 m + 3600 4500 l gs col0 s gr +% Polyline +n 9150 4200 m 9075 4350 l 9225 4350 l + cp gs col0 s gr +% Polyline +n 7050 4800 m 7050 4500 l 10950 4500 l + 10950 4800 l gs col0 s gr +% Polyline +n 9150 4350 m + 9150 4800 l gs col0 s gr +% Polyline +gs clippath +9885 3870 m 9885 3930 l 10036 3930 l 9916 3900 l 10036 3870 l cp +eoclip +n 11550 4650 m 11550 3900 l + 9900 3900 l gs col0 s gr gr + +% arrowhead +n 10036 3870 m 9916 3900 l 10036 3930 l 10036 3870 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +8415 3930 m 8415 3870 l 8264 3870 l 8384 3900 l 8264 3930 l cp +eoclip +n 4650 3900 m + 8400 3900 l gs col0 s gr gr + +% arrowhead +n 8264 3930 m 8384 3900 l 8264 3870 l 8264 3930 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +3930 1785 m 3870 1785 l 3870 1936 l 3900 1816 l 3930 1936 l cp +eoclip +n 3900 2250 m + 3900 1800 l gs col0 s gr gr + +% arrowhead +n 3930 1936 m 3900 1816 l 3870 1936 l 3930 1936 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +3270 2415 m 3330 2415 l 3330 2264 l 3300 2384 l 3270 2264 l cp +eoclip +n 3300 1950 m + 3300 2400 l gs col0 s gr gr + +% arrowhead +n 3270 2264 m 3300 2384 l 3330 2264 l 3270 2264 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +3570 3615 m 3630 3615 l 3630 3464 l 3600 3584 l 3570 3464 l cp +eoclip +n 3600 3150 m + 3600 3600 l gs col0 s gr gr + +% arrowhead +n 3570 3464 m 3600 3584 l 3630 3464 l 3570 3464 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4380 4185 m 4320 4185 l 4320 4336 l 4350 4216 l 4380 4336 l cp +eoclip +n 4350 4650 m + 4350 4200 l gs col0 s gr gr + +% arrowhead +n 4380 4336 m 4350 4216 l 4320 4336 l 4380 4336 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +2880 4185 m 2820 4185 l 2820 4336 l 2850 4216 l 2880 4336 l cp +eoclip +n 2850 4650 m + 2850 4200 l gs col0 s gr gr + +% arrowhead +n 2880 4336 m 2850 4216 l 2820 4336 l 2880 4336 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +2715 3930 m 2715 3870 l 2564 3870 l 2684 3900 l 2564 3930 l cp +eoclip +n 1500 3150 m 1500 3900 l + 2700 3900 l gs col0 s gr gr + +% arrowhead +n 2564 3930 m 2684 3900 l 2564 3870 l 2564 3930 l cp gs 0.00 setgray ef gr col0 s +% Polyline +n 4650 3900 m 4575 3860 l 4500 3900 l 4575 3940 l + cp gs col0 s gr +% Polyline +n 1500 3000 m 1460 3075 l 1500 3150 l 1540 3075 l + cp gs col0 s gr +% Polyline +n 3600 3000 m 3560 3075 l 3600 3150 l 3640 3075 l + cp gs col0 s gr +% Polyline +n 3300 1800 m 3260 1875 l 3300 1950 l 3340 1875 l + cp gs col0 s gr +% Polyline +n 3900 2250 m 3860 2325 l 3900 2400 l 3940 2325 l + cp gs col0 s gr +% Polyline +n 4350 4650 m 4310 4725 l 4350 4800 l 4390 4725 l + cp gs col0 s gr +% Polyline +n 2850 4650 m 2810 4725 l 2850 4800 l 2890 4725 l + cp gs col0 s gr +% Polyline +n 11550 4650 m 11510 4725 l 11550 4800 l 11590 4725 l + cp gs col0 s gr +% Polyline + [60] 0 sd +n 3600 1200 m + 3600 900 l gs col0 s gr [] 0 sd +$F2psEnd +rs diff --git a/doc/python10/builder.jpg b/doc/python10/builder.jpg new file mode 100644 index 00000000..e9085e83 Binary files /dev/null and b/doc/python10/builder.jpg differ diff --git a/doc/python10/job-task.eps b/doc/python10/job-task.eps new file mode 100644 index 00000000..b3eeaff4 --- /dev/null +++ b/doc/python10/job-task.eps @@ -0,0 +1,238 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/job-task.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 416 236 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 236 moveto 0 0 lineto 416 0 lineto 416 236 lineto closepath clip newpath +-35.3 342.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +% Polyline +7.500 slw +n 4200 3900 m 5100 3900 l 5100 4500 l 4200 4500 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +4650 4275 m +gs 1 -1 sc (Task) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 4200 5100 m 5100 5100 l 5100 5700 l 4200 5700 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +4650 5475 m +gs 1 -1 sc (Node) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 6300 2100 m 7200 2100 l 7200 2700 l 6300 2700 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +6750 2475 m +gs 1 -1 sc (Sig) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 6300 3300 m 7500 3300 l 7500 3900 l 6300 3900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +6900 3675 m +gs 1 -1 sc (Walker) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 4200 2100 m 5700 2100 l 5700 2700 l 4200 2700 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +4950 2475 m +gs 1 -1 sc (TaskMaster) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 2400 3300 m 3600 3300 l 3600 3900 l 2400 3900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +3000 3675 m +gs 1 -1 sc (Parallel) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 600 3300 m 1800 3300 l 1800 3900 l 600 3900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +1200 3675 m +gs 1 -1 sc (Serial) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 1200 2100 m 3000 2100 l 3000 2700 l 1200 2700 l + cp gs col0 s gr +/Times-Roman ff 255.00 scf sf +2099 2475 m +gs 1 -1 sc (Jobs) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 2700 2700 m 2660 2775 l 2700 2850 l 2740 2775 l + cp gs col0 s gr +% Polyline +n 5700 2400 m 5775 2440 l 5850 2400 l 5775 2360 l + cp gs col0 s gr +% Polyline +n 5400 2700 m 5360 2775 l 5400 2850 l 5440 2775 l + cp gs col0 s gr +% Polyline +n 4650 2700 m 4610 2775 l 4650 2850 l 4690 2775 l + cp gs col0 s gr +% Polyline +n 1500 2700 m 1460 2775 l 1500 2850 l 1540 2775 l + cp gs col0 s gr +% Polyline +n 4650 4500 m 4610 4575 l 4650 4650 l 4690 4575 l + cp gs col0 s gr +% Polyline +gs clippath +1470 3315 m 1530 3315 l 1530 3164 l 1500 3284 l 1470 3164 l cp +eoclip +n 1500 2850 m + 1500 3300 l gs col0 s gr gr + +% arrowhead +n 1470 3164 m 1500 3284 l 1530 3164 l 1470 3164 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +2670 3315 m 2730 3315 l 2730 3164 l 2700 3284 l 2670 3164 l cp +eoclip +n 2700 2850 m + 2700 3300 l gs col0 s gr gr + +% arrowhead +n 2670 3164 m 2700 3284 l 2730 3164 l 2670 3164 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4620 3915 m 4680 3915 l 4680 3764 l 4650 3884 l 4620 3764 l cp +eoclip +n 4650 2850 m + 4650 3900 l gs col0 s gr gr + +% arrowhead +n 4620 3764 m 4650 3884 l 4680 3764 l 4620 3764 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4620 5115 m 4680 5115 l 4680 4964 l 4650 5084 l 4620 4964 l cp +eoclip +n 4650 4650 m + 4650 5100 l gs col0 s gr gr + +% arrowhead +n 4620 4964 m 4650 5084 l 4680 4964 l 4620 4964 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +6315 3630 m 6315 3570 l 6164 3570 l 6284 3600 l 6164 3630 l cp +eoclip +n 5400 2850 m 5400 3600 l + 6300 3600 l gs col0 s gr gr + +% arrowhead +n 6164 3630 m 6284 3600 l 6164 3570 l 6164 3630 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +6315 2430 m 6315 2370 l 6164 2370 l 6284 2400 l 6164 2430 l cp +eoclip +n 5850 2400 m + 6300 2400 l gs col0 s gr gr + +% arrowhead +n 6164 2430 m 6284 2400 l 6164 2370 l 6164 2430 l cp gs 0.00 setgray ef gr col0 s +% Polyline +n 3000 2400 m 3075 2440 l 3150 2400 l 3075 2360 l + cp gs col0 s gr +% Polyline +gs clippath +4215 2430 m 4215 2370 l 4064 2370 l 4184 2400 l 4064 2430 l cp +eoclip +n 3150 2400 m + 4200 2400 l gs col0 s gr gr + +% arrowhead +n 4064 2430 m 4184 2400 l 4064 2370 l 4064 2430 l cp gs 0.00 setgray ef gr col0 s +% Polyline + [60] 0 sd +n 2100 2100 m + 2100 1800 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 4950 2100 m + 4950 1800 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 6750 2100 m + 6750 1800 l gs col0 s gr [] 0 sd +$F2psEnd +rs diff --git a/doc/python10/job-task.jpg b/doc/python10/job-task.jpg new file mode 100644 index 00000000..ff3ded0d Binary files /dev/null and b/doc/python10/job-task.jpg differ diff --git a/doc/python10/main.sgml b/doc/python10/main.sgml index 0708f306..ff1e3178 100644 --- a/doc/python10/main.sgml +++ b/doc/python10/main.sgml @@ -26,7 +26,7 @@ + %scons; diff --git a/doc/python10/node.eps b/doc/python10/node.eps new file mode 100644 index 00000000..995235d2 --- /dev/null +++ b/doc/python10/node.eps @@ -0,0 +1,351 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/node.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 452 362 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 362 moveto 0 0 lineto 452 0 lineto 452 362 lineto closepath clip newpath +0.7 414.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +% Polyline +7.500 slw +n 2700 1200 m 4500 1200 l 4500 1800 l 2700 1800 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +2925 1575 m +gs 1 -1 sc (Environment) col0 sh gr +% Polyline +n 2700 3600 m 4500 3600 l 4500 4200 l 2700 4200 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +3375 3975 m +gs 1 -1 sc (Node) col0 sh gr +% Polyline +n 5700 1800 m 6900 1800 l 6900 2400 l 5700 2400 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +5925 2175 m +gs 1 -1 sc (Walker) col0 sh gr +% Polyline +n 2100 2400 m 3300 2400 l 3300 3000 l 2100 3000 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +2325 2775 m +gs 1 -1 sc (Builder) col0 sh gr +% Polyline +n 3900 2400 m 5100 2400 l 5100 3000 l 3900 3000 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +4125 2775 m +gs 1 -1 sc (Scanner) col0 sh gr +% Polyline +n 2400 6300 m 3300 6300 l 3300 6900 l 2400 6900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +2700 6675 m +gs 1 -1 sc (Dir) col0 sh gr +% Polyline +n 0 6300 m 900 6300 l 900 6900 l 0 6900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +150 6675 m +gs 1 -1 sc (Entry) col0 sh gr +% Polyline +n 1200 6300 m 2100 6300 l 2100 6900 l 1200 6900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +1425 6675 m +gs 1 -1 sc (File) col0 sh gr +% Polyline +n 1050 5100 m 2250 5100 l 2250 5700 l 1050 5700 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +1200 5475 m +gs 1 -1 sc (Node.FS) col0 sh gr +% Polyline +n 1650 5700 m 1575 5850 l 1725 5850 l + cp gs col0 s gr +% Polyline +n 450 6300 m 450 6000 l 2700 6000 l + 2700 6300 l gs col0 s gr +% Polyline +n 1650 6300 m + 1650 5850 l gs col0 s gr +% Polyline + [60] 0 sd +n 5100 6300 m 6300 6300 l 6300 6900 l 5100 6900 l + cp gs col0 s gr [] 0 sd +/Times-Roman ff 240.00 scf sf +5325 6675 m +gs 1 -1 sc (Record) col0 sh gr +% Polyline + [60] 0 sd +n 6600 6300 m 7500 6300 l 7500 6900 l 6600 6900 l + cp gs col0 s gr [] 0 sd +/Times-Roman ff 240.00 scf sf +6750 6675 m +gs 1 -1 sc (Field) col0 sh gr +% Polyline + [60] 0 sd +n 4950 5100 m 6150 5100 l 6150 5700 l 4950 5700 l + cp gs col0 s gr [] 0 sd +/Times-Roman ff 240.00 scf sf +5100 5475 m +gs 1 -1 sc (Node.DB) col0 sh gr +% Polyline +n 5550 5700 m 5475 5850 l 5625 5850 l + cp gs col0 s gr +% Polyline + [60] 0 sd +n 4350 6300 m 4350 6000 l 7050 6000 l + 7050 6300 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 5550 5850 m + 5550 6300 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 3900 6300 m 4800 6300 l 4800 6900 l 3900 6900 l + cp gs col0 s gr [] 0 sd +/Times-Roman ff 240.00 scf sf +4050 6675 m +gs 1 -1 sc (Table) col0 sh gr +% Polyline +n 5700 3000 m 6900 3000 l 6900 3600 l 5700 3600 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +5850 3375 m +gs 1 -1 sc (Wrapper) col0 sh gr +% Polyline +n 900 1200 m 1800 1200 l 1800 1800 l 900 1800 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +1200 1575 m +gs 1 -1 sc (FS) col0 sh gr +% Polyline +n 3600 4200 m 3525 4350 l 3675 4350 l + cp gs col0 s gr +% Polyline +n 1800 5100 m 1800 4800 l 5550 4800 l + 5550 5100 l gs col0 s gr +% Polyline +n 3600 4800 m + 3600 4350 l gs col0 s gr +% Polyline +n 4200 1800 m 4160 1875 l 4200 1950 l 4240 1875 l + cp gs col0 s gr +% Polyline +n 3000 6150 m 2960 6225 l 3000 6300 l 3040 6225 l + cp gs col0 s gr +% Polyline +n 6300 3600 m 6260 3675 l 6300 3750 l 6340 3675 l + cp gs col0 s gr +% Polyline +n 6300 2400 m 6260 2475 l 6300 2550 l 6340 2475 l + cp gs col0 s gr +% Polyline +n 3000 4200 m 2960 4275 l 3000 4350 l 3040 4275 l + cp gs col0 s gr +% Polyline +n 4200 3450 m 4160 3525 l 4200 3600 l 4240 3525 l + cp gs col0 s gr +% Polyline +n 3000 3450 m 2960 3525 l 3000 3600 l 3040 3525 l + cp gs col0 s gr +% Polyline +gs clippath +2235 5370 m 2235 5430 l 2386 5430 l 2266 5400 l 2386 5370 l cp +eoclip +n 3000 6150 m 3000 5400 l + 2250 5400 l gs col0 s gr gr + +% arrowhead +n 2386 5370 m 2266 5400 l 2386 5430 l 2386 5370 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +2715 3930 m 2715 3870 l 2564 3870 l 2684 3900 l 2564 3930 l cp +eoclip +n 3000 4350 m 3000 4500 l 1800 4500 l 1800 3900 l + 2700 3900 l gs col0 s gr gr + +% arrowhead +n 2564 3930 m 2684 3900 l 2564 3870 l 2564 3930 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4485 3870 m 4485 3930 l 4636 3930 l 4516 3900 l 4636 3870 l cp +eoclip +n 6300 3750 m 6300 3900 l + 4500 3900 l gs col0 s gr gr + +% arrowhead +n 4636 3870 m 4516 3900 l 4636 3930 l 4636 3870 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4230 2985 m 4170 2985 l 4170 3136 l 4200 3016 l 4230 3136 l cp +eoclip +n 4200 3450 m + 4200 3000 l gs col0 s gr gr + +% arrowhead +n 4230 3136 m 4200 3016 l 4170 3136 l 4230 3136 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +3030 2985 m 2970 2985 l 2970 3136 l 3000 3016 l 3030 3136 l cp +eoclip +n 3000 3450 m + 3000 3000 l gs col0 s gr gr + +% arrowhead +n 3030 3136 m 3000 3016 l 2970 3136 l 3030 3136 l cp gs 0.00 setgray ef gr col0 s +% Polyline +n 3000 1800 m 2960 1875 l 3000 1950 l 3040 1875 l + cp gs col0 s gr +% Polyline +gs clippath +2970 2415 m 3030 2415 l 3030 2264 l 3000 2384 l 2970 2264 l cp +eoclip +n 3000 1950 m + 3000 2400 l gs col0 s gr gr + +% arrowhead +n 2970 2264 m 3000 2384 l 3030 2264 l 2970 2264 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4170 2415 m 4230 2415 l 4230 2264 l 4200 2384 l 4170 2264 l cp +eoclip +n 4200 1950 m + 4200 2400 l gs col0 s gr gr + +% arrowhead +n 4170 2264 m 4200 2384 l 4230 2264 l 4170 2264 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +6270 3015 m 6330 3015 l 6330 2864 l 6300 2984 l 6270 2864 l cp +eoclip +n 6300 2550 m + 6300 3000 l gs col0 s gr gr + +% arrowhead +n 6270 2864 m 6300 2984 l 6330 2864 l 6270 2864 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +4785 6570 m 4785 6630 l 4936 6630 l 4816 6600 l 4936 6570 l cp +eoclip +n 5100 6600 m + 4800 6600 l gs col0 s gr gr + +% arrowhead +n 4936 6570 m 4816 6600 l 4936 6630 l 4936 6570 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +6285 6570 m 6285 6630 l 6436 6630 l 6316 6600 l 6436 6570 l cp +eoclip +n 6600 6600 m + 6300 6600 l gs col0 s gr gr + +% arrowhead +n 6436 6570 m 6316 6600 l 6436 6630 l 6436 6570 l cp gs 0.00 setgray ef gr col0 s +% Polyline +n 1350 1800 m 1310 1875 l 1350 1950 l 1390 1875 l + cp gs col0 s gr +% Polyline +gs clippath +1320 5115 m 1380 5115 l 1380 4964 l 1350 5084 l 1320 4964 l cp +eoclip +n 1350 1950 m + 1350 5100 l gs col0 s gr gr + +% arrowhead +n 1320 4964 m 1350 5084 l 1380 4964 l 1320 4964 l cp gs 0.00 setgray ef gr col0 s +% Polyline + [60] 0 sd +n 1350 1200 m + 1350 900 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 3600 1200 m + 3600 900 l gs col0 s gr [] 0 sd +$F2psEnd +rs diff --git a/doc/python10/node.jpg b/doc/python10/node.jpg new file mode 100644 index 00000000..98ceb5eb Binary files /dev/null and b/doc/python10/node.jpg differ diff --git a/doc/python10/scanner.eps b/doc/python10/scanner.eps new file mode 100644 index 00000000..35614f80 --- /dev/null +++ b/doc/python10/scanner.eps @@ -0,0 +1,168 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/scanner.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 398 200 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 200 moveto 0 0 lineto 398 0 lineto 398 200 lineto closepath clip newpath +-17.3 360.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +% Polyline +7.500 slw +n 2700 5400 m 4500 5400 l 4500 6000 l 2700 6000 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +3000 5775 m +gs 1 -1 sc (ProgScanner) col0 sh gr +% Polyline +n 2700 4200 m 4500 4200 l 4500 4800 l 2700 4800 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +3225 4575 m +gs 1 -1 sc (Scanner) col0 sh gr +% Polyline +n 2700 3000 m 4500 3000 l 4500 3600 l 2700 3600 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +2925 3375 m +gs 1 -1 sc (Environment) col0 sh gr +% Polyline + [60] 0 sd +n 5100 5400 m 6900 5400 l 6900 6000 l 5100 6000 l + cp gs col0 s gr [] 0 sd +/Times-Roman ff 240.00 scf sf +5400 5775 m +gs 1 -1 sc (JavaScanner) col0 sh gr +% Polyline +n 300 5400 m 2100 5400 l 2100 6000 l 300 6000 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +750 5775 m +gs 1 -1 sc (CScanner) col0 sh gr +% Polyline +n 600 3300 m 1500 3300 l 1500 3900 l 600 3900 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +825 3675 m +gs 1 -1 sc (Node) col0 sh gr +% Polyline +n 1200 5400 m 1200 5100 l 6000 5100 l + 6000 5400 l gs col0 s gr +% Polyline +n 3600 4950 m + 3600 5400 l gs col0 s gr +% Polyline +n 3600 4800 m 3525 4950 l 3675 4950 l + cp gs col0 s gr +% Polyline +n 3600 3600 m 3560 3675 l 3600 3750 l 3640 3675 l + cp gs col0 s gr +% Polyline +n 1050 3900 m 1010 3975 l 1050 4050 l 1090 3975 l + cp gs col0 s gr +% Polyline +gs clippath +2715 4530 m 2715 4470 l 2564 4470 l 2684 4500 l 2564 4530 l cp +eoclip +n 1050 4050 m 1050 4500 l + 2700 4500 l gs col0 s gr gr + +% arrowhead +n 2564 4530 m 2684 4500 l 2564 4470 l 2564 4530 l cp gs 0.00 setgray ef gr col0 s +% Polyline +gs clippath +3570 4215 m 3630 4215 l 3630 4064 l 3600 4184 l 3570 4064 l cp +eoclip +n 3600 3750 m + 3600 4200 l gs col0 s gr gr + +% arrowhead +n 3570 4064 m 3600 4184 l 3630 4064 l 3570 4064 l cp gs 0.00 setgray ef gr col0 s +% Polyline + [60] 0 sd +n 3600 3000 m + 3600 2700 l gs col0 s gr [] 0 sd +$F2psEnd +rs diff --git a/doc/python10/scanner.jpg b/doc/python10/scanner.jpg new file mode 100644 index 00000000..08e5dcb2 Binary files /dev/null and b/doc/python10/scanner.jpg differ diff --git a/doc/python10/scons.mod b/doc/python10/scons.mod new file mode 100644 index 00000000..58a6576a --- /dev/null +++ b/doc/python10/scons.mod @@ -0,0 +1,428 @@ + + + + + + +Aegis"> +Ant"> +Autoconf"> +Automake"> +cc"> +Cons"> +cp"> +csh"> +gcc"> +Jam"> +jar"> +javac"> +javah"> +Make"> +Make++"> +Python"> +ranlib"> +rmic"> +SCons"> +scons"> +ScCons"> +tar"> +touch"> +zip"> + + + + +Action"> +ActionBase"> +CommandAction"> +FunctionAction"> +ListAction"> +Builder"> +BuilderBase"> +CompositeBuilder"> +MultiStepBuilder"> +Job"> +Jobs"> +Serial"> +Parallel"> +Node"> +Node.FS"> +Scanner"> +Sig"> +Signature"> +Taskmaster"> +TimeStamp"> +Walker"> +Wrapper"> + + + + + +--debug=explain"> +--implicit-cache"> +--implicit-deps-changed"> +--implicit-deps-unchanged"> +-Q"> + + + +implicit_cache"> +implicit_deps_changed"> +implicit_deps_unchanged"> + + + + + +build"> +Makefile"> +Makefiles"> +SConscript"> +SConstruct"> +Sconstruct"> +sconstruct"> +.sconsign"> +src"> + + + + + +Add"> +AddOptions"> +Alias"> +Aliases"> +Append"> +BoolOption"> +Build"> +CacheDir"> +Clean"> +Clone"> +Command"> +Configure"> +Copy"> +Default"> +DefaultRules"> +Depends"> +Dir"> +Entry"> +EnumOption"> +Environment"> +Export"> +File"> +Finish"> +GenerateHelpText"> +Help"> +Ignore"> +Import"> +Install"> +InstallAs"> +Link"> +ListOption"> +Local"> +Module"> +Objects"> +Options"> +PackageOption"> +PathOption"> +Precious"> +Prepend"> +Replace"> +Repository"> +Return"> +RuleSet"> +Salt"> +SetBuildSignatureType"> +SetContentSignatureType"> +SourceSignature"> +SourceSignatures"> +Split"> +TargetSignatures"> +Task"> + + +subst"> + + +Message"> +Result"> +CheckCHeader"> +CheckCXXHeader"> +CheckFunc"> +CheckHeader"> +CheckLib"> +CheckLibWithHeader"> +CheckType"> +TryAction"> +TryBuild"> +TryCompile"> +TryLink"> +TryRun"> + + +str"> +zipfile"> + + +Cache"> + + + + + +ARGUMENTS"> +BUILD_TARGETS"> +COMMAND_LINE_TARGETS"> +DEFAULT_TARGETS"> + + + + + +BUILDERMAP"> +BUILDERS"> +CC"> +CCFLAGS"> +CCCOM"> +COLOR"> +COLORS"> +CONFIG"> +CPPDEFINES"> +ENV"> +JAVACLASSDIR"> +LIBDIRPREFIX"> +LIBDIRSUFFIX"> +LIBLINKPREFIX"> +LIBLINKSUFFIX"> +LIBPATH"> +LIBS"> +LINK"> +LINKCOM"> +LINKFLAGS"> +RELEASE"> +RELEASE_BUILD"> +SCANNERMAP"> +SCANNERS"> +TARFLAGS"> +TARSUFFIX"> + + + + + +PATH"> +PYTHONPATH"> +SCONSFLAGS"> + + + + + +allowed_values"> +build_dir"> +map"> +ignorecase"> +options"> +exports"> +source"> +target"> + + + + + +all"> +none"> + + + + + +BuildDir"> +CFile"> +CXXFile"> +DVI"> +Jar"> +Java"> +JavaH"> +Library"> +Object"> +PCH"> +PDF"> +PostScript"> +Program"> +RES"> +RMIC"> +SharedLibrary"> +SharedObject"> +StaticLibrary"> +StaticObject"> +Tar"> +Zip"> + + +Make"> + + + + + +builder function"> +builder method"> + +Configure Contexts"> +configure context"> + +Construction Environment"> +Construction Environments"> +Construction environment"> +Construction environments"> +construction environment"> +construction environments"> + +Construction Variable"> +Construction Variables"> +Construction variable"> +Construction variables"> +construction variable"> +construction variables"> + +CPPPATH"> + +Dictionary"> + +Emitter"> +emitter"> +Generator"> +generator"> + +Nodes"> + +signature"> +build signature"> + +true"> +false"> + +typedef"> + + + +bar"> +common1.c"> +common2.c"> +custom.py"> +goodbye"> +goodbye.o"> +goodbye.obj"> +file.dll"> +file.in"> +file.lib"> +file.o"> +file.obj"> +file.out"> +foo"> +foo.o"> +foo.obj"> +hello"> +hello.c"> +hello.exe"> +hello.h"> +hello.o"> +hello.obj"> +libfile_a"> +libfile_so"> +new_hello"> +new_hello.exe"> +prog"> +prog1"> +prog2"> +prog.c"> +prog.exe"> +stdio.h"> + + + ++"> +#"> + + + +announce@scons.tigris.org"> +dev@scons.tigris.org"> +users@scons.tigris.org"> diff --git a/doc/python10/sig.eps b/doc/python10/sig.eps new file mode 100644 index 00000000..26aabaaf --- /dev/null +++ b/doc/python10/sig.eps @@ -0,0 +1,147 @@ +%!PS-Adobe-2.0 EPSF-2.0 +%%Title: build/doc/python10/sig.fig +%%Creator: /usr/bin/fig2dev Version 3.2 Patchlevel 3d +%%CreationDate: Sun Jan 2 01:21:05 2005 +%%For: knight@casablanca.home.baldmt.com (Steven Knight) +%%BoundingBox: 0 0 308 128 +%%Magnification: 1.0000 +%%EndComments +/$F2psDict 200 dict def +$F2psDict begin +$F2psDict /mtrx matrix put +/col-1 {0 setgray} bind def +/col0 {0.000 0.000 0.000 srgb} bind def +/col1 {0.000 0.000 1.000 srgb} bind def +/col2 {0.000 1.000 0.000 srgb} bind def +/col3 {0.000 1.000 1.000 srgb} bind def +/col4 {1.000 0.000 0.000 srgb} bind def +/col5 {1.000 0.000 1.000 srgb} bind def +/col6 {1.000 1.000 0.000 srgb} bind def +/col7 {1.000 1.000 1.000 srgb} bind def +/col8 {0.000 0.000 0.560 srgb} bind def +/col9 {0.000 0.000 0.690 srgb} bind def +/col10 {0.000 0.000 0.820 srgb} bind def +/col11 {0.530 0.810 1.000 srgb} bind def +/col12 {0.000 0.560 0.000 srgb} bind def +/col13 {0.000 0.690 0.000 srgb} bind def +/col14 {0.000 0.820 0.000 srgb} bind def +/col15 {0.000 0.560 0.560 srgb} bind def +/col16 {0.000 0.690 0.690 srgb} bind def +/col17 {0.000 0.820 0.820 srgb} bind def +/col18 {0.560 0.000 0.000 srgb} bind def +/col19 {0.690 0.000 0.000 srgb} bind def +/col20 {0.820 0.000 0.000 srgb} bind def +/col21 {0.560 0.000 0.560 srgb} bind def +/col22 {0.690 0.000 0.690 srgb} bind def +/col23 {0.820 0.000 0.820 srgb} bind def +/col24 {0.500 0.190 0.000 srgb} bind def +/col25 {0.630 0.250 0.000 srgb} bind def +/col26 {0.750 0.380 0.000 srgb} bind def +/col27 {1.000 0.500 0.500 srgb} bind def +/col28 {1.000 0.630 0.630 srgb} bind def +/col29 {1.000 0.750 0.750 srgb} bind def +/col30 {1.000 0.880 0.880 srgb} bind def +/col31 {1.000 0.840 0.000 srgb} bind def + +end +save +newpath 0 128 moveto 0 0 lineto 308 0 lineto 308 128 lineto closepath clip newpath +-71.3 288.7 translate +1 -1 scale + +/cp {closepath} bind def +/ef {eofill} bind def +/gr {grestore} bind def +/gs {gsave} bind def +/sa {save} bind def +/rs {restore} bind def +/l {lineto} bind def +/m {moveto} bind def +/rm {rmoveto} bind def +/n {newpath} bind def +/s {stroke} bind def +/sh {show} bind def +/slc {setlinecap} bind def +/slj {setlinejoin} bind def +/slw {setlinewidth} bind def +/srgb {setrgbcolor} bind def +/rot {rotate} bind def +/sc {scale} bind def +/sd {setdash} bind def +/ff {findfont} bind def +/sf {setfont} bind def +/scf {scalefont} bind def +/sw {stringwidth} bind def +/tr {translate} bind def +/tnt {dup dup currentrgbcolor + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add + 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb} + bind def +/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul + 4 -2 roll mul srgb} bind def +/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def +/$F2psEnd {$F2psEnteredState restore end} def + +$F2psBegin +10 setmiterlimit + 0.06000 0.06000 sc +% +% Fig objects follow +% +% Polyline +7.500 slw +n 1200 3000 m 2700 3000 l 2700 3600 l 1200 3600 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +1950 3375 m +gs 1 -1 sc (Taskmaster) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 3300 4200 m 4500 4200 l 4500 4800 l 3300 4800 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +3900 4575 m +gs 1 -1 sc (MD5) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 5100 4200 m 6300 4200 l 6300 4800 l 5100 4800 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +5700 4575 m +gs 1 -1 sc (TStamp) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 4200 3000 m 5400 3000 l 5400 3600 l 4200 3600 l + cp gs col0 s gr +/Times-Roman ff 240.00 scf sf +4800 3375 m +gs 1 -1 sc (Sig) dup sw pop 2 div neg 0 rm col0 sh gr +% Polyline +n 2700 3300 m 2775 3340 l 2850 3300 l 2775 3260 l + cp gs col0 s gr +% Polyline +n 4800 3600 m 4725 3750 l 4875 3750 l + cp gs col0 s gr +% Polyline +n 3900 4200 m 3900 3900 l 5700 3900 l + 5700 4200 l gs col0 s gr +% Polyline +n 4800 3750 m + 4800 3900 l gs col0 s gr +% Polyline +gs clippath +4215 3330 m 4215 3270 l 4064 3270 l 4184 3300 l 4064 3330 l cp +eoclip +n 2850 3300 m + 4200 3300 l gs col0 s gr gr + +% arrowhead +n 4064 3330 m 4184 3300 l 4064 3270 l 4064 3330 l cp gs 0.00 setgray ef gr col0 s +% Polyline + [60] 0 sd +n 1950 3000 m + 1950 2700 l gs col0 s gr [] 0 sd +% Polyline + [60] 0 sd +n 4800 3000 m + 4800 2700 l gs col0 s gr [] 0 sd +$F2psEnd +rs diff --git a/doc/python10/sig.jpg b/doc/python10/sig.jpg new file mode 100644 index 00000000..0c7e0df3 Binary files /dev/null and b/doc/python10/sig.jpg differ diff --git a/doc/scons.mod b/doc/scons.mod index 897262dc..b8b64aa6 100644 --- a/doc/scons.mod +++ b/doc/scons.mod @@ -130,6 +130,7 @@ BoolOption"> Build"> CacheDir"> +Chmod"> Clean"> Clone"> Command"> @@ -137,15 +138,19 @@ Copy"> Default"> DefaultRules"> +Delete"> Depends"> Dir"> +Dump"> Entry"> EnumOption"> Environment"> +Execute"> Export"> File"> Finish"> GenerateHelpText"> +GetOption"> Help"> Ignore"> Import"> @@ -154,10 +159,13 @@ Link"> ListOption"> Local"> +Mkdir"> Module"> +Move"> Objects"> Options"> PackageOption"> +ParseConfig"> PathOption"> PathOption.PathAccept"> PathOption.PathExists"> @@ -178,6 +186,7 @@ Split"> TargetSignatures"> Task"> +Touch"> subst"> @@ -198,6 +207,7 @@ TryLink"> TryRun"> + str"> zipfile"> @@ -227,29 +237,12 @@ --> BUILDERMAP"> -BUILDERS"> -CC"> -CCFLAGS"> -CCCOM"> COLOR"> COLORS"> CONFIG"> -CPPDEFINES"> -ENV"> -JAVACLASSDIR"> -LIBDIRPREFIX"> -LIBDIRSUFFIX"> -LIBLINKPREFIX"> -LIBLINKSUFFIX"> -LIBPATH"> -LIBS"> -LINK"> -LINKCOM"> -LINKFLAGS"> RELEASE"> RELEASE_BUILD"> SCANNERMAP"> -SCANNERS"> TARFLAGS"> TARSUFFIX"> @@ -361,6 +354,9 @@ Emitter"> emitter"> + +factory"> + Generator"> generator"> diff --git a/doc/user/ENV.in b/doc/user/ENV.in index b1edd816..56d5901b 100644 --- a/doc/user/ENV.in +++ b/doc/user/ENV.in @@ -31,7 +31,7 @@ the same external environment that you used to execute &SCons;. Instead, it uses the dictionary - stored in the &ENV; construction variable + stored in the &cv-link-ENV; construction variable as the external environment for executing commands. @@ -62,7 +62,7 @@ If you want to execute any commands--compilers, linkers, etc.--that are not in these default locations, you need to set the &PATH; value - in the &ENV; dictionary + in the &cv-ENV; dictionary in your construction environment. @@ -82,14 +82,14 @@ - Assign a dictionary to the &ENV; + Assign a dictionary to the &cv-ENV; construction variable in this way completely resets the external environment so that the only variable that will be set when external commands are executed will be the &PATH; value. If you want to use the rest of - the values in &ENV; and only + the values in &cv-ENV; and only set the value of &PATH;, the most straightforward way is probably: @@ -146,7 +146,7 @@ - scons -Q + scons -Q --> diff --git a/doc/user/ENV.sgml b/doc/user/ENV.sgml index c2d72965..aa65ebd9 100644 --- a/doc/user/ENV.sgml +++ b/doc/user/ENV.sgml @@ -31,7 +31,7 @@ the same external environment that you used to execute &SCons;. Instead, it uses the dictionary - stored in the &ENV; construction variable + stored in the &cv-link-ENV; construction variable as the external environment for executing commands. @@ -62,7 +62,7 @@ If you want to execute any commands--compilers, linkers, etc.--that are not in these default locations, you need to set the &PATH; value - in the &ENV; dictionary + in the &cv-ENV; dictionary in your construction environment. @@ -82,14 +82,14 @@ - Assign a dictionary to the &ENV; + Assign a dictionary to the &cv-ENV; construction variable in this way completely resets the external environment so that the only variable that will be set when external commands are executed will be the &PATH; value. If you want to use the rest of - the values in &ENV; and only + the values in &cv-ENV; and only set the value of &PATH;, the most straightforward way is probably: @@ -146,7 +146,7 @@ - scons -Q + scons -Q --> diff --git a/doc/user/MANIFEST b/doc/user/MANIFEST index e2663931..3af2c9c2 100644 --- a/doc/user/MANIFEST +++ b/doc/user/MANIFEST @@ -1,6 +1,7 @@ actions.sgml alias.sgml ant.sgml +builders.sgml builders-built-in.sgml builders-commands.sgml builders-writing.sgml @@ -15,6 +16,7 @@ ENV.sgml environments.sgml errors.sgml example.sgml +factories.sgml help.sgml hierarchy.sgml install.sgml @@ -24,8 +26,10 @@ less-simple.sgml main.sgml make.sgml nodes.sgml +parseconfig.sgml precious.sgml preface.sgml +python.sgml repositories.sgml run.sgml scanners.sgml @@ -34,8 +38,10 @@ separate.sgml simple.sgml sourcecode.sgml tasks.sgml +tools.sgml troubleshoot.sgml variants.sgml +variables.sgml SCons-win32-install-1.jpg SCons-win32-install-2.jpg SCons-win32-install-3.jpg diff --git a/doc/user/alias.in b/doc/user/alias.in index d2344a2d..686c004f 100644 --- a/doc/user/alias.in +++ b/doc/user/alias.in @@ -50,7 +50,7 @@ - scons -Q install + scons -Q install @@ -95,8 +95,8 @@ - scons -Q install-bin - scons -Q install-lib - scons -Q -c __ROOT__/ - scons -Q install + scons -Q install-bin + scons -Q install-lib + scons -Q -c __ROOT__/ + scons -Q install diff --git a/doc/user/build-install.in b/doc/user/build-install.in index 0f63bd90..763c13e0 100644 --- a/doc/user/build-install.in +++ b/doc/user/build-install.in @@ -78,6 +78,12 @@ + + $ python Python 2.2.2 (#1, Feb 24 2003, 19:13:11) @@ -156,6 +162,7 @@ &SCons; comes in RPM (Red Hat Package Manager) format, pre-built and ready to install on Red Hat Linux, + Fedora Core, or any other Linux distribution that uses RPM. Your distribution may already have an &SCons; RPM built specifically for it; @@ -406,36 +413,6 @@ -
- Building and Installing &SCons; Without Administrative Privileges - - - - If you don't have the right privileges to install &SCons; - in a system location, - you can install it in a location of your choosing - by specifying the --prefix= option: - - - - - # python setup.py install --prefix=$HOME - - - - - This would install &SCons; in appropriate locations - relative to the user's $HOME directory, - the scons script in - $HOME/bin - and the build engine in - $HOME/lib/scons. - You may, of course, specify any other location you prefer. - - - -
- + $ python Python 2.2.2 (#1, Feb 24 2003, 19:13:11) @@ -156,6 +162,7 @@ &SCons; comes in RPM (Red Hat Package Manager) format, pre-built and ready to install on Red Hat Linux, + Fedora Core, or any other Linux distribution that uses RPM. Your distribution may already have an &SCons; RPM built specifically for it; @@ -406,36 +413,6 @@ -
- Building and Installing &SCons; Without Administrative Privileges - - - - If you don't have the right privileges to install &SCons; - in a system location, - you can install it in a location of your choosing - by specifying the --prefix= option: - - - - - # python setup.py install --prefix=$HOME - - - - - This would install &SCons; in appropriate locations - relative to the user's $HOME directory, - the scons script in - $HOME/bin - and the build engine in - $HOME/lib/scons. - You may, of course, specify any other location you prefer. - - - -
- + + + + + +This appendix contains descriptions of all of the +Builders that are potentially +available "out of the box" in this version of SCons. + + + + + +&builders-gen; + + diff --git a/doc/user/builders.sgml b/doc/user/builders.sgml new file mode 100644 index 00000000..2bc139d4 --- /dev/null +++ b/doc/user/builders.sgml @@ -0,0 +1,56 @@ + + + + + + +This appendix contains descriptions of all of the +Builders that are potentially +available "out of the box" in this version of SCons. + + + + + +&builders-gen; + + diff --git a/doc/user/caching.in b/doc/user/caching.in index 552f3c1b..0195c435 100644 --- a/doc/user/caching.in +++ b/doc/user/caching.in @@ -93,9 +93,9 @@ - scons -Q - scons -Q -c - scons -Q + scons -Q + scons -Q -c + scons -Q @@ -129,9 +129,9 @@ - scons -Q - scons -Q -c - scons -Q --cache-show + scons -Q + scons -Q -c + scons -Q --cache-show @@ -176,11 +176,11 @@ - scons -Q - scons -Q -c - scons -Q - scons -Q -c - scons -Q --cache-disable + scons -Q + scons -Q -c + scons -Q + scons -Q -c + scons -Q --cache-disable @@ -217,12 +217,12 @@ - scons -Q --cache-disable - scons -Q -c - scons -Q --cache-disable - scons -Q --cache-force - scons -Q -c - scons -Q + scons -Q --cache-disable + scons -Q -c + scons -Q --cache-disable + scons -Q --cache-force + scons -Q -c + scons -Q diff --git a/doc/user/command-line.in b/doc/user/command-line.in index f23755f3..b444d30f 100644 --- a/doc/user/command-line.in +++ b/doc/user/command-line.in @@ -78,9 +78,9 @@ - scons - export SCONSFLAGS="-Q" - scons + scons + export SCONSFLAGS="-Q" + scons @@ -147,8 +147,8 @@ - scons -Q - scons -Q bar + scons -Q + scons -Q bar @@ -209,9 +209,9 @@ - scons -Q - scons -Q - scons -Q goodbye + scons -Q + scons -Q + scons -Q goodbye @@ -226,7 +226,7 @@ - scons -Q . + scons -Q . @@ -285,8 +285,8 @@ - scons -Q - scons -Q . + scons -Q + scons -Q . @@ -327,9 +327,9 @@ - scons -Q - scons -Q - scons -Q . + scons -Q + scons -Q + scons -Q . @@ -363,8 +363,8 @@ - scons -Q - scons -Q . + scons -Q + scons -Q .
@@ -408,7 +408,7 @@ - scons + scons @@ -444,7 +444,7 @@ - scons + scons @@ -537,9 +537,9 @@ - scons -Q - scons -Q prog2 - scons -Q -c . + scons -Q + scons -Q prog2 + scons -Q -c .
@@ -587,7 +587,7 @@ - The following code sets the &CCFLAGS; construction + The following code sets the &cv-link-CCFLAGS; construction variable in response to the debug flag being set in the &ARGUMENTS; dictionary: @@ -616,10 +616,10 @@ - scons -Q debug=0 - scons -Q debug=0 - scons -Q debug=1 - scons -Q debug=1 + scons -Q debug=0 + scons -Q debug=0 + scons -Q debug=1 + scons -Q debug=1 @@ -668,7 +668,7 @@ to pass the value to the C compiler. Here's how you might do that by setting the appropriate value in a dictionary for the - &CPPDEFINES; construction variable: + &cv-link-CPPDEFINES; construction variable: @@ -718,7 +718,7 @@
- scons -Q RELEASE=1 + scons -Q RELEASE=1 @@ -763,7 +763,7 @@ - scons -Q -h + scons -Q -h @@ -835,7 +835,7 @@ - scons -Q + scons -Q @@ -872,7 +872,7 @@ - scons -Q + scons -Q @@ -940,11 +940,11 @@ - scons -Q RELEASE=yes foo.o + scons -Q RELEASE=yes foo.o - scons -Q RELEASE=t foo.o + scons -Q RELEASE=t foo.o @@ -969,11 +969,11 @@ - scons -Q RELEASE=no foo.o + scons -Q RELEASE=no foo.o - scons -Q RELEASE=f foo.o + scons -Q RELEASE=f foo.o @@ -996,7 +996,7 @@ - scons -Q RELEASE=bad_value foo.o + scons -Q RELEASE=bad_value foo.o @@ -1043,9 +1043,9 @@ - scons -Q COLOR=red foo.o - scons -Q COLOR=blue foo.o - scons -Q COLOR=green foo.o + scons -Q COLOR=red foo.o + scons -Q COLOR=blue foo.o + scons -Q COLOR=green foo.o @@ -1058,7 +1058,7 @@ - scons -Q COLOR=magenta foo.o + scons -Q COLOR=magenta foo.o @@ -1101,7 +1101,7 @@ - scons -Q COLOR=navy foo.o + scons -Q COLOR=navy foo.o @@ -1115,9 +1115,9 @@ - scons -Q COLOR=Red foo.o - scons -Q COLOR=BLUE foo.o - scons -Q COLOR=nAvY foo.o + scons -Q COLOR=Red foo.o + scons -Q COLOR=BLUE foo.o + scons -Q COLOR=nAvY foo.o @@ -1153,10 +1153,10 @@ - scons -Q COLOR=Red foo.o - scons -Q COLOR=BLUE foo.o - scons -Q COLOR=nAvY foo.o - scons -Q COLOR=green foo.o + scons -Q COLOR=Red foo.o + scons -Q COLOR=BLUE foo.o + scons -Q COLOR=nAvY foo.o + scons -Q COLOR=green foo.o @@ -1198,9 +1198,9 @@ - scons -Q COLOR=Red foo.o - scons -Q COLOR=nAvY foo.o - scons -Q COLOR=GREEN foo.o + scons -Q COLOR=Red foo.o + scons -Q COLOR=nAvY foo.o + scons -Q COLOR=GREEN foo.o @@ -1243,8 +1243,8 @@ - scons -Q COLORS=red,blue foo.o - scons -Q COLORS=blue,green,red foo.o + scons -Q COLORS=red,blue foo.o + scons -Q COLORS=blue,green,red foo.o @@ -1258,8 +1258,8 @@ - scons -Q COLORS=all foo.o - scons -Q COLORS=none foo.o + scons -Q COLORS=all foo.o + scons -Q COLORS=none foo.o @@ -1270,7 +1270,7 @@ - scons -Q COLORS=magenta foo.o + scons -Q COLORS=magenta foo.o @@ -1320,8 +1320,8 @@ - scons -Q foo.o - scons -Q CONFIG=__ROOT__/usr/local/etc/other_config foo.o + scons -Q foo.o + scons -Q CONFIG=__ROOT__/usr/local/etc/other_config foo.o @@ -1333,7 +1333,7 @@ - scons -Q CONFIG=__ROOT__/does/not/exist foo.o + scons -Q CONFIG=__ROOT__/does/not/exist foo.o @@ -1500,10 +1500,10 @@ - scons -Q foo.o - scons -Q PACKAGE=__ROOT__/usr/local/location foo.o - scons -Q PACKAGE=yes foo.o - scons -Q PACKAGE=no foo.o + scons -Q foo.o + scons -Q PACKAGE=__ROOT__/usr/local/location foo.o + scons -Q PACKAGE=yes foo.o + scons -Q PACKAGE=no foo.o diff --git a/doc/user/command-line.sgml b/doc/user/command-line.sgml index 70658e00..565d9f89 100644 --- a/doc/user/command-line.sgml +++ b/doc/user/command-line.sgml @@ -568,7 +568,7 @@ - The following code sets the &CCFLAGS; construction + The following code sets the &cv-link-CCFLAGS; construction variable in response to the debug flag being set in the &ARGUMENTS; dictionary: @@ -650,7 +650,7 @@ to pass the value to the C compiler. Here's how you might do that by setting the appropriate value in a dictionary for the - &CPPDEFINES; construction variable: + &cv-link-CPPDEFINES; construction variable: diff --git a/doc/user/depends.in b/doc/user/depends.in index ab422b69..02629245 100644 --- a/doc/user/depends.in +++ b/doc/user/depends.in @@ -67,8 +67,8 @@ operating system on which the build is performed (as reported by C - scons -Q - scons -Q + scons -Q + scons -Q @@ -83,8 +83,8 @@ operating system on which the build is performed (as reported by C - scons -Q hello - scons -Q hello + scons -Q hello + scons -Q hello @@ -132,9 +132,9 @@ operating system on which the build is performed (as reported by C - scons -Q hello - touch hello.c - scons -Q hello + scons -Q hello + touch hello.c + scons -Q hello @@ -154,9 +154,9 @@ operating system on which the build is performed (as reported by C - scons -Q hello - edit hello.c - scons -Q hello + scons -Q hello + edit hello.c + scons -Q hello @@ -209,9 +209,9 @@ operating system on which the build is performed (as reported by C - scons -Q hello - touch hello.c - scons -Q hello + scons -Q hello + touch hello.c + scons -Q hello @@ -252,9 +252,9 @@ operating system on which the build is performed (as reported by C - scons -Q hello - edit hello.c - scons -Q hello + scons -Q hello + edit hello.c + scons -Q hello @@ -339,9 +339,9 @@ operating system on which the build is performed (as reported by C - scons -Q hello - edit hello.c - scons -Q hello + scons -Q hello + edit hello.c + scons -Q hello @@ -364,7 +364,7 @@ operating system on which the build is performed (as reported by C
- Implicit Dependencies: The &CPPPATH; Construction Variable + Implicit Dependencies: The &cv-CPPPATH; Construction Variable @@ -415,7 +415,7 @@ operating system on which the build is performed (as reported by C - The &CPPPATH; value + The &cv-CPPPATH; value tells &SCons; to look in the current directory ('.') for any files included by C source files @@ -425,17 +425,17 @@ operating system on which the build is performed (as reported by C - scons -Q hello - scons -Q hello - edit hello.h - scons -Q hello + scons -Q hello + scons -Q hello + edit hello.h + scons -Q hello First, notice that &SCons; added the -I. argument - from the &CPPPATH; variable + from the &cv-CPPPATH; variable so that the compilation would find the &hello_h; file in the local directory. @@ -462,8 +462,8 @@ operating system on which the build is performed (as reported by C - Like the &LIBPATH; variable, - the &CPPPATH; variable + Like the &cv-LIBPATH; variable, + the &cv-CPPPATH; variable may be a list of directories, or a string separated by the system-specific path separate character @@ -490,7 +490,7 @@ operating system on which the build is performed (as reported by C - scons -Q hello + scons -Q hello @@ -500,7 +500,7 @@ operating system on which the build is performed (as reported by C - scons -Q hello.exe + scons -Q hello.exe
@@ -554,8 +554,8 @@ operating system on which the build is performed (as reported by C - scons -Q --implicit-cache hello - scons -Q hello + scons -Q --implicit-cache hello + scons -Q hello @@ -610,8 +610,8 @@ operating system on which the build is performed (as reported by C - scons -Q --implicit-deps-changed hello - scons -Q hello + scons -Q --implicit-deps-changed hello + scons -Q hello @@ -645,8 +645,8 @@ operating system on which the build is performed (as reported by C - scons -Q --implicit-deps-unchanged hello - scons -Q hello + scons -Q --implicit-deps-unchanged hello + scons -Q hello @@ -699,10 +699,10 @@ operating system on which the build is performed (as reported by C - scons -Q hello - scons -Q hello - edit hello.h - scons -Q hello + scons -Q hello + scons -Q hello + edit hello.h + scons -Q hello XXX THIS EXAMPLE SHOULD BE UP-TO-DATE! XXX --> diff --git a/doc/user/depends.sgml b/doc/user/depends.sgml index b3728852..3d740251 100644 --- a/doc/user/depends.sgml +++ b/doc/user/depends.sgml @@ -375,7 +375,7 @@ operating system on which the build is performed (as reported by C
- Implicit Dependencies: The &CPPPATH; Construction Variable + Implicit Dependencies: The &cv-CPPPATH; Construction Variable @@ -422,7 +422,7 @@ operating system on which the build is performed (as reported by C - The &CPPPATH; value + The &cv-CPPPATH; value tells &SCons; to look in the current directory ('.') for any files included by C source files @@ -448,7 +448,7 @@ operating system on which the build is performed (as reported by C-I. argument - from the &CPPPATH; variable + from the &cv-CPPPATH; variable so that the compilation would find the &hello_h; file in the local directory. @@ -475,8 +475,8 @@ operating system on which the build is performed (as reported by C - Like the &LIBPATH; variable, - the &CPPPATH; variable + Like the &cv-LIBPATH; variable, + the &cv-CPPPATH; variable may be a list of directories, or a string separated by the system-specific path separate character @@ -711,10 +711,10 @@ operating system on which the build is performed (as reported by C - scons -Q hello - scons -Q hello - edit hello.h - scons -Q hello + scons -Q hello + scons -Q hello + edit hello.h + scons -Q hello XXX THIS EXAMPLE SHOULD BE UP-TO-DATE! XXX --> diff --git a/doc/user/environments.in b/doc/user/environments.in index 47a3c444..586242c2 100644 --- a/doc/user/environments.in +++ b/doc/user/environments.in @@ -468,7 +468,8 @@ environment undisturbed. and further specifies that the -O2 (optimization level two) flag should be used when compiling the object file. - In other words, the explicit initializations of &CC; and &CCFLAGS; + In other words, the explicit initializations of + &cv-link-CC; and &cv-link-CCFLAGS; override the default values in the newly-created construction environment. So a run from this example would look like: @@ -476,7 +477,7 @@ environment undisturbed. - scons -Q + scons -Q
@@ -514,7 +515,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -522,7 +523,7 @@ environment undisturbed. We can even use multiple construction environments to build multiple versions of a single program. If you do this by simply trying to use the - &Program; builder with both environments, though, + &b-link-Program; builder with both environments, though, like this: @@ -548,17 +549,17 @@ environment undisturbed. - scons -Q + scons -Q - This is because the two &Program; calls have + This is because the two &b-Program; calls have each implicitly told &SCons; to generate an object file named foo.o, - one with a &CCFLAGS; value of + one with a &cv-link-CCFLAGS; value of -O2 - and one with a &CCFLAGS; value of + and one with a &cv-link-CCFLAGS; value of -g. &SCons; can't just decide that one of them should take precedence over the other, @@ -568,7 +569,7 @@ environment undisturbed. that each environment compile foo.c to a separately-named object file - using the &Object; call, like so: + using the &b-link-Object; builder, like so: @@ -590,12 +591,12 @@ environment undisturbed. - Notice that each call to the &Object; builder + Notice that each call to the &b-Object; builder returns a value, an internal &SCons; object that represents the object file that will be built. We then use that object - as input to the &Program; builder. + as input to the &b-Program; builder. This avoids having to specify explicitly the object file name in multiple places, and makes for a compact, readable @@ -605,7 +606,7 @@ environment undisturbed. - scons -Q + scons -Q
@@ -633,10 +634,10 @@ environment undisturbed. to create three versions of a program, one optimized, one debug, and one with neither. We could do this by creating a "base" construction environment - that sets &CC; to &gcc;, + that sets &cv-link-CC; to &gcc;, and then creating two copies, - one which sets &CCFLAGS; for optimization - and the other which sets &CCFLAGS; for debugging: + one which sets &cv-link-CCFLAGS; for optimization + and the other which sets &cv-CCFLAGS; for debugging: @@ -666,7 +667,7 @@ environment undisturbed. - scons -Q + scons -Q
@@ -693,12 +694,12 @@ environment undisturbed. This example &SConstruct; file doesn't build anything, but because it's actually a Python script, - it will print the value of &CC; for us: + it will print the value of &cv-link-CC; for us:
- scons -Q + scons -Q @@ -729,7 +730,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -739,7 +740,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -775,7 +776,7 @@ environment undisturbed. the example from the previous section that used env['CC'] - to fetch the value of &CC; + to fetch the value of &cv-link-CC; could also be written as: @@ -794,7 +795,7 @@ environment undisturbed. re-expanded until there are no expansions left in the string. So a simple fetch of a value like - $CCCOM: + &cv-link-CCCOM;:
@@ -805,7 +806,7 @@ environment undisturbed. - Will print the unexpanded value of &CCCOM;, + Will print the unexpanded value of &cv-CCCOM;, showing us the construction variables that still need to be expanded: @@ -848,7 +849,7 @@ environment undisturbed. (Note that because we're not expanding this in the context of building something there are no target or source files - for $TARGET and $SOURCES to expand. + for &cv-link-TARGET; and &cv-link-SOURCES; to expand. @@ -895,7 +896,7 @@ environment undisturbed.
- scons -Q + scons -Q @@ -923,7 +924,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -972,14 +973,14 @@ environment undisturbed. - scons + scons Because the replacement occurs while the &SConscript; files are being read, - the $CCFLAGS + the &cv-link-CCFLAGS; variable has already been set to -DDEFINE2 by the time the &foo_o; target is built, @@ -1021,7 +1022,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -1046,7 +1047,7 @@ environment undisturbed. - scons -Q + scons -Q @@ -1081,7 +1082,7 @@ environment undisturbed.
- scons -Q + scons -Q @@ -1106,7 +1107,7 @@ environment undisturbed. - scons -Q + scons -Q diff --git a/doc/user/environments.sgml b/doc/user/environments.sgml index 1ff2fb35..14be5afd 100644 --- a/doc/user/environments.sgml +++ b/doc/user/environments.sgml @@ -463,7 +463,8 @@ environment undisturbed. and further specifies that the -O2 (optimization level two) flag should be used when compiling the object file. - In other words, the explicit initializations of &CC; and &CCFLAGS; + In other words, the explicit initializations of + &cv-link-CC; and &cv-link-CCFLAGS; override the default values in the newly-created construction environment. So a run from this example would look like: @@ -515,7 +516,7 @@ environment undisturbed. We can even use multiple construction environments to build multiple versions of a single program. If you do this by simply trying to use the - &Program; builder with both environments, though, + &b-link-Program; builder with both environments, though, like this:
@@ -544,12 +545,12 @@ environment undisturbed. - This is because the two &Program; calls have + This is because the two &b-Program; calls have each implicitly told &SCons; to generate an object file named foo.o, - one with a &CCFLAGS; value of + one with a &cv-link-CCFLAGS; value of -O2 - and one with a &CCFLAGS; value of + and one with a &cv-link-CCFLAGS; value of -g. &SCons; can't just decide that one of them should take precedence over the other, @@ -559,7 +560,7 @@ environment undisturbed. that each environment compile foo.c to a separately-named object file - using the &Object; call, like so: + using the &b-link-Object; builder, like so: @@ -576,12 +577,12 @@ environment undisturbed. - Notice that each call to the &Object; builder + Notice that each call to the &b-Object; builder returns a value, an internal &SCons; object that represents the object file that will be built. We then use that object - as input to the &Program; builder. + as input to the &b-Program; builder. This avoids having to specify explicitly the object file name in multiple places, and makes for a compact, readable @@ -623,10 +624,10 @@ environment undisturbed. to create three versions of a program, one optimized, one debug, and one with neither. We could do this by creating a "base" construction environment - that sets &CC; to &gcc;, + that sets &cv-link-CC; to &gcc;, and then creating two copies, - one which sets &CCFLAGS; for optimization - and the other which sets &CCFLAGS; for debugging: + one which sets &cv-link-CCFLAGS; for optimization + and the other which sets &cv-CCFLAGS; for debugging: @@ -682,7 +683,7 @@ environment undisturbed. This example &SConstruct; file doesn't build anything, but because it's actually a Python script, - it will print the value of &CC; for us: + it will print the value of &cv-link-CC; for us:
@@ -772,7 +773,7 @@ environment undisturbed. the example from the previous section that used env['CC'] - to fetch the value of &CC; + to fetch the value of &cv-link-CC; could also be written as:
@@ -791,7 +792,7 @@ environment undisturbed. re-expanded until there are no expansions left in the string. So a simple fetch of a value like - $CCCOM: + &cv-link-CCCOM;:
@@ -802,7 +803,7 @@ environment undisturbed. - Will print the unexpanded value of &CCCOM;, + Will print the unexpanded value of &cv-CCCOM;, showing us the construction variables that still need to be expanded: @@ -845,7 +846,7 @@ environment undisturbed. (Note that because we're not expanding this in the context of building something there are no target or source files - for $TARGET and $SOURCES to expand. + for &cv-link-TARGET; and &cv-link-SOURCES; to expand. @@ -975,7 +976,7 @@ environment undisturbed. Because the replacement occurs while the &SConscript; files are being read, - the $CCFLAGS + the &cv-link-CCFLAGS; variable has already been set to -DDEFINE2 by the time the &foo_o; target is built, diff --git a/doc/user/factories.in b/doc/user/factories.in new file mode 100644 index 00000000..95145d89 --- /dev/null +++ b/doc/user/factories.in @@ -0,0 +1,470 @@ + + + + + &SCons; provides a number of platform-independent functions, + called factories, + that perform common file system manipulations + like copying, moving or deleting files and directories, + or making directories. + These functions are factories + because they don't perform the action + at the time they're called, + they each return an &Action; object + that can be executed at the appropriate time. + + + +
+ Copying Files or Directories: The &Copy; Factory + + + + Suppose you want to arrange to make a copy of a file, + and the &Install; builder isn't appropriate + because it may make a hard link on POSIX systems. + One way would be to use the &Copy; action factory + in conjunction with the &Command; builder: + + + + + + Command("file.out", "file.in", Copy("$TARGET", "$SOURCE")) + + file.in + + + + + Notice that the action returned by the &Copy; factory + will expand the &cv-TARGET; and &cv-SOURCE; strings + at the time &file_out; is built, + and that the order of the arguments + is the same as that of a builder itself--that is, + target first, followed by source: + + + + + scons -Q + + + + + You can, of course, name a file explicitly + instead of using &cv-TARGET; or &cv-SOURCE;: + + + + + + Command("file.out", [], Copy("$TARGET", "file.in")) + + file.in + + + + + Which executes as: + + + + + scons -Q + + + + + The usefulness of the &Copy; factory + becomes more apparent when + you use it in a list of actions + passed to the &Command; builder. + For example, suppose you needed to run a + file through a utility that only modifies files in-place, + and can't "pipe" input to output. + One solution is to copy the source file + to a temporary file name, + run the utility, + and then copy the modified temporary file to the target, + which the &Copy; factory makes extremely easy: + + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Copy("$TARGET", "tempfile"), + ]) + + + env = DefaultEnvironment() + import os + env['ENV']['PATH'] = env['ENV']['PATH'] + os.pathsep + os.getcwd() + SConscript('S') + + file.in + + touch $* + + + + + + The output then looks like: + + + + + scons -Q + + +
+ +
+ Deleting Files or Directories: The &Delete; Factory + + + + If you need to delete a file, + then the &Delete; factory + can be used in much the same way as + the &Copy; factory. + For example, if we want to make sure that + the temporary file + in our last example doesn't exist before + we copy to it, + we could add &Delete; to the beginning + of the command list: + + + + + + Command("file.out", "file.in", + [ + Delete("tempfile"), + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Copy("$TARGET", "tempfile"), + ]) + + + env = DefaultEnvironment() + import os + env['ENV']['PATH'] = env['ENV']['PATH'] + os.pathsep + os.getcwd() + SConscript('S') + + file.in + + touch $* + + + + + + When then executes as follows: + + + + + scons -Q + + + + + Of course, like all of these &Action; factories, + the &Delete factory also expands + &cv-TARGET; and &cv-SOURCE; variables appropriately. + For example: + + + + + + Command("file.out", "file.in", + [ + Delete("$TARGET"), + Copy("$TARGET", "$SOURCE") + ]) + + file.in + + + + + Executes as: + + + + + scons -Q + + + + + (Note, however, that you typically don't need to + call the &Delete; factory explicitly in this way; + by default, &SCons; deletes its target(s) + for you before executing any action. + + + +
+ +
+ Moving (Renaming) Files or Directories: The &Move; Factory + + + + The &Move; factory + allows you to rename a file or directory. + For example, if we don't want to copy the temporary file, + we could: + + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Move("$TARGET", "tempfile"), + ]) + + + env = DefaultEnvironment() + import os + env['ENV']['PATH'] = env['ENV']['PATH'] + os.pathsep + os.getcwd() + SConscript('S') + + file.in + + touch $* + + + + + + Which would execute as: + + + + + scons -Q + + +
+ +
+ Updating the Modification Time of a File: The &Touch; Factory + + + + If you just need to update the + recorded modification time for a file, + use the &Touch; factory: + + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Move("$TARGET", "tempfile"), + ]) + + + env = DefaultEnvironment() + import os + env['ENV']['PATH'] = env['ENV']['PATH'] + os.pathsep + os.getcwd() + SConscript('S') + + file.in + + touch $* + + + + + + Which executes as: + + + + + scons -Q + + +
+ +
+ Creating a Directory: The &Mkdir; Factory + + + + If you need to create a directory, + use the &Mkdir; factory. + For example, if we need to process + a file in a temporary directory + in which the processing tool + will create other files that we don't care about, + you could: + + + + + + Command("file.out", "file.in", + [ + Delete("tempdir"), + Mkdir("tempdir"), + Copy("tempdir/${SOURCE.file}", "$SOURCE"), + "process tempdir", + Move("$TARGET", "tempdir/output_file"), + Delete("tempdir"), + ]) + + + env = DefaultEnvironment() + import os + env['ENV']['PATH'] = env['ENV']['PATH'] + os.pathsep + os.getcwd() + SConscript('S') + + file.in + + touch $* + + + + + + Which executes as: + + + + + scons -Q + + +
+ +
+ Changing File or Directory Permissions: The &Chmod; Factory + + + + To change permissions on a file or directory, + use the &Chmod; factory. + The permission argument uses POSIX-style + permission bits and should typically + be expressed as an octal, + not decimal, number: + + + + + + Command("file.out", "file.in", + [ + Copy("$TARGET", "$SOURCE"), + Chmod("$TARGET", 0755), + ]) + + file.in + + + + + Which executes: + + + + + scons -Q + + +
+ +
+ Executing an action immediately: the &Execute; Function + + + + We've been showing you how to use &Action; factories + in the &Command; function. + You can also execute an &Action; returned by a factory + (or actually, any &Action;) + at the time the &SConscript; file is read + by wrapping it up in the &Execute; function. + For example, if we need to make sure that + a directory exists before we build any targets, + + + + + + + Execute(Mkdir('__ROOT__/tmp/my_temp_directory')) + + + + + + Notice that this will + create the directory while + the &SConscript; file is being read: + + + + + scons + + + + + If you're familiar with Python, + you may wonder why you would want to use this + instead of just calling the native Python + os.mkdir() function. + The advantage here is that the &Mkdir; + action will behave appropriately if the user + specifies the &SCons; or + options--that is, + it will print the action but not actually + make the directory when is specified, + or make the directory but not print the action + when is specified. + + + +
diff --git a/doc/user/factories.sgml b/doc/user/factories.sgml new file mode 100644 index 00000000..b145ff2b --- /dev/null +++ b/doc/user/factories.sgml @@ -0,0 +1,427 @@ + + + + + &SCons; provides a number of platform-independent functions, + called factories, + that perform common file system manipulations + like copying, moving or deleting files and directories, + or making directories. + These functions are factories + because they don't perform the action + at the time they're called, + they each return an &Action; object + that can be executed at the appropriate time. + + + +
+ Copying Files or Directories: The &Copy; Factory + + + + Suppose you want to arrange to make a copy of a file, + and the &Install; builder isn't appropriate + because it may make a hard link on POSIX systems. + One way would be to use the &Copy; action factory + in conjunction with the &Command; builder: + + + + + Command("file.out", "file.in", Copy("$TARGET", "$SOURCE")) + + + + + Notice that the action returned by the &Copy; factory + will expand the &cv-TARGET; and &cv-SOURCE; strings + at the time &file_out; is built, + and that the order of the arguments + is the same as that of a builder itself--that is, + target first, followed by source: + + + + + % scons -Q + Copy("file.out", "file.in") + + + + + You can, of course, name a file explicitly + instead of using &cv-TARGET; or &cv-SOURCE;: + + + + + Command("file.out", [], Copy("$TARGET", "file.in")) + + + + + Which executes as: + + + + + % scons -Q + Copy("file.out", "file.in") + + + + + The usefulness of the &Copy; factory + becomes more apparent when + you use it in a list of actions + passed to the &Command; builder. + For example, suppose you needed to run a + file through a utility that only modifies files in-place, + and can't "pipe" input to output. + One solution is to copy the source file + to a temporary file name, + run the utility, + and then copy the modified temporary file to the target, + which the &Copy; factory makes extremely easy: + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Copy("$TARGET", "tempfile"), + ]) + + + + + The output then looks like: + + + + + % scons -Q + Copy("tempfile", "file.in") + modify tempfile + Copy("file.out", "tempfile") + + +
+ +
+ Deleting Files or Directories: The &Delete; Factory + + + + If you need to delete a file, + then the &Delete; factory + can be used in much the same way as + the &Copy; factory. + For example, if we want to make sure that + the temporary file + in our last example doesn't exist before + we copy to it, + we could add &Delete; to the beginning + of the command list: + + + + + Command("file.out", "file.in", + [ + Delete("tempfile"), + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Copy("$TARGET", "tempfile"), + ]) + + + + + When then executes as follows: + + + + + % scons -Q + Delete("tempfile") + Copy("tempfile", "file.in") + modify tempfile + Copy("file.out", "tempfile") + + + + + Of course, like all of these &Action; factories, + the &Delete; factory also expands + &cv-TARGET; and &cv-SOURCE; variables appropriately. + For example: + + + + + Command("file.out", "file.in", + [ + Delete("$TARGET"), + Copy("$TARGET", "$SOURCE") + ]) + + + + + Executes as: + + + + + % scons -Q + Delete("file.out") + Copy("file.out", "file.in") + + + + + (Note, however, that you typically don't need to + call the &Delete; factory explicitly in this way; + by default, &SCons; deletes its target(s) + for you before executing any action. + + + +
+ +
+ Moving (Renaming) Files or Directories: The &Move; Factory + + + + The &Move; factory + allows you to rename a file or directory. + For example, if we don't want to copy the temporary file, + we could: + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Move("$TARGET", "tempfile"), + ]) + + + + + Which would execute as: + + + + + % scons -Q + Copy("tempfile", "file.in") + modify tempfile + Move("file.out", "tempfile") + + +
+ +
+ Updating the Modification Time of a File: The &Touch; Factory + + + + If you just need to update the + recorded modification time for a file, + use the &Touch; factory: + + + + + Command("file.out", "file.in", + [ + Copy("tempfile", "$SOURCE"), + "modify tempfile", + Move("$TARGET", "tempfile"), + ]) + + + + + Which executes as: + + + + + % scons -Q + Copy("tempfile", "file.in") + modify tempfile + Move("file.out", "tempfile") + + +
+ +
+ Creating a Directory: The &Mkdir; Factory + + + + If you need to create a directory, + use the &Mkdir; factory. + For example, if we need to process + a file in a temporary directory + in which the processing tool + will create other files that we don't care about, + you could: + + + + + Command("file.out", "file.in", + [ + Delete("tempdir"), + Mkdir("tempdir"), + Copy("tempdir/${SOURCE.file}", "$SOURCE"), + "process tempdir", + Move("$TARGET", "tempdir/output_file"), + Delete("tempdir"), + ]) + + + + + Which executes as: + + + + + % scons -Q + Delete("tempdir") + Mkdir("tempdir") + Copy("tempdir/file.in", "file.in") + process tempdir + Move("file.out", "tempdir/output_file") + scons: *** [file.out] No such file or directory + + +
+ +
+ Changing File or Directory Permissions: The &Chmod; Factory + + + + To change permissions on a file or directory, + use the &Chmod; factory. + The permission argument uses POSIX-style + permission bits and should typically + be expressed as an octal, + not decimal, number: + + + + + Command("file.out", "file.in", + [ + Copy("$TARGET", "$SOURCE"), + Chmod("$TARGET", 0755), + ]) + + + + + Which executes: + + + + + % scons -Q + Copy("file.out", "file.in") + Chmod("file.out", 0755) + + +
+ +
+ Executing an action immediately: the &Execute; Function + + + + We've been showing you how to use &Action; factories + in the &Command; function. + You can also execute an &Action; returned by a factory + (or actually, any &Action;) + at the time the &SConscript; file is read + by wrapping it up in the &Execute; function. + For example, if we need to make sure that + a directory exists before we build any targets, + + + + + + Execute(Mkdir('/tmp/my_temp_directory')) + + + + + Notice that this will + create the directory while + the &SConscript; file is being read: + + + + + % scons + scons: Reading SConscript files ... + Mkdir("/tmp/my_temp_directory") + scons: done reading SConscript files. + scons: Building targets ... + scons: `.' is up to date. + scons: done building targets. + + + + + If you're familiar with Python, + you may wonder why you would want to use this + instead of just calling the native Python + os.mkdir() function. + The advantage here is that the &Mkdir; + action will behave appropriately if the user + specifies the &SCons; or + options--that is, + it will print the action but not actually + make the directory when is specified, + or make the directory but not print the action + when is specified. + + + +
diff --git a/doc/user/help.in b/doc/user/help.in index d4b2caa6..4356d18c 100644 --- a/doc/user/help.in +++ b/doc/user/help.in @@ -61,7 +61,66 @@
- scons -h + scons -h + + + + + The &SConscript; files may contain + multiple calls to the &Help; function, + in which case the specified text(s) + will be concatenated when displayed. + This allows you to split up the + help text across multiple &SConscript; files. + In this situation, the order in + which the &SConscript; files are called + will determine the order in which the &Help; functions are called, + which will determine the order in which + the various bits of text will get concatenated. + + + + + + Another use would be to make the help text conditional + on some variable. + For example, suppose you only want to display + a line about building a Windows-only + version of a program when actually + run on Windows. + The following &SConstruct; file: + + + + + + env = Environment() + + Help("\nType: 'scons program' to build the production program.\n") + + if env['PLATFORM'] == 'win32': + Help("\nType: 'scons windebug' to build the Windows debug version.\n") + + + + + + Will display the completely help text on Windows: + + + + + scons -h + + + + + But only show the relevant option on a Linux or UNIX system: + + + + + scons -h diff --git a/doc/user/help.sgml b/doc/user/help.sgml index 9db5bf09..ca44a40f 100644 --- a/doc/user/help.sgml +++ b/doc/user/help.sgml @@ -71,6 +71,77 @@ + The &SConscript; files may contain + multiple calls to the &Help; function, + in which case the specified text(s) + will be concatenated when displayed. + This allows you to split up the + help text across multiple &SConscript; files. + In this situation, the order in + which the &SConscript; files are called + will determine the order in which the &Help; functions are called, + which will determine the order in which + the various bits of text will get concatenated. + + + + + + Another use would be to make the help text conditional + on some variable. + For example, suppose you only want to display + a line about building a Windows-only + version of a program when actually + run on Windows. + The following &SConstruct; file: + + + + + env = Environment() + + Help("\nType: 'scons program' to build the production program.\n") + + if env['PLATFORM'] == 'win32': + Help("\nType: 'scons windebug' to build the Windows debug version.\n") + + + + + Will display the completely help text on Windows: + + + + + C:\>scons -h + scons: Reading SConscript files ... + scons: done reading SConscript files. + + Type: 'scons program' to build the production program. + + Type: 'scons windebug' to build the Windows debug version. + + Use scons -H for help about command-line options. + + + + + But only show the relevant option on a Linux or UNIX system: + + + + + % scons -h + scons: Reading SConscript files ... + scons: done reading SConscript files. + + Type: 'scons program' to build the production program. + + Use scons -H for help about command-line options. + + + + If there is no &Help; text in the &SConstruct; or &SConscript; files, &SCons; will revert to displaying its diff --git a/doc/user/hierarchy.in b/doc/user/hierarchy.in index 0c4563d4..355aca34 100644 --- a/doc/user/hierarchy.in +++ b/doc/user/hierarchy.in @@ -340,7 +340,7 @@ make no difference to the build. - scons -Q + scons -Q @@ -411,7 +411,7 @@ make no difference to the build. - scons -Q + scons -Q @@ -462,7 +462,7 @@ make no difference to the build. - scons -Q + scons -Q @@ -767,7 +767,7 @@ make no difference to the build. - scons -Q + scons -Q diff --git a/doc/user/install.in b/doc/user/install.in index dfbb822f..ac9510f2 100644 --- a/doc/user/install.in +++ b/doc/user/install.in @@ -62,8 +62,8 @@ - scons -Q - scons -Q __ROOT__/usr/bin + scons -Q + scons -Q __ROOT__/usr/bin @@ -101,8 +101,8 @@ - scons -Q - scons -Q install + scons -Q + scons -Q install
@@ -155,7 +155,7 @@ - scons -Q install + scons -Q install
@@ -194,7 +194,7 @@ - scons -Q install + scons -Q install @@ -241,7 +241,7 @@ - scons -Q install + scons -Q install diff --git a/doc/user/java.in b/doc/user/java.in index 66b9c867..9768dabc 100644 --- a/doc/user/java.in +++ b/doc/user/java.in @@ -38,7 +38,7 @@
- Building Java Class Files: the &Java; Builder + Building Java Class Files: the &b-Java; Builder @@ -49,7 +49,7 @@ to turn them into one or more .class files. In &SCons;, you do this - by giving the &Java; Builder + by giving the &b-link-Java; Builder a target directory in which to put the .class files, and a source directory that contains @@ -99,7 +99,7 @@ - scons -Q + scons -Q @@ -191,8 +191,8 @@ - scons -Q - scons -Q classes + scons -Q + scons -Q classes @@ -215,25 +215,25 @@ - scons -Q - scons -Q -c classes + scons -Q + scons -Q -c classes
- Building Java Archive (<filename>.jar</filename>) Files: the &Jar; Builder + Building Java Archive (<filename>.jar</filename>) Files: the &b-Jar; Builder After building the class files, it's common to collect them into a Java archive (.jar) file, - which you do by calling the &Jar; Builder method. + which you do by calling the &b-link-Jar; Builder method. If you want to just collect all of the class files within a subdirectory, you can just specify that subdirectory - as the &Jar; source: + as the &b-Jar; source: @@ -281,7 +281,7 @@ - scons -Q + scons -Q @@ -291,13 +291,13 @@ for multiple programs in one location, and only archive some of them in each .jar file, - you can pass the &Jar; builder a + you can pass the &b-Jar; builder a list of files as its source. It's extremely simple to create multiple .jar files this way, using the lists of target class files created - by calls to the &Java; builder - as sources to the various &Jar; calls: + by calls to the &b-link-Java; builder + as sources to the various &b-Jar; calls: @@ -357,19 +357,19 @@ - scons -Q + scons -Q
- Building C Header and Stub Files: the &JavaH; Builder + Building C Header and Stub Files: the &b-JavaH; Builder You can generate C header and source files for implementing native methods, - by using the &JavaH; Builder. + by using the &b-link-JavaH; Builder. There are several ways of using the &JavaH Builder. One typical invocation might look like: @@ -412,7 +412,7 @@ The source is a list of class files generated by the - call to the &Java; Builder, + call to the &b-link-Java; Builder, and the target is the output directory in which we want the C header files placed. The target @@ -422,7 +422,7 @@ - scons -Q + scons -Q @@ -447,15 +447,15 @@ Although it's more convenient to use the list of class files returned by - the &Java; Builder - as the source of a call to the &JavaH; Builder, + the &b-Java; Builder + as the source of a call to the &b-JavaH; Builder, you can specify the list of class files by hand, if you prefer. If you do, you need to set the - &JAVACLASSDIR; construction variable - when calling &JavaH;: + &cv-link-JAVACLASSDIR; construction variable + when calling &b-JavaH;: @@ -498,14 +498,14 @@ - The &JAVACLASSDIR; value then + The &cv-JAVACLASSDIR; value then gets converted into the when &SCons; runs &javah;: - scons -Q + scons -Q @@ -513,7 +513,7 @@ Lastly, if you don't want a separate header file generated for each source file, you can specify an explicit File Node - as the target of the &JavaH; Builder: + as the target of the &b-JavaH; Builder: @@ -554,7 +554,7 @@ Because &SCons; assumes by default - that the target of the &JavaH; builder is a directory, + that the target of the &b-JavaH; builder is a directory, you need to use the &File; function to make sure that &SCons; doesn't create a directory named native.h. @@ -565,20 +565,20 @@ - scons -Q + scons -Q
- Building RMI Stub and Skeleton Class Files: the &RMIC; Builder + Building RMI Stub and Skeleton Class Files: the &b-RMIC; Builder You can generate Remote Method Invocation stubs - by using the &RMIC; Builder. + by using the &b-link-RMIC; Builder. The source is a list of directories, - typically returned by a call to the &Java; Builder, + typically returned by a call to the &b-link-Java; Builder, and the target is an output directory where the _Stub.class and _Skel.class files will @@ -613,7 +613,7 @@ - As it did with the &JavaH; Builder, + As it did with the &b-link-JavaH; Builder, &SCons; remembers the class directory and passes it as the option to &rmic: @@ -621,7 +621,7 @@ - scons -Q + scons -Q diff --git a/doc/user/java.sgml b/doc/user/java.sgml index e3eee533..18769168 100644 --- a/doc/user/java.sgml +++ b/doc/user/java.sgml @@ -38,7 +38,7 @@
- Building Java Class Files: the &Java; Builder + Building Java Class Files: the &b-Java; Builder @@ -49,7 +49,7 @@ to turn them into one or more .class files. In &SCons;, you do this - by giving the &Java; Builder + by giving the &b-link-Java; Builder a target directory in which to put the .class files, and a source directory that contains @@ -158,18 +158,18 @@
- Building Java Archive (<filename>.jar</filename>) Files: the &Jar; Builder + Building Java Archive (<filename>.jar</filename>) Files: the &b-Jar; Builder After building the class files, it's common to collect them into a Java archive (.jar) file, - which you do by calling the &Jar; Builder method. + which you do by calling the &b-link-Jar; Builder method. If you want to just collect all of the class files within a subdirectory, you can just specify that subdirectory - as the &Jar; source: + as the &b-Jar; source: @@ -200,13 +200,13 @@ for multiple programs in one location, and only archive some of them in each .jar file, - you can pass the &Jar; builder a + you can pass the &b-Jar; builder a list of files as its source. It's extremely simple to create multiple .jar files this way, using the lists of target class files created - by calls to the &Java; builder - as sources to the various &Jar; calls: + by calls to the &b-link-Java; builder + as sources to the various &b-Jar; calls: @@ -238,13 +238,13 @@
- Building C Header and Stub Files: the &JavaH; Builder + Building C Header and Stub Files: the &b-JavaH; Builder You can generate C header and source files for implementing native methods, - by using the &JavaH; Builder. + by using the &b-link-JavaH; Builder. There are several ways of using the &JavaH; Builder. One typical invocation might look like: @@ -258,7 +258,7 @@ The source is a list of class files generated by the - call to the &Java; Builder, + call to the &b-link-Java; Builder, and the target is the output directory in which we want the C header files placed. The target @@ -295,15 +295,15 @@ Although it's more convenient to use the list of class files returned by - the &Java; Builder - as the source of a call to the &JavaH; Builder, + the &b-Java; Builder + as the source of a call to the &b-JavaH; Builder, you can specify the list of class files by hand, if you prefer. If you do, you need to set the - &JAVACLASSDIR; construction variable - when calling &JavaH;: + &cv-link-JAVACLASSDIR; construction variable + when calling &b-JavaH;: @@ -317,7 +317,7 @@ - The &JAVACLASSDIR; value then + The &cv-JAVACLASSDIR; value then gets converted into the when &SCons; runs &javah;: @@ -334,7 +334,7 @@ Lastly, if you don't want a separate header file generated for each source file, you can specify an explicit File Node - as the target of the &JavaH; Builder: + as the target of the &b-JavaH; Builder: @@ -346,7 +346,7 @@ Because &SCons; assumes by default - that the target of the &JavaH; builder is a directory, + that the target of the &b-JavaH; builder is a directory, you need to use the &File; function to make sure that &SCons; doesn't create a directory named native.h. @@ -365,14 +365,14 @@
- Building RMI Stub and Skeleton Class Files: the &RMIC; Builder + Building RMI Stub and Skeleton Class Files: the &b-RMIC; Builder You can generate Remote Method Invocation stubs - by using the &RMIC; Builder. + by using the &b-link-RMIC; Builder. The source is a list of directories, - typically returned by a call to the &Java; Builder, + typically returned by a call to the &b-link-Java; Builder, and the target is an output directory where the _Stub.class and _Skel.class files will @@ -387,7 +387,7 @@ - As it did with the &JavaH; Builder, + As it did with the &b-link-JavaH; Builder, &SCons; remembers the class directory and passes it as the option to &rmic;: diff --git a/doc/user/less-simple.in b/doc/user/less-simple.in index c0dafb10..ccc59b65 100644 --- a/doc/user/less-simple.in +++ b/doc/user/less-simple.in @@ -40,7 +40,7 @@ - You've seen that when you call the &Program; builder method, + You've seen that when you call the &b-link-Program; builder method, it builds the resulting program with the same base name as the source file. That is, the following call to build an @@ -91,7 +91,7 @@ - scons -Q + scons -Q @@ -102,7 +102,7 @@ - scons -Q + scons -Q
@@ -146,7 +146,7 @@
- scons -Q + scons -Q @@ -193,7 +193,7 @@ - scons -Q + scons -Q @@ -203,7 +203,7 @@ - scons -Q + scons -Q
@@ -220,7 +220,7 @@ - Program('hello', ['file1.c', 'file2']) + Program('hello', ['file1.c', 'file2.c']) @@ -351,13 +351,13 @@ Putting the call to the &Split; function - inside the Program call + inside the &b-Program; call can also be a little unwieldy. A more readable alternative is to assign the output from the &Split; call to a variable name, and then use the variable when calling the - Program function: + &b-Program; function: @@ -451,7 +451,7 @@ In order to compile multiple programs within the same &SConstruct; file, - simply call the Program method + simply call the &Program; method multiple times, once for each program you need to build: @@ -480,7 +480,7 @@ - scons -Q + scons -Q @@ -555,7 +555,7 @@ - scons -Q + scons -Q diff --git a/doc/user/less-simple.sgml b/doc/user/less-simple.sgml index d3a6edcd..1aa993d7 100644 --- a/doc/user/less-simple.sgml +++ b/doc/user/less-simple.sgml @@ -40,7 +40,7 @@ - You've seen that when you call the &Program; builder method, + You've seen that when you call the &b-link-Program; builder method, it builds the resulting program with the same base name as the source file. That is, the following call to build an @@ -209,7 +209,7 @@ - Program('hello', ['file1.c', 'file2']) + Program('hello', ['file1.c', 'file2.c']) @@ -340,13 +340,13 @@ Putting the call to the &Split; function - inside the Program call + inside the &b-Program; call can also be a little unwieldy. A more readable alternative is to assign the output from the &Split; call to a variable name, and then use the variable when calling the - Program function: + &b-Program; function: @@ -440,7 +440,7 @@ In order to compile multiple programs within the same &SConstruct; file, - simply call the Program method + simply call the &Program; method multiple times, once for each program you need to build: diff --git a/doc/user/libraries.in b/doc/user/libraries.in index 542cd134..e5368d17 100644 --- a/doc/user/libraries.in +++ b/doc/user/libraries.in @@ -37,8 +37,8 @@ - You build your own libraries by specifying &Library; - instead of &Program;: + You build your own libraries by specifying &b-link-Library; + instead of &b-link-Program;: @@ -67,7 +67,7 @@ - scons -Q + scons -Q @@ -78,7 +78,7 @@ - scons -Q + scons -Q @@ -94,14 +94,14 @@
- Building Static Libraries Explicitly: the &StaticLibrary; Builder + Building Static Libraries Explicitly: the &b-StaticLibrary; Builder - The &Library; function builds a traditional static library. + The &b-link-Library; function builds a traditional static library. If you want to be explicit about the type of library being built, - you can use the synonym &StaticLibrary; function - instead of &Library: + you can use the synonym &b-link-StaticLibrary; function + instead of &b-Library: @@ -114,20 +114,20 @@ There is no functional difference between the - &StaticLibrary; and &Library; functions. + &b-link-StaticLibrary; and &b-Library; functions.
- Building Shared (DLL) Libraries: the &SharedLibrary; Builder + Building Shared (DLL) Libraries: the &b-SharedLibrary; Builder If you want to build a shared library (on POSIX systems) or a DLL file (on Windows systems), - you use the &SharedLibrary; function: + you use the &b-link-SharedLibrary; function: @@ -153,7 +153,7 @@ - scons -Q + scons -Q @@ -163,7 +163,7 @@ - scons -Q + scons -Q @@ -188,10 +188,10 @@ Usually, you build a library because you want to link it with one or more programs. You link libraries with a program by specifying - the libraries in the &LIBS; construction variable, + the libraries in the &cv-link-LIBS; construction variable, and by specifying the directory in which the library will be found in the - &LIBPATH; construction variable: + &cv-link-LIBPATH; construction variable: @@ -231,7 +231,7 @@ - scons -Q + scons -Q @@ -242,7 +242,7 @@ - scons -Q + scons -Q @@ -288,7 +288,7 @@
- Finding Libraries: the &LIBPATH; Construction Variable + Finding Libraries: the &cv-LIBPATH; Construction Variable @@ -296,8 +296,8 @@ certain system-defined directories for libraries. &SCons; knows how to look for libraries in directories that you specify with the - &LIBPATH; construction variable. - &LIBPATH; consists of a list of + &cv-link-LIBPATH; construction variable. + &cv-LIBPATH; consists of a list of directory names, like so: @@ -356,7 +356,7 @@ - scons -Q + scons -Q @@ -367,7 +367,7 @@ - scons -Q + scons -Q diff --git a/doc/user/libraries.sgml b/doc/user/libraries.sgml index 8e25c9a9..aab30450 100644 --- a/doc/user/libraries.sgml +++ b/doc/user/libraries.sgml @@ -37,8 +37,8 @@ - You build your own libraries by specifying &Library; - instead of &Program;: + You build your own libraries by specifying &b-link-Library; + instead of &b-link-Program;: @@ -92,14 +92,14 @@
- Building Static Libraries Explicitly: the &StaticLibrary; Builder + Building Static Libraries Explicitly: the &b-StaticLibrary; Builder - The &Library; function builds a traditional static library. + The &b-link-Library; function builds a traditional static library. If you want to be explicit about the type of library being built, - you can use the synonym &StaticLibrary; function - instead of &Library;: + you can use the synonym &b-link-StaticLibrary; function + instead of &b-Library: @@ -110,20 +110,20 @@ There is no functional difference between the - &StaticLibrary; and &Library; functions. + &b-link-StaticLibrary; and &b-Library; functions.
- Building Shared (DLL) Libraries: the &SharedLibrary; Builder + Building Shared (DLL) Libraries: the &b-SharedLibrary; Builder If you want to build a shared library (on POSIX systems) or a DLL file (on Windows systems), - you use the &SharedLibrary; function: + you use the &b-link-SharedLibrary; function: @@ -157,6 +157,7 @@ cl /nologo /c f2.c /Fof2.obj cl /nologo /c f3.c /Fof3.obj link /nologo /dll /out:foo.dll /implib:foo.lib f1.obj f2.obj f3.obj + RegServerFunc(target, source, env) @@ -181,10 +182,10 @@ Usually, you build a library because you want to link it with one or more programs. You link libraries with a program by specifying - the libraries in the &LIBS; construction variable, + the libraries in the &cv-link-LIBS; construction variable, and by specifying the directory in which the library will be found in the - &LIBPATH; construction variable: + &cv-link-LIBPATH; construction variable: @@ -280,7 +281,7 @@
- Finding Libraries: the &LIBPATH; Construction Variable + Finding Libraries: the &cv-LIBPATH; Construction Variable @@ -288,8 +289,8 @@ certain system-defined directories for libraries. &SCons; knows how to look for libraries in directories that you specify with the - &LIBPATH; construction variable. - &LIBPATH; consists of a list of + &cv-link-LIBPATH; construction variable. + &cv-LIBPATH; consists of a list of directory names, like so: diff --git a/doc/user/main.in b/doc/user/main.in index 3e0e047c..a720915b 100644 --- a/doc/user/main.in +++ b/doc/user/main.in @@ -32,10 +32,20 @@ %scons; + + %builders-mod; + + + %tools-mod; + + + %variables-mod; + + @@ -48,6 +58,7 @@ + @@ -56,8 +67,10 @@ + + @@ -66,9 +79,15 @@ + + + + + + ]> @@ -137,6 +156,15 @@ &environments; + + Controlling the External Environment Used to Execute Build Commands &ENV_file; @@ -157,6 +185,11 @@ &install; + + Platform-Independent File System Manipulation + &factories; + + Preventing Removal of Targets: the &Precious; Function &precious; @@ -273,6 +306,21 @@ Tools() --> + + Construction Variables + &variables; + + + + Builders + &builders; + + + + Tools + &tools; + + Handling Common Tasks &tasks; @@ -280,6 +328,11 @@ + Controlling the External Environment Used to Execute Build Commands &ENV_file; @@ -157,6 +185,11 @@ &install; + + Platform-Independent File System Manipulation + &factories; + + Preventing Removal of Targets: the &Precious; Function &precious; @@ -273,6 +306,21 @@ Tools() --> + + Construction Variables + &variables; + + + + Builders + &builders; + + + + Tools + &tools; + + Handling Common Tasks &tasks; @@ -280,6 +328,11 @@ + + + + Configuring the right options to build programs to work with the + libraries--especially shared libraries--installed on a POSIX system + can be very complicated. + Various utilies with names that end in config + can return command-line options for the + GNU Compiler Collection + + + + + + &SCons; construction environments have a &ParseConfig; method + that executes a utility and configures + the appropriate construction variables + in the environment + based on the command-line options + returned by the specified command. + + + + + + + + env = Environment() + env.ParseConfig("pkg-config") + + + int f1() { } + + + int f2() { } + + + int f3() { } + + + + + + &SCons; will execute the specified command string + and XXX + + + + + scons -Q + + + + + XXX + + diff --git a/doc/user/parseconfig.sgml b/doc/user/parseconfig.sgml new file mode 100644 index 00000000..067ef375 --- /dev/null +++ b/doc/user/parseconfig.sgml @@ -0,0 +1,72 @@ + + + + + Configuring the right options to build programs to work with the + libraries--especially shared libraries--installed on a POSIX system + can be very complicated. + Various utilies with names that end in config + can return command-line options for the + GNU Compiler Collection + + + + + + &SCons; construction environments have a &ParseConfig; method + that executes a utility and configures + the appropriate construction variables + in the environment + based on the command-line options + returned by the specified command. + + + + + + + env = Environment() + env.ParseConfig("pkg-config") + + + + + &SCons; will execute the specified command string + and XXX + + + + + % scons -Q + scons: `.' is up to date. + Must specify package names on the command line + + + + + XXX + + diff --git a/doc/user/precious.in b/doc/user/precious.in index fb32f2bd..f5e000b0 100644 --- a/doc/user/precious.in +++ b/doc/user/precious.in @@ -79,7 +79,7 @@ which the C method is called. - scons -Q + scons -Q diff --git a/doc/user/preface.in b/doc/user/preface.in index 190dad13..9d0323e9 100644 --- a/doc/user/preface.in +++ b/doc/user/preface.in @@ -228,7 +228,8 @@ One word of warning as you read through this Guide: Like too much Open Source software out there, - the &SCons; documentation lags the available features. + the &SCons; documentation isn't always + kept up-to-date with the available features. In other words, there's a lot that &SCons; can do that isn't yet covered in this User's Guide. diff --git a/doc/user/preface.sgml b/doc/user/preface.sgml index dfececda..47dbd983 100644 --- a/doc/user/preface.sgml +++ b/doc/user/preface.sgml @@ -228,7 +228,8 @@ One word of warning as you read through this Guide: Like too much Open Source software out there, - the &SCons; documentation lags the available features. + the &SCons; documentation isn't always + kept up-to-date with the available features. In other words, there's a lot that &SCons; can do that isn't yet covered in this User's Guide. diff --git a/doc/user/python.in b/doc/user/python.in new file mode 100644 index 00000000..e2a7cdd0 --- /dev/null +++ b/doc/user/python.in @@ -0,0 +1,154 @@ + + + diff --git a/doc/user/python.sgml b/doc/user/python.sgml new file mode 100644 index 00000000..e2a7cdd0 --- /dev/null +++ b/doc/user/python.sgml @@ -0,0 +1,154 @@ + + + diff --git a/doc/user/repositories.in b/doc/user/repositories.in index 79d9a758..d2c92369 100644 --- a/doc/user/repositories.in +++ b/doc/user/repositories.in @@ -240,7 +240,7 @@ subdirectories under the repository tree. - scons -Q + scons -Q @@ -264,7 +264,7 @@ subdirectories under the repository tree. - scons -Q + scons -Q gcc -c /usr/repository1/hello.c -o hello.o gcc -o hello hello.o @@ -289,7 +289,7 @@ subdirectories under the repository tree. - scons -Q + scons -Q @@ -376,8 +376,8 @@ subdirectories under the repository tree. - cd /usr/repository1 - scons -Q + cd /usr/repository1 + scons -Q @@ -402,9 +402,9 @@ subdirectories under the repository tree. diff --git a/doc/user/repositories.sgml b/doc/user/repositories.sgml index e728bc4e..03928536 100644 --- a/doc/user/repositories.sgml +++ b/doc/user/repositories.sgml @@ -374,9 +374,9 @@ subdirectories under the repository tree. diff --git a/doc/user/scanners.in b/doc/user/scanners.in index 946c0580..a0029ef4 100644 --- a/doc/user/scanners.in +++ b/doc/user/scanners.in @@ -228,7 +228,7 @@ over the file scanning rather than being called for each input line: A list of directories that form the search path for included files for this scanner. - This is how &SCons; handles the &CPPPATH; and &LIBPATH; + This is how &SCons; handles the &cv-link-CPPPATH; and &cv-link-LIBPATH; variables. @@ -257,7 +257,7 @@ over the file scanning rather than being called for each input line: which typically takes an skeys argument to associate the type of file suffix with this scanner. The Scanner object must then be associated with the - &SCANNERS; construction variable of a construction environment, + &cv-link-SCANNERS; construction variable of a construction environment, typically by using the &Append; method: @@ -320,10 +320,10 @@ over the file scanning rather than being called for each input line: - scons -Q - edit other_file - scons -Q - scons -Q + scons -Q + edit other_file + scons -Q + scons -Q --> diff --git a/doc/user/scanners.sgml b/doc/user/scanners.sgml index 46323698..b4756c53 100644 --- a/doc/user/scanners.sgml +++ b/doc/user/scanners.sgml @@ -228,7 +228,7 @@ over the file scanning rather than being called for each input line: A list of directories that form the search path for included files for this scanner. - This is how &SCons; handles the &CPPPATH; and &LIBPATH; + This is how &SCons; handles the &cv-link-CPPPATH; and &cv-link-LIBPATH; variables. @@ -257,7 +257,7 @@ over the file scanning rather than being called for each input line: which typically takes an skeys argument to associate the type of file suffix with this scanner. The Scanner object must then be associated with the - &SCANNERS; construction variable of a construction environment, + &cv-link-SCANNERS; construction variable of a construction environment, typically by using the &Append; method: @@ -306,10 +306,10 @@ over the file scanning rather than being called for each input line: - scons -Q - edit other_file - scons -Q - scons -Q + scons -Q + edit other_file + scons -Q + scons -Q --> diff --git a/doc/user/sconf.in b/doc/user/sconf.in index 525b0fc4..14c10b7c 100644 --- a/doc/user/sconf.in +++ b/doc/user/sconf.in @@ -67,6 +67,28 @@ + &SCons; provides a number of basic checks, + as well as a mechanism for adding your own custom checks. + + + + + + Note that &SCons; uses its own dependency + mechanism to determine when a check + needs to be run--that is, + &SCons; does not run the checks + every time it is invoked, + but caches the values returned by previous checks + and uses the cached values unless something has changed. + This saves a tremendous amount + of developer time while working on + cross-platform build issues. + + + + + The next sections describe the basic checks that &SCons; supports, as well as how to add your own custom checks. @@ -229,14 +251,14 @@ - + env = Environment() conf = Configure(env) if not conf.CheckType('off_t', '#include &lt;sys/types.h&gt;\n'): print 'Did not find off_t typedef, assuming int' conf.env.Append(CCFLAGS = '-Doff_t=int') env = conf.Finish() - +
@@ -259,7 +281,7 @@ - + mylib_test_source_file = """ #include &lt;mylib.h&gt; int main(int argc, char **argv) @@ -274,7 +296,7 @@ result = context.TryLink(mylib_test_source_file, '.c') context.Result(result) return result - + @@ -336,7 +358,7 @@ - + mylib_test_source_file = """ #include &lt;mylib.h&gt; int main(int argc, char **argv) @@ -361,7 +383,7 @@ # We would then add actual calls like Program() to build # something using the "env" construction environment. - + @@ -396,3 +418,54 @@
+ +
+ Not Configuring When Cleaning Targets + + + + Using multi-platform configuration + as described in the previous sections + will run the configuration commands + even when invoking + scons -c + to clean targets: + + + + + % scons -Q -c + Checking for MyLibrary... ok + Removed foo.o + Removed foo + + + + + Although running the platform checks + when removing targets doesn't hurt anything, + it's usually unnecessary. + You can avoid this by using the + &GetOption(); method to + check whether the (clean) + option has been invoked on the command line: + + + + + env = Environment() + if not env.GetOption('clean'): + conf = Configure(env, custom_tests = {'CheckMyLibrary' : CheckMyLibrary}) + if not conf.CheckMyLibrary(): + print 'MyLibrary is not installed!' + Exit(1) + env = conf.Finish() + + + + % scons -Q -c + Removed foo.o + Removed foo + + +
diff --git a/doc/user/sconf.sgml b/doc/user/sconf.sgml index 2e2a698a..997c97d2 100644 --- a/doc/user/sconf.sgml +++ b/doc/user/sconf.sgml @@ -67,6 +67,28 @@ + &SCons; provides a number of basic checks, + as well as a mechanism for adding your own custom checks. + + + + + + Note that &SCons; uses its own dependency + mechanism to determine when a check + needs to be run--that is, + &SCons; does not run the checks + every time it is invoked, + but caches the values returned by previous checks + and uses the cached values unless something has changed. + This saves a tremendous amount + of developer time while working on + cross-platform build issues. + + + + + The next sections describe the basic checks that &SCons; supports, as well as how to add your own custom checks. @@ -396,3 +418,54 @@
+ +
+ Not Configuring When Cleaning Targets + + + + Using multi-platform configuration + as described in the previous sections + will run the configuration commands + even when invoking + scons -c + to clean targets: + + + + + % scons -Q -c + Checking for MyLibrary... ok + Removed foo.o + Removed foo + + + + + Although running the platform checks + when removing targets doesn't hurt anything, + it's usually unnecessary. + You can avoid this by using the + &GetOption;(); method to + check whether the (clean) + option has been invoked on the command line: + + + + + env = Environment() + if not env.GetOption('clean'): + conf = Configure(env, custom_tests = {'CheckMyLibrary' : CheckMyLibrary}) + if not conf.CheckMyLibrary(): + print 'MyLibrary is not installed!' + Exit(1) + env = conf.Finish() + + + + % scons -Q -c + Removed foo.o + Removed foo + + +
diff --git a/doc/user/separate.in b/doc/user/separate.in index d613f424..6d497a20 100644 --- a/doc/user/separate.in +++ b/doc/user/separate.in @@ -160,9 +160,9 @@ program using the F path name. - ls src - scons -Q - ls build + ls src + scons -Q + ls build @@ -357,9 +357,9 @@ program using the F path name. - ls src - scons -Q - ls build + ls src + scons -Q + ls build @@ -388,9 +388,9 @@ program using the F path name. - ls src - scons -Q - ls build + ls src + scons -Q + ls build @@ -439,9 +439,9 @@ program using the F path name. - ls src - scons -Q - ls build + ls src + scons -Q + ls build diff --git a/doc/user/simple.in b/doc/user/simple.in index 4ac6d332..57fdd3ad 100644 --- a/doc/user/simple.in +++ b/doc/user/simple.in @@ -77,7 +77,7 @@ and the input file from which you want it built (the hello.c file). - &Program; is a &builder_method;, + &b-link-Program; is a builder_method, a Python call that tells &SCons; that you want to build an executable program. @@ -92,7 +92,7 @@ - scons + scons @@ -103,7 +103,7 @@ - scons + scons @@ -147,10 +147,10 @@ - The &Program; builder method is only one of + The &b-link-Program; builder method is only one of many builder methods that &SCons; provides to build different types of files. - Another is the &Object; builder method, + Another is the &b-link-Object; builder method, which tells &SCons; to build an object file from the specified source file: @@ -173,7 +173,7 @@ - scons + scons @@ -184,7 +184,7 @@ - scons + scons @@ -195,8 +195,8 @@ &SCons; also makes building with Java extremely easy. - Unlike the &Program; and &Object; builder methods, - however, the &Java; builder method + Unlike the &b-link-Program; and &b-link-Object; builder methods, + however, the &b-link-Java; builder method requires that you specify the name of a destination directory in which you want the class files placed, @@ -231,7 +231,7 @@ - scons + scons @@ -272,8 +272,8 @@ - scons - scons -c + scons + scons -c @@ -283,8 +283,8 @@ - scons - scons -c + scons + scons -c @@ -378,7 +378,7 @@ which to do things. - In other words, when you call the &Program; builder + In other words, when you call the &b-link-Program; builder (or any other builder method), you're not telling &SCons; to build the program at the instant the builder method is called. @@ -396,7 +396,7 @@ &SCons; reflects this distinction between - calling a builder method like &Program;> + calling a builder method like &b-Program;> and actually building the program by printing the status messages that indicate when it's "just reading" the &SConstruct; file, @@ -415,7 +415,7 @@ Python has a print statement that prints a string of characters to the screen. If we put print statements around - our calls to the &Program; builder method: + our calls to the &b-Program; builder method: @@ -447,7 +447,7 @@ - scons + scons @@ -475,7 +475,7 @@ - scons + scons @@ -501,7 +501,7 @@ - scons -Q + scons -Q diff --git a/doc/user/simple.sgml b/doc/user/simple.sgml index b925d041..fc68d170 100644 --- a/doc/user/simple.sgml +++ b/doc/user/simple.sgml @@ -72,7 +72,7 @@ and the input file from which you want it built (the hello.c file). - &Program; is a &builder_method;, + &b-link-Program; is a builder_method, a Python call that tells &SCons; that you want to build an executable program. @@ -154,10 +154,10 @@ - The &Program; builder method is only one of + The &b-link-Program; builder method is only one of many builder methods that &SCons; provides to build different types of files. - Another is the &Object; builder method, + Another is the &b-link-Object; builder method, which tells &SCons; to build an object file from the specified source file: @@ -207,8 +207,8 @@ &SCons; also makes building with Java extremely easy. - Unlike the &Program; and &Object; builder methods, - however, the &Java; builder method + Unlike the &b-link-Program; and &b-link-Object; builder methods, + however, the &b-link-Java; builder method requires that you specify the name of a destination directory in which you want the class files placed, @@ -401,7 +401,7 @@ which to do things. - In other words, when you call the &Program; builder + In other words, when you call the &b-link-Program; builder (or any other builder method), you're not telling &SCons; to build the program at the instant the builder method is called. @@ -419,7 +419,7 @@ &SCons; reflects this distinction between - calling a builder method like &Program;> + calling a builder method like &b-Program;> and actually building the program by printing the status messages that indicate when it's "just reading" the &SConstruct; file, @@ -438,7 +438,7 @@ Python has a print statement that prints a string of characters to the screen. If we put print statements around - our calls to the &Program; builder method: + our calls to the &b-Program; builder method: diff --git a/doc/user/sourcecode.in b/doc/user/sourcecode.in index c40c5129..04c76d04 100644 --- a/doc/user/sourcecode.in +++ b/doc/user/sourcecode.in @@ -54,7 +54,7 @@ - scons -Q + scons -Q @@ -77,7 +77,7 @@ - scons -Q + scons -Q @@ -103,7 +103,7 @@ - scons -Q + scons -Q @@ -129,7 +129,7 @@ - scons -Q + scons -Q @@ -154,7 +154,7 @@ - scons -Q + scons -Q diff --git a/doc/user/sourcecode.sgml b/doc/user/sourcecode.sgml index daa9ad78..6ea0b21f 100644 --- a/doc/user/sourcecode.sgml +++ b/doc/user/sourcecode.sgml @@ -153,7 +153,7 @@ - scons -Q + scons -Q diff --git a/doc/user/tools.in b/doc/user/tools.in new file mode 100644 index 00000000..8eaa35ea --- /dev/null +++ b/doc/user/tools.in @@ -0,0 +1,38 @@ + + + + +This appendix contains descriptions of all of the +Tools that are +available "out of the box" in this version of SCons. + + + + + +&tools-gen; + + diff --git a/doc/user/tools.sgml b/doc/user/tools.sgml new file mode 100644 index 00000000..8eaa35ea --- /dev/null +++ b/doc/user/tools.sgml @@ -0,0 +1,38 @@ + + + + +This appendix contains descriptions of all of the +Tools that are +available "out of the box" in this version of SCons. + + + + + +&tools-gen; + + diff --git a/doc/user/troubleshoot.in b/doc/user/troubleshoot.in index e5c008d3..206e50e6 100644 --- a/doc/user/troubleshoot.in +++ b/doc/user/troubleshoot.in @@ -77,9 +77,9 @@ - scons -Q - scons -Q - scons -Q + scons -Q + scons -Q + scons -Q @@ -100,7 +100,7 @@ - scons -Q --debug=explain + scons -Q --debug=explain @@ -145,9 +145,9 @@ - scons -Q - edit file2.c - scons -Q --debug=explain + scons -Q + edit file2.c + scons -Q --debug=explain @@ -188,9 +188,121 @@ - scons -Q - edit hello.h - scons -Q --debug=explain + scons -Q + edit hello.h + scons -Q --debug=explain + + + + +
+ What's in That Construction Environment? the &Dump; Method + + + + When you create a construction environment, + &SCons; populates it + with construction variables that are set up + for various compilers, linkers and utilities + that it finds on your system. + Although this is usually helpful and what you want, + it might be frustrating if &SCons; + doesn't set certain variables that you + expect to be sit. + In situations like this, + it's sometimes helpful to use the + construction environment &Dump; method + to print all or some of + the construction variables. + Note that the &Dump; method + returns + the representation of the variables + in the environment + for you to print (or otherwise manipulate): + + + + + + env = Environment() + print env.Dump() + + + + + + On a POSIX system with gcc installed, + this might generate: + + + + + scons + + + + + On a Windows system with Visual C++ + the output might look like: + + + + + scons + + + + + The construction environments in these examples have + actually been restricted to just gcc and Visual C++, + respectively. + In a real-life situation, + the construction environments will + likely contain a great many more variables. + + + + + + To make it easier to see just what you're + interested in, + the &Dump; method allows you to + specify a specific constrcution variable + that you want to disply. + For example, + it's not unusual to want to verify + the external environment used to execute build commands, + to make sure that the PATH and other + environment variables are set up the way they should be. + You can do this as follows: + + + + + + env = Environment() + print env.Dump('ENV') + + + + + + Which might display the following when executed on a POSIX system: + + + + + scons + + + + + And the following when executed on a Windows system: + + + + + scons
diff --git a/doc/user/troubleshoot.sgml b/doc/user/troubleshoot.sgml index aee2aee6..5cd1c9e5 100644 --- a/doc/user/troubleshoot.sgml +++ b/doc/user/troubleshoot.sgml @@ -185,3 +185,276 @@
+ +
+ What's in That Construction Environment? the &Dump; Method + + + + When you create a construction environment, + &SCons; populates it + with construction variables that are set up + for various compilers, linkers and utilities + that it finds on your system. + Although this is usually helpful and what you want, + it might be frustrating if &SCons; + doesn't set certain variables that you + expect to be sit. + In situations like this, + it's sometimes helpful to use the + construction environment &Dump; method + to print all or some of + the construction variables. + Note that the &Dump; method + returns + the representation of the variables + in the environment + for you to print (or otherwise manipulate): + + + + + + + + On a POSIX system with gcc installed, + this might generate: + + + + + % scons + scons: Reading SConscript files ... + { 'BUILDERS': {}, + 'CPPSUFFIXES': [ '.c', + '.C', + '.cxx', + '.cpp', + '.c++', + '.cc', + '.h', + '.H', + '.hxx', + '.hpp', + '.hh', + '.F', + '.fpp', + '.FPP', + '.S', + '.spp', + '.SPP'], + 'DSUFFIXES': ['.d'], + 'Dir': <SCons.Defaults.Variable_Method_Caller instance at 0x829dcb4>, + 'ENV': {'PATH': '/usr/local/bin:/bin:/usr/bin'}, + 'ESCAPE': <function escape at 0x837d2a4>, + 'File': <SCons.Defaults.Variable_Method_Caller instance at 0x829e0fc>, + 'IDLSUFFIXES': ['.idl', '.IDL'], + 'INSTALL': <function copyFunc at 0x829db9c>, + 'LIBPREFIX': 'lib', + 'LIBPREFIXES': '$LIBPREFIX', + 'LIBSUFFIX': '.a', + 'LIBSUFFIXES': ['$LIBSUFFIX', '$SHLIBSUFFIX'], + 'OBJPREFIX': '', + 'OBJSUFFIX': '.o', + 'PDFPREFIX': '', + 'PDFSUFFIX': '.pdf', + 'PLATFORM': 'posix', + 'PROGPREFIX': '', + 'PROGSUFFIX': '', + 'PSPAWN': <function piped_env_spawn at 0x837d384>, + 'PSPREFIX': '', + 'PSSUFFIX': '.ps', + 'RDirs': <SCons.Defaults.Variable_Method_Caller instance at 0x829e46c>, + 'SCANNERS': [], + 'SHELL': 'sh', + 'SHLIBPREFIX': '$LIBPREFIX', + 'SHLIBSUFFIX': '.so', + 'SHOBJPREFIX': '$OBJPREFIX', + 'SHOBJSUFFIX': '$OBJSUFFIX', + 'SPAWN': <function spawnvpe_spawn at 0x8377fdc>, + 'TEMPFILE': <class SCons.Defaults.NullCmdGenerator at 0x829ddec>, + 'TOOLS': [], + '_CPPDEFFLAGS': '${_defines(CPPDEFPREFIX, CPPDEFINES, CPPDEFSUFFIX, __env__)}', + '_CPPINCFLAGS': '$( ${_concat(INCPREFIX, CPPPATH, INCSUFFIX, __env__, RDirs, TARGET)} $)', + '_LIBDIRFLAGS': '$( ${_concat(LIBDIRPREFIX, LIBPATH, LIBDIRSUFFIX, __env__, RDirs, TARGET)} $)', + '_LIBFLAGS': '${_concat(LIBLINKPREFIX, LIBS, LIBLINKSUFFIX, __env__)}', + '__RPATH': '$_RPATH', + '_concat': <function _concat at 0x829dc0c>, + '_defines': <function _defines at 0x829dc7c>, + '_stripixes': <function _stripixes at 0x829dc44>} + scons: done reading SConscript files. + scons: Building targets ... + scons: `.' is up to date. + scons: done building targets. + + + + + On a Windows system with Visual C++ + the output might look like: + + + + + C:\>scons + scons: Reading SConscript files ... + { 'BUILDERS': {'Object': <SCons.Memoize.MultiStepBuilder object at 0x83493e4>, 'SharedObject': <SCons.Memoize.MultiStepBuilder object at 0x8349fec>, 'StaticObject': <SCons.Memoize.MultiStepBuilder object at 0x83493e4>, 'PCH': <SCons.Memoize.BuilderBase object at 0x83418cc>, 'RES': <SCons.Memoize.BuilderBase object at 0x8367cec>}, + 'CC': 'cl', + 'CCCOM': <SCons.Memoize.FunctionAction object at 0x8340454>, + 'CCCOMFLAGS': '$CPPFLAGS $_CPPDEFFLAGS $_CPPINCFLAGS /c $SOURCES /Fo$TARGET $CCPCHFLAGS $CCPDBFLAGS', + 'CCFLAGS': ['/nologo'], + 'CCPCHFLAGS': ['${(PCH and "/Yu%s /Fp%s"%(PCHSTOP or "",File(PCH))) or ""}'], + 'CCPDBFLAGS': ['${(PDB and "/Z7") or ""}'], + 'CFILESUFFIX': '.c', + 'CPPDEFPREFIX': '/D', + 'CPPDEFSUFFIX': '', + 'CPPSUFFIXES': [ '.c', + '.C', + '.cxx', + '.cpp', + '.c++', + '.cc', + '.h', + '.H', + '.hxx', + '.hpp', + '.hh', + '.F', + '.fpp', + '.FPP', + '.S', + '.spp', + '.SPP'], + 'CXX': '$CC', + 'CXXCOM': '$CXX $CXXFLAGS $CCCOMFLAGS', + 'CXXFILESUFFIX': '.cc', + 'CXXFLAGS': ['$CCFLAGS', '$(', '/TP', '$)'], + 'DSUFFIXES': ['.d'], + 'Dir': <SCons.Defaults.Variable_Method_Caller instance at 0x829dcb4>, + 'ENV': { 'INCLUDE': 'C:\\Program Files\\Microsoft Visual Studio/VC98\\include', + 'LIB': 'C:\\Program Files\\Microsoft Visual Studio/VC98\\lib', + 'PATH': 'C:\\Program Files\\Microsoft Visual Studio\\Common\\tools\\WIN95;C:\\Program Files\\Microsoft Visual Studio\\Common\\MSDev98\\bin;C:\\Program Files\\Microsoft Visual Studio\\Common\\tools;C:\\Program Files\\Microsoft Visual Studio/VC98\\bin', + 'PATHEXT': '.COM;.EXE;.BAT;.CMD'}, + 'ESCAPE': <function <lambda> at 0x82339ec>, + 'File': <SCons.Defaults.Variable_Method_Caller instance at 0x829e0fc>, + 'IDLSUFFIXES': ['.idl', '.IDL'], + 'INCPREFIX': '/I', + 'INCSUFFIX': '', + 'INSTALL': <function copyFunc at 0x829db9c>, + 'LIBPREFIX': '', + 'LIBPREFIXES': ['$LIBPREFIX'], + 'LIBSUFFIX': '.lib', + 'LIBSUFFIXES': ['$LIBSUFFIX'], + 'MAXLINELENGTH': 2048, + 'MSVS': {'VERSION': '6.0', 'VERSIONS': ['6.0']}, + 'MSVS_VERSION': '6.0', + 'OBJPREFIX': '', + 'OBJSUFFIX': '.obj', + 'PCHCOM': '$CXX $CXXFLAGS $CPPFLAGS $_CPPDEFFLAGS $_CPPINCFLAGS /c $SOURCES /Fo${TARGETS[1]} /Yc$PCHSTOP /Fp${TARGETS[0]} $CCPDBFLAGS $PCHPDBFLAGS', + 'PCHPDBFLAGS': ['${(PDB and "/Yd") or ""}'], + 'PDFPREFIX': '', + 'PDFSUFFIX': '.pdf', + 'PLATFORM': 'win32', + 'PROGPREFIX': '', + 'PROGSUFFIX': '.exe', + 'PSPAWN': <function piped_spawn at 0x8372bc4>, + 'PSPREFIX': '', + 'PSSUFFIX': '.ps', + 'RC': 'rc', + 'RCCOM': '$RC $_CPPDEFFLAGS $_CPPINCFLAGS $RCFLAGS /fo$TARGET $SOURCES', + 'RCFLAGS': [], + 'RDirs': <SCons.Defaults.Variable_Method_Caller instance at 0x829e46c>, + 'SCANNERS': [], + 'SHCC': '$CC', + 'SHCCCOM': <SCons.Memoize.FunctionAction object at 0x83494bc>, + 'SHCCFLAGS': ['$CCFLAGS'], + 'SHCXX': '$CXX', + 'SHCXXCOM': '$SHCXX $SHCXXFLAGS $CCCOMFLAGS', + 'SHCXXFLAGS': ['$CXXFLAGS'], + 'SHELL': None, + 'SHLIBPREFIX': '', + 'SHLIBSUFFIX': '.dll', + 'SHOBJPREFIX': '$OBJPREFIX', + 'SHOBJSUFFIX': '$OBJSUFFIX', + 'SPAWN': <function spawn at 0x8374c34>, + 'STATIC_AND_SHARED_OBJECTS_ARE_THE_SAME': 1, + 'TEMPFILE': <class SCons.Platform.win32.TempFileMunge at 0x835edc4>, + 'TOOLS': ['msvc'], + '_CPPDEFFLAGS': '${_defines(CPPDEFPREFIX, CPPDEFINES, CPPDEFSUFFIX, __env__)}', + '_CPPINCFLAGS': '$( ${_concat(INCPREFIX, CPPPATH, INCSUFFIX, __env__, RDirs, TARGET)} $)', + '_LIBDIRFLAGS': '$( ${_concat(LIBDIRPREFIX, LIBPATH, LIBDIRSUFFIX, __env__, RDirs, TARGET)} $)', + '_LIBFLAGS': '${_concat(LIBLINKPREFIX, LIBS, LIBLINKSUFFIX, __env__)}', + '_concat': <function _concat at 0x829dc0c>, + '_defines': <function _defines at 0x829dc7c>, + '_stripixes': <function _stripixes at 0x829dc44>} + scons: done reading SConscript files. + scons: Building targets ... + scons: `.' is up to date. + scons: done building targets. + + + + + The construction environments in these examples have + actually been restricted to just gcc and Visual C++, + respectively. + In a real-life situation, + the construction environments will + likely contain a great many more variables. + + + + + + To make it easier to see just what you're + interested in, + the &Dump; method allows you to + specify a specific constrcution variable + that you want to disply. + For example, + it's not unusual to want to verify + the external environment used to execute build commands, + to make sure that the PATH and other + environment variables are set up the way they should be. + You can do this as follows: + + + + + + + + Which might display the following when executed on a POSIX system: + + + + + % scons + scons: Reading SConscript files ... + {'PATH': '/usr/local/bin:/bin:/usr/bin'} + scons: done reading SConscript files. + scons: Building targets ... + scons: `.' is up to date. + scons: done building targets. + + + + + And the following when executed on a Windows system: + + + + + C:\>scons + scons: Reading SConscript files ... + { 'INCLUDE': 'C:\\Program Files\\Microsoft Visual Studio/VC98\\include', + 'LIB': 'C:\\Program Files\\Microsoft Visual Studio/VC98\\lib', + 'PATH': 'C:\\Program Files\\Microsoft Visual Studio\\Common\\tools\\WIN95;C:\\Program Files\\Microsoft Visual Studio\\Common\\MSDev98\\bin;C:\\Program Files\\Microsoft Visual Studio\\Common\\tools;C:\\Program Files\\Microsoft Visual Studio/VC98\\bin', + 'PATHEXT': '.COM;.EXE;.BAT;.CMD'} + scons: done reading SConscript files. + scons: Building targets ... + scons: `.' is up to date. + scons: done building targets. + + +
diff --git a/doc/user/variables.in b/doc/user/variables.in new file mode 100644 index 00000000..70099969 --- /dev/null +++ b/doc/user/variables.in @@ -0,0 +1,56 @@ + + + + +This appendix contains descriptions of all of the +construction variables that are potentially +available "out of the box" in this version of SCons. +Whether or not setting a construction variable +in a construction environment +will actually have an effect depends on +whether any of the Tools and/or Builders +that use the variable have been +included in the construction environment. + + + + + +In this appendix, we have +appended the initial $ +(dollar sign) to the beginning of each +variable name when it appears in the text, +but left off the dollar sign +in the left-hand column +where the name appears for each entry. + + + + + +&variables-gen; + + diff --git a/doc/user/variables.sgml b/doc/user/variables.sgml new file mode 100644 index 00000000..70099969 --- /dev/null +++ b/doc/user/variables.sgml @@ -0,0 +1,56 @@ + + + + +This appendix contains descriptions of all of the +construction variables that are potentially +available "out of the box" in this version of SCons. +Whether or not setting a construction variable +in a construction environment +will actually have an effect depends on +whether any of the Tools and/or Builders +that use the variable have been +included in the construction environment. + + + + + +In this appendix, we have +appended the initial $ +(dollar sign) to the beginning of each +variable name when it appears in the text, +but left off the dollar sign +in the left-hand column +where the name appears for each entry. + + + + + +&variables-gen; + + diff --git a/doc/user/variants.in b/doc/user/variants.in index 82d938b9..2bdc3941 100644 --- a/doc/user/variants.in +++ b/doc/user/variants.in @@ -49,7 +49,8 @@ is pretty smart about rebuilding things when you change options. - The &BuildDir; function now gives us everything + The &build_dir; keyword argument of + the &SConscript; function provides everything we need to show how easy it is to create variant builds using &SCons;. Suppose, for example, that we want to @@ -79,11 +80,6 @@ is pretty smart about rebuilding things when you change options. Export('env') env.SConscript('src/SConscript', build_dir='build/$PLATFORM') - - # - #BuildDir("#build/$PLATFORM", 'src') - #SConscript("build/$PLATFORM/hello/SConscript") - #SConscript("build/$PLATFORM/world/SConscript") @@ -125,7 +121,7 @@ is pretty smart about rebuilding things when you change options. - scons -Q OS=linux + scons -Q OS=linux @@ -135,7 +131,7 @@ is pretty smart about rebuilding things when you change options. - scons -Q OS=windows + scons -Q OS=windows diff --git a/doc/user/variants.sgml b/doc/user/variants.sgml index 0ef7d1f4..57d96e02 100644 --- a/doc/user/variants.sgml +++ b/doc/user/variants.sgml @@ -49,7 +49,8 @@ is pretty smart about rebuilding things when you change options. - The &BuildDir; function now gives us everything + The &build_dir; keyword argument of + the &SConscript; function provides everything we need to show how easy it is to create variant builds using &SCons;. Suppose, for example, that we want to @@ -78,11 +79,6 @@ is pretty smart about rebuilding things when you change options. Export('env') env.SConscript('src/SConscript', build_dir='build/$PLATFORM') - - # - #BuildDir("#build/$PLATFORM", 'src') - #SConscript("build/$PLATFORM/hello/SConscript") - #SConscript("build/$PLATFORM/world/SConscript") @@ -132,7 +128,7 @@ is pretty smart about rebuilding things when you change options. - scons -Q + scons -Q --> diff --git a/src/CHANGES.txt b/src/CHANGES.txt index 2dbb6bff..3acb1cce 100644 --- a/src/CHANGES.txt +++ b/src/CHANGES.txt @@ -15,6 +15,8 @@ RELEASE 0.97 - XXX - Fix Java parsing to avoid erroneously identifying a new array of class instances as an anonymous inner class. + - Fix a typo in the man page description of PathIsDirCreate. + From Chad Austin: - Allow Help() to be called multiple times, appending to the help @@ -207,6 +209,14 @@ RELEASE 0.97 - XXX a source_scanner keyword argument to Command() that can be set to DirScanner to get this behavior. + - Documentation changes: Explain that $CXXFLAGS contains $CCFLAGS + by default. Fix a bad target_factory example in the man page. + Add appendices to the User's Guide to cover the available Tools, + Builders and construction variables. Comment out the build of + the old Python 10 paper, which doesn't build on all systems and + is old enough at this point that it probably isn't worth the + effort to make it do so. + From Wayne Lee: - Avoid "maximum recursion limit" errors when removing $(-$) pairs @@ -294,6 +304,9 @@ RELEASE 0.97 - XXX - Supply a better error message when a construction variable expansion has an unknown attribute. + - Documentation changes: Update the man page to describe use of + filenames or Nodes in $LIBS. + From Chris Pawling: - Have the linkloc tool use $MSVS_VERSION to select the Microsoft @@ -419,6 +432,11 @@ RELEASE 0.97 - XXX - Add a PathAccept validator to the list of new canned PathOption validators. + From Jeff Squyres: + + - Documentation changes: Use $CPPDEFINES instead of $CCFLAGS in man + page examples. + From Levi Stephen: - Allow $JARCHDIR to be expanded to other construction variables. diff --git a/src/engine/MANIFEST-xml.in b/src/engine/MANIFEST-xml.in new file mode 100644 index 00000000..d8082c70 --- /dev/null +++ b/src/engine/MANIFEST-xml.in @@ -0,0 +1,86 @@ +SCons/Action.xml +SCons/Defaults.xml +SCons/Environment.xml +SCons/Platform/__init__.xml +SCons/Platform/posix.xml +SCons/Platform/win32.xml +SCons/Tool/386asm.xml +SCons/Tool/aixcc.xml +SCons/Tool/aixc++.xml +SCons/Tool/aixf77.xml +SCons/Tool/aixlink.xml +SCons/Tool/applelink.xml +SCons/Tool/ar.xml +SCons/Tool/as.xml +SCons/Tool/bcc32.xml +SCons/Tool/BitKeeper.xml +SCons/Tool/cc.xml +SCons/Tool/cvf.xml +SCons/Tool/CVS.xml +SCons/Tool/c++.xml +SCons/Tool/default.xml +SCons/Tool/dmd.xml +SCons/Tool/dvipdf.xml +SCons/Tool/dvips.xml +SCons/Tool/f77.xml +SCons/Tool/f90.xml +SCons/Tool/f95.xml +SCons/Tool/fortran.xml +SCons/Tool/g77.xml +SCons/Tool/gas.xml +SCons/Tool/gcc.xml +SCons/Tool/gnulink.xml +SCons/Tool/gs.xml +SCons/Tool/g++.xml +SCons/Tool/hpcc.xml +SCons/Tool/hpc++.xml +SCons/Tool/hplink.xml +SCons/Tool/icc.xml +SCons/Tool/icl.xml +SCons/Tool/ifl.xml +SCons/Tool/ifort.xml +SCons/Tool/ilink32.xml +SCons/Tool/ilink.xml +SCons/Tool/__init__.xml +SCons/Tool/intelc.xml +SCons/Tool/jar.xml +SCons/Tool/javac.xml +SCons/Tool/javah.xml +SCons/Tool/latex.xml +SCons/Tool/lex.xml +SCons/Tool/linkloc.xml +SCons/Tool/link.xml +SCons/Tool/m4.xml +SCons/Tool/masm.xml +SCons/Tool/midl.xml +SCons/Tool/mingw.xml +SCons/Tool/mslib.xml +SCons/Tool/mslink.xml +SCons/Tool/msvc.xml +SCons/Tool/msvs.xml +SCons/Tool/mwcc.xml +SCons/Tool/mwld.xml +SCons/Tool/nasm.xml +SCons/Tool/pdflatex.xml +SCons/Tool/pdftex.xml +SCons/Tool/Perforce.xml +SCons/Tool/qt.xml +SCons/Tool/RCS.xml +SCons/Tool/rmic.xml +SCons/Tool/rpcgen.xml +SCons/Tool/SCCS.xml +SCons/Tool/sgiar.xml +SCons/Tool/sgicc.xml +SCons/Tool/sgic++.xml +SCons/Tool/sgilink.xml +SCons/Tool/Subversion.xml +SCons/Tool/sunar.xml +SCons/Tool/suncc.xml +SCons/Tool/sunc++.xml +SCons/Tool/sunlink.xml +SCons/Tool/swig.xml +SCons/Tool/tar.xml +SCons/Tool/tex.xml +SCons/Tool/tlib.xml +SCons/Tool/yacc.xml +SCons/Tool/zip.xml diff --git a/src/engine/SCons/Action.xml b/src/engine/SCons/Action.xml new file mode 100644 index 00000000..c2253184 --- /dev/null +++ b/src/engine/SCons/Action.xml @@ -0,0 +1,67 @@ + + + +A Python function used to print the command lines as they are executed +(assuming command printing is not disabled by the + +or + +options or their equivalents). +The function should take four arguments: +s, +the command being executed (a string), +target, +the target being built (file node, list, or string name(s)), +source, +the source(s) used (file node, list, or string name(s)), and +env, +the environment being used. + +The function must do the printing itself. The default implementation, +used if this variable is not set or is None, is: + +def print_cmd_line(s, target, source, env): + sys.stdout.write(s + "\n") + + +Here's an example of a more interesting function: + + +def print_cmd_line(s, target, source, env): + sys.stdout.write("Building %s -> %s...\n" % + (' and '.join([str(x) for x in source]), + ' and '.join([str(x) for x in target]))) +env=Environment(PRINT_CMD_LINE_FUNC=print_cmd_line) +env.Program('foo', 'foo.c') + + +This just prints "Building targetname from sourcename..." instead +of the actual commands. +Such a function could also log the actual commands to a log file, +for example. + + + + + +A command interpreter function that will be called to execute command line +strings. The function must expect the following arguments: + + +def spawn(shell, escape, cmd, args, env): + + +sh +is a string naming the shell program to use. +escape +is a function that can be called to escape shell special characters in +the command line. +cmd +is the path to the command to be executed. +args +is the arguments to the command. +env +is a dictionary of the environment variables +in which the command should be executed. + + diff --git a/src/engine/SCons/Defaults.py b/src/engine/SCons/Defaults.py index 8ade7923..44d10fa5 100644 --- a/src/engine/SCons/Defaults.py +++ b/src/engine/SCons/Defaults.py @@ -121,10 +121,6 @@ LinkAction = SCons.Action.Action("$LINKCOM", "$LINKCOMSTR") ShLinkAction = SCons.Action.Action("$SHLINKCOM", "$SHLINKCOMSTR") LdModuleLinkAction = SCons.Action.Action("$LDMODULECOM", "$LDMODULECOMSTR") -ArAction = SCons.Action.Action("$ARCOM", "$ARCOMSTR") - -LexAction = SCons.Action.Action("$LEXCOM", "$LEXCOMSTR") -YaccAction = SCons.Action.Action("$YACCCOM", "$YACCCOMSTR") def DVI(): """Common function to generate a DVI file Builder.""" diff --git a/src/engine/SCons/Defaults.xml b/src/engine/SCons/Defaults.xml new file mode 100644 index 00000000..8d90ce29 --- /dev/null +++ b/src/engine/SCons/Defaults.xml @@ -0,0 +1,471 @@ + + + +Builds a .dvi file +from a .tex, +.ltx or .latex input file. +If the source file suffix is .tex, +&scons; +will examine the contents of the file; +if the string +\documentclass +or +\documentstyle +is found, the file is assumed to be a LaTeX file and +the target is built by invoking the &cv-LATEXCOM; command line; +otherwise, the &cv-TEXCOM; command line is used. +If the file is a LaTeX file, +the +&b-DVI; +builder method will also examine the contents +of the +.aux +file +and invoke the &cv-BIBTEX; command line +if the string +bibdata +is found, +and will examine the contents +.log +file and re-run the &cv-LATEXCOM; command +if the log file says it is necessary. + +The suffix .dvi +(hard-coded within TeX itself) +is automatically added to the target +if it is not already present. +Examples: + + +# builds from aaa.tex +env.DVI(target = 'aaa.dvi', source = 'aaa.tex') +# builds bbb.dvi +env.DVI(target = 'bbb', source = 'bbb.ltx') +# builds from ccc.latex +env.DVI(target = 'ccc.dvi', source = 'ccc.latex') + + + + + + +Builds a .pdf file +from a .dvi input file +(or, by extension, a .tex, +.ltx, +or +.latex input file). +The suffix specified by the &cv-PDFSUFFIX; construction variable +(.pdf by default) +is added automatically to the target +if it is not already present. Example: + + +# builds from aaa.tex +env.PDF(target = 'aaa.pdf', source = 'aaa.tex') +# builds bbb.pdf from bbb.dvi +env.PDF(target = 'bbb', source = 'bbb.dvi') + + + + + + +A function used to produce variables like &cv-_CPPINCFLAGS;. It takes +four or five +arguments: a prefix to concatenate onto each element, a list of +elements, a suffix to concatenate onto each element, an environment +for variable interpolation, and an optional function that will be +called to transform the list before concatenation. + + +env['_CPPINCFLAGS'] = '$( ${_concat(INCPREFIX, CPPPATH, INCSUFFIX, __env__, RDirs)} $)', + + + + + + +A platform independent specification of C preprocessor definitions. +The definitions will be added to command lines +through the automatically-generated +&cv-_CPPDEFFLAGS; construction variable (see below), +which is constructed according to +the type of value of &cv-CPPDEFINES;: + +If &cv-CPPDEFINES; is a string, +the values of the +&cv-CPPDEFPREFIX; and &cv-CPPDEFSUFFIX; +construction variables +will be added to the beginning and end. + + +# Will add -Dxyz to POSIX compiler command lines, +# and /Dxyz to Microsoft Visual C++ command lines. +env = Environment(CPPDEFINES='xyz') + + +If &cv-CPPDEFINES; is a list, +the values of the +&cv-CPPDEFPREFIX; and &cv-CPPDEFSUFFIX; +construction variables +will be appended to the beginning and end +of each element in the list. +If any element is a list or tuple, +then the first item is the name being +defined and the second item is its value: + + +# Will add -DB=2 -DA to POSIX compiler command lines, +# and /DB=2 /DA to Microsoft Visual C++ command lines. +env = Environment(CPPDEFINES=[('B', 2), 'A']) + + +If &cv-CPPDEFINES; is a dictionary, +the values of the +&cv-CPPDEFPREFIX; and &cv-CPPDEFSUFFIX; +construction variables +will be appended to the beginning and end +of each item from the dictionary. +The key of each dictionary item +is a name being defined +to the dictionary item's corresponding value; +if the value is +None, +then the name is defined without an explicit value. +Note that the resulting flags are sorted by keyword +to ensure that the order of the options on the +command line is consistent each time +&scons; is run. + + +# Will add -DA -DB=2 to POSIX compiler command lines, +# and /DA /DB=2 to Microsoft Visual C++ command lines. +env = Environment(CPPDEFINES={'B':2, 'A':None}) + + + + + + +An automatically-generated construction variable +containing the C preprocessor command-line options +to define values. +The value of &cv-_CPPDEFFLAGS; is created +by appending &cv-CPPDEFPREFIX; and &cv-CPPDEFSUFFIX; +to the beginning and end +of each directory in &cv-CPPDEFINES;. + + + + + +The prefix used to specify preprocessor definitions +on the C compiler command line. +This will be appended to the beginning of each definition +in the &cv-CPPDEFINES; construction variable +when the &cv-_CPPDEFFLAGS; variable is automatically generated. + + + + + +The suffix used to specify preprocessor definitions +on the C compiler command line. +This will be appended to the end of each definition +in the &cv-CPPDEFINES; construction variable +when the &cv-_CPPDEFFLAGS; variable is automatically generated. + + + + + +An automatically-generated construction variable +containing the C preprocessor command-line options +for specifying directories to be searched for include files. +The value of &cv-_CPPINCFLAGS; is created +by appending &cv-INCPREFIX; and &cv-INCSUFFIX; +to the beginning and end +of each directory in &cv-CPPPATH;. + + + + + +The list of directories that the C preprocessor will search for include +directories. The C/C++ implicit dependency scanner will search these +directories for include files. Don't explicitly put include directory +arguments in CCFLAGS or CXXFLAGS because the result will be non-portable +and the directories will not be searched by the dependency scanner. Note: +directory names in CPPPATH will be looked-up relative to the SConscript +directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: + + +env = Environment(CPPPATH='#/include') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +include = Dir('include') +env = Environment(CPPPATH=include) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_CPPINCFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-INCPREFIX; and &cv-INCSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-CPPPATH;. +Any command lines you define that need +the CPPPATH directory list should +include &cv-_CPPINCFLAGS;: + + +env = Environment(CCCOM="my_compiler $_CPPINCFLAGS -c -o $TARGET $SOURCE") + + + + + + +The list of suffixes of files that will be scanned +for imported D package files. +The default list is: + + +['.d'] + + + + + + +The list of suffixes of files that will be scanned +for IDL implicit dependencies +(#include or import lines). +The default list is: + + +[".idl", ".IDL"] + + + + + + +The prefix used to specify an include directory on the C compiler command +line. +This will be appended to the beginning of each directory +in the &cv-CPPPATH; and &cv-FORTRANPATH; construction variables +when the &cv-_CPPINCFLAGS; and &cv-_FORTRANINCFLAGS; +variables are automatically generated. + + + + + +The suffix used to specify an include directory on the C compiler command +line. +This will be appended to the end of each directory +in the &cv-CPPPATH; and &cv-FORTRANPATH; construction variables +when the &cv-_CPPINCFLAGS; and &cv-_FORTRANINCFLAGS; +variables are automatically generated. + + + + + +A function to be called to install a file into a +destination file name. +The default function copies the file into the destination +(and sets the destination file's mode and permission bits +to match the source file's). +The function takes the following arguments: + + +def install(dest, source, env): + + +dest +is the path name of the destination file. +source +is the path name of the source file. +env +is the construction environment +(a dictionary of construction values) +in force for this file installation. + + + + + +An automatically-generated construction variable +containing the linker command-line options +for specifying directories to be searched for library. +The value of &cv-_LIBDIRFLAGS; is created +by appending &cv-LIBDIRPREFIX; and &cv-LIBDIRSUFFIX; +to the beginning and end +of each directory in &cv-LIBPATH;. + + + + + +The prefix used to specify a library directory on the linker command line. +This will be appended to the beginning of each directory +in the &cv-LIBPATH; construction variable +when the &cv-_LIBDIRFLAGS; variable is automatically generated. + + + + + +The suffix used to specify a library directory on the linker command line. +This will be appended to the end of each directory +in the &cv-LIBPATH; construction variable +when the &cv-_LIBDIRFLAGS; variable is automatically generated. + + + + + +An automatically-generated construction variable +containing the linker command-line options +for specifying libraries to be linked with the resulting target. +The value of &cv-_LIBFLAGS; is created +by appending &cv-LIBLINKPREFIX; and &cv-LIBLINKSUFFIX; +to the beginning and end +of each filename in &cv-LIBS;. + + + + + +The prefix used to specify a library to link on the linker command line. +This will be appended to the beginning of each library +in the &cv-LIBS; construction variable +when the &cv-_LIBFLAGS; variable is automatically generated. + + + + + +The suffix used to specify a library to link on the linker command line. +This will be appended to the end of each library +in the &cv-LIBS; construction variable +when the &cv-_LIBFLAGS; variable is automatically generated. + + + + + +The list of directories that will be searched for libraries. +The implicit dependency scanner will search these +directories for include files. Don't explicitly put include directory +arguments in &cv-LINKFLAGS; or &cv-SHLINKFLAGS; +because the result will be non-portable +and the directories will not be searched by the dependency scanner. Note: +directory names in LIBPATH will be looked-up relative to the SConscript +directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: + + +env = Environment(LIBPATH='#/libs') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +libs = Dir('libs') +env = Environment(LIBPATH=libs) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_LIBDIRFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-LIBDIRPREFIX; and &cv-LIBDIRSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-LIBPATH;. +Any command lines you define that need +the LIBPATH directory list should +include &cv-_LIBDIRFLAGS;: + + +env = Environment(LINKCOM="my_linker $_LIBDIRFLAGS $_LIBFLAGS -o $TARGET $SOURCE") + + + + + + +A list of one or more libraries +that will be linked with +any executable programs +created by this environment. + +The library list will be added to command lines +through the automatically-generated +&cv-_LIBFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-LIBLINKPREFIX; and &cv-LIBLINKSUFFIX; +construction variables +to the beginning and end +of each filename in &cv-LIBS;. +Any command lines you define that need +the LIBS library list should +include &cv-_LIBFLAGS;: + + +env = Environment(LINKCOM="my_linker $_LIBDIRFLAGS $_LIBFLAGS -o $TARGET $SOURCE") + + +If you add a +File +object to the +&cv-LIBS; +list, the name of that file will be added to +&cv-_LIBFLAGS;, +and thus the link line, as is, without +&cv-LIBLINKPREFIX; +or +&cv-LIBLINKSUFFIX;. +For example: + + +env.Append(LIBS=File('/tmp/mylib.so')) + + +In all cases, scons will add dependencies from the executable program to +all the libraries in this list. + + + + + +The prefix used for PDF file names. + + + + + +The suffix used for PDF file names. + + diff --git a/src/engine/SCons/Environment.xml b/src/engine/SCons/Environment.xml new file mode 100644 index 00000000..d41cdafb --- /dev/null +++ b/src/engine/SCons/Environment.xml @@ -0,0 +1,157 @@ + + + +A dictionary mapping the names of the builders +available through this environment +to underlying Builder objects. +Builders named +Alias, CFile, CXXFile, DVI, Library, Object, PDF, PostScript, and Program +are available by default. +If you initialize this variable when an +Environment is created: + + +env = Environment(BUILDERS = {'NewBuilder' : foo}) + + +the default Builders will no longer be available. +To use a new Builder object in addition to the default Builders, +add your new Builder object like this: + + +env = Environment() +env.Append(BUILDERS = {'NewBuilder' : foo}) + + +or this: + + +env = Environment() +env['BUILDERS]['NewBuilder'] = foo + + + + + + +A function that converts a file name into a Dir instance relative to the +target being built. + + + + + +A dictionary of environment variables +to use when invoking commands. When +&cv-ENV; is used in a command all list +values will be joined using the path separator and any other non-string +values will simply be coerced to a string. +Note that, by default, +&scons; +does +not +propagate the environment in force when you +execute +&scons; +to the commands used to build target files. +This is so that builds will be guaranteed +repeatable regardless of the environment +variables set at the time +&scons; +is invoked. + +If you want to propagate your +environment variables +to the commands executed +to build target files, +you must do so explicitly: + + +import os +env = Environment(ENV = os.environ) + + +Note that you can choose only to propagate +certain environment variables. +A common example is +the system +PATH +environment variable, +so that +&scons; +uses the same utilities +as the invoking shell (or other process): + + +import os +env = Environment(ENV = {'PATH' : os.environ['PATH']}) + + + + + + +A function that converts a file name into a File instance relative to the +target being built. + + + + + +A function that converts a file name into a list of Dir instances by +searching the repositories. + + + + + +A list of the available implicit dependency scanners. +New file scanners may be added by +appending to this list, +although the more flexible approach +is to associate scanners +with a specific Builder. +See the sections "Builder Objects" +and "Scanner Objects," +below, for more information. + + + + + +A reserved variable name +that may not be set or used in a construction environment. +(See "Variable Substitution," below.) + + + + + +A reserved variable name +that may not be set or used in a construction environment. +(See "Variable Substitution," below.) + + + + + +A reserved variable name +that may not be set or used in a construction environment. +(See "Variable Substitution," below.) + + + + + +A reserved variable name +that may not be set or used in a construction environment. +(See "Variable Substitution," below.) + + + + + +A list of the names of the Tool specifications +that are part of this construction environment. + + diff --git a/src/engine/SCons/Platform/__init__.xml b/src/engine/SCons/Platform/__init__.xml new file mode 100644 index 00000000..20ec83bd --- /dev/null +++ b/src/engine/SCons/Platform/__init__.xml @@ -0,0 +1,118 @@ + + + +A function that will be called to escape shell special characters in +command lines. The function should take one argument: the command line +string to escape; and should return the escaped command line. + + + + + +The prefix used for (static) library file names. +A default value is set for each platform +(posix, win32, os2, etc.), +but the value is overridden by individual tools +(ar, mslib, sgiar, sunar, tlib, etc.) +to reflect the names of the libraries they create. + + + + + +An array of legal prefixes for library file names. + + + + + +The suffix used for (static) library file names. +A default value is set for each platform +(posix, win32, os2, etc.), +but the value is overridden by individual tools +(ar, mslib, sgiar, sunar, tlib, etc.) +to reflect the names of the libraries they create. + + + + + +An array of legal suffixes for library file names. + + + + + +The prefix used for (static) object file names. + + + + + +The suffix used for (static) object file names. + + + + + +The name of the platform used to create the Environment. If no platform is +specified when the Environment is created, +&scons; +autodetects the platform. + + +env = Environment(tools = []) +if env['PLATFORM'] == 'cygwin': + Tool('mingw')(env) +else: + Tool('msvc')(env) + + + + + + +The prefix used for executable file names. + + + + + +The suffix used for executable file names. + + + + + +A string naming the shell program that will be passed to the +&cv-SPAWN; +function. +See the +&cv-SPAWN; +construction variable for more information. + + + + + +The prefix used for shared library file names. + + + + + +The suffix used for shared library file names. + + + + + +The prefix used for shared object file names. + + + + + +The suffix used for shared object file names. + + diff --git a/src/engine/SCons/Platform/posix.xml b/src/engine/SCons/Platform/posix.xml new file mode 100644 index 00000000..1a53c722 --- /dev/null +++ b/src/engine/SCons/Platform/posix.xml @@ -0,0 +1,45 @@ + + + +A list of paths to search for shared libraries when running programs. +Currently only used in the GNU linker (gnulink) and IRIX linker (sgilink). +Ignored on platforms and toolchains that don't support it. +Note that the paths added to RPATH +are not transformed by +&scons; +in any way: if you want an absolute +path, you must make it absolute yourself. + + + + + +An automatically-generated construction variable +containing the rpath flags to be used when linking +a program with shared libraries. +The value of &cv-_RPATH; is created +by appending &cv-RPATHPREFIX; and &cv-RPATHSUFFIX; +to the beginning and end +of each directory in &cv-RPATH;. + + + + + +The prefix used to specify a directory to be searched for +shared libraries when running programs. +This will be appended to the beginning of each directory +in the &cv-RPATH; construction variable +when the &cv-_RPATH; variable is automatically generated. + + + + + +The suffix used to specify a directory to be searched for +shared libraries when running programs. +This will be appended to the end of each directory +in the &cv-RPATH; construction variable +when the &cv-_RPATH; variable is automatically generated. + + diff --git a/src/engine/SCons/Platform/win32.xml b/src/engine/SCons/Platform/win32.xml new file mode 100644 index 00000000..c893f0c1 --- /dev/null +++ b/src/engine/SCons/Platform/win32.xml @@ -0,0 +1,9 @@ + + + +The maximum number of characters allowed on an external command line. +On Win32 systems, +link lines longer than this many characters +are linked via a temporary file name. + + diff --git a/src/engine/SCons/Tool/386asm.xml b/src/engine/SCons/Tool/386asm.xml new file mode 100644 index 00000000..2a9d9930 --- /dev/null +++ b/src/engine/SCons/Tool/386asm.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/BitKeeper.xml b/src/engine/SCons/Tool/BitKeeper.xml new file mode 100644 index 00000000..43841a02 --- /dev/null +++ b/src/engine/SCons/Tool/BitKeeper.xml @@ -0,0 +1,43 @@ + + + +XXX + + + + + +The BitKeeper executable. + + + + + +The command line for +fetching source files using BitKEeper. + + + + + +The string displayed when fetching +a source file using BitKeeper. +If this is not set, then &cv-BITKEEPERCOM; +(the command line) is displayed. + + + + + +The command (&cv-BITKEEPER;) and subcommand +for fetching source files using BitKeeper. + + + + + +Options that are passed to the BitKeeper +get +subcommand. + + diff --git a/src/engine/SCons/Tool/CVS.xml b/src/engine/SCons/Tool/CVS.xml new file mode 100644 index 00000000..9a072943 --- /dev/null +++ b/src/engine/SCons/Tool/CVS.xml @@ -0,0 +1,51 @@ + + + +XXX + + + + + +The CVS executable. + + + + + +Options that are passed to the CVS checkout subcommand. + + + + + +The command line used to +fetch source files from a CVS repository. + + + + + +The string displayed when fetching +a source file from a CVS repository. +If this is not set, then &cv-CVSCOM; +(the command line) is displayed. + + + + + +General options that are passed to CVS. +By default, this is set to +-d $CVSREPOSITORY +to specify from where the files must be fetched. + + + + + +The path to the CVS repository. +This is referenced in the default +&cv-CVSFLAGS; value. + + diff --git a/src/engine/SCons/Tool/Perforce.xml b/src/engine/SCons/Tool/Perforce.xml new file mode 100644 index 00000000..247330e8 --- /dev/null +++ b/src/engine/SCons/Tool/Perforce.xml @@ -0,0 +1,33 @@ + + + +XXX + + + + + +The Perforce executable. + + + + + +The command line used to +fetch source files from Perforce. + + + + + +The string displayed when +fetching a source file from Perforce. +If this is not set, then &cv-P4COM; (the command line) is displayed. + + + + + +General options that are passed to Perforce. + + diff --git a/src/engine/SCons/Tool/RCS.xml b/src/engine/SCons/Tool/RCS.xml new file mode 100644 index 00000000..40d972f3 --- /dev/null +++ b/src/engine/SCons/Tool/RCS.xml @@ -0,0 +1,46 @@ + + + +XXX + + + + + +The RCS executable. +Note that this variable is not actually used +for the command to fetch source files from RCS; +see the +&cv-RCS_CO; +construction variable, below. + + + + + +The RCS "checkout" executable, +used to fetch source files from RCS. + + + + + +The command line used to +fetch (checkout) source files from RCS. + + + + + +The string displayed when fetching +a source file from RCS. +If this is not set, then &cv-RCS_COCOM; +(the command line) is displayed. + + + + + +Options that are passed to the &cv-RCS_CO; command. + + diff --git a/src/engine/SCons/Tool/SCCS.xml b/src/engine/SCons/Tool/SCCS.xml new file mode 100644 index 00000000..08aa949d --- /dev/null +++ b/src/engine/SCons/Tool/SCCS.xml @@ -0,0 +1,43 @@ + + + +XXX + + + + + +The SCCS executable. + + + + + +The command line used to +fetch source files from SCCS. + + + + + +The string displayed when fetching +a source file from a CVS repository. +If this is not set, then &cv-SCCSCOM; +(the command line) is displayed. + + + + + +General options that are passed to SCCS. + + + + + +Options that are passed specifically to the SCCS "get" subcommand. +This can be set, for example, to + +to check out editable files from SCCS. + + diff --git a/src/engine/SCons/Tool/Subversion.xml b/src/engine/SCons/Tool/Subversion.xml new file mode 100644 index 00000000..e5560d1c --- /dev/null +++ b/src/engine/SCons/Tool/Subversion.xml @@ -0,0 +1,32 @@ + + + +XXX + + + + + + + + diff --git a/src/engine/SCons/Tool/__init__.py b/src/engine/SCons/Tool/__init__.py index 7ef2ea0c..7010e1c5 100644 --- a/src/engine/SCons/Tool/__init__.py +++ b/src/engine/SCons/Tool/__init__.py @@ -161,8 +161,8 @@ def createStaticLibBuilder(env): try: static_lib = env['BUILDERS']['StaticLibrary'] except KeyError: - import SCons.Defaults - static_lib = SCons.Builder.Builder(action = SCons.Defaults.ArAction, + ar_action = SCons.Action.Action("$ARCOM", "$ARCOMSTR") + static_lib = SCons.Builder.Builder(action = ar_action, emitter = '$LIBEMITTER', prefix = '$LIBPREFIX', suffix = '$LIBSUFFIX', diff --git a/src/engine/SCons/Tool/__init__.xml b/src/engine/SCons/Tool/__init__.xml new file mode 100644 index 00000000..86b830c1 --- /dev/null +++ b/src/engine/SCons/Tool/__init__.xml @@ -0,0 +1,324 @@ + + + +Builds a C source file given a lex (.l) +or yacc (.y) input file. +The suffix specified by the &cv-CFILESUFFIX; construction variable +(.c by default) +is automatically added to the target +if it is not already present. Example: + + +# builds foo.c +env.CFile(target = 'foo.c', source = 'foo.l') +# builds bar.c +env.CFile(target = 'bar', source = 'bar.y') + + + + + + +Builds a C++ source file given a lex (.ll) +or yacc (.yy) +input file. +The suffix specified by the &cv-CXXFILESUFFIX; construction variable +(.cc by default) +is automatically added to the target +if it is not already present. Example: + + +# builds foo.cc +env.CXXFile(target = 'foo.cc', source = 'foo.ll') +# builds bar.cc +env.CXXFile(target = 'bar', source = 'bar.yy') + + + + + + +A synonym for the +&b-StaticLibrary; +builder method. + + + + + +A synonym for the +&b-StaticObject; +builder method. + + + + + +Builds an executable given one or more object files +or C, C++, D, or Fortran source files. +If any C, C++, D or Fortran source files are specified, +then they will be automatically +compiled to object files using the +&b-Object; +builder method; +see that builder method's description for +a list of legal source file suffixes +and how they are interpreted. +The target executable file prefix +(specified by the &cv-PROGPREFIX; construction variable; nothing by default) +and suffix +(specified by the &cv-PROGSUFFIX; construction variable; +by default, .exe on Windows systems, +nothing on POSIX systems) +are automatically added to the target if not already present. +Example: + + +env.Program(target = 'foo', source = ['foo.o', 'bar.c', 'baz.f']) + + + + + + +Builds a shared library +(.so on a POSIX system, +.dll on WIN32) +given one or more object files +or C, C++, D or Fortran source files. +If any source files are given, +then they will be automatically +compiled to object files. +The static library prefix and suffix (if any) +are automatically added to the target. +The target library file prefix +(specified by the &cv-SHLIBPREFIX; construction variable; +by default, lib on POSIX systems, +nothing on Windows systems) +and suffix +(specified by the &cv-SHLIBSUFFIX; construction variable; +by default, .dll on Windows systems, +.so on POSIX systems) +are automatically added to the target if not already present. +Example: + + +env.SharedLibrary(target = 'bar', source = ['bar.c', 'foo.o']) + + +On WIN32 systems, the +&b-SharedLibrary; +builder method will always build an import +(.lib) library +in addition to the shared (.dll) library, +adding a .lib library with the same basename +if there is not already a .lib file explicitly +listed in the targets. + +Any object files listed in the +source +must have been built for a shared library +(that is, using the +&b-SharedObject; +builder method). +&scons; +will raise an error if there is any mismatch. + +On WIN32 systems, specifying +register=1 +will cause the .dll to be +registered after it is built using REGSVR32. +The command that is run +("regsvr32" by default) is determined by &cv-REGSVR; construction +variable, and the flags passed are determined by &cv-REGSVRFLAGS;. By +default, &cv-REGSVRFLAGS; includes the option, +to prevent dialogs from popping +up and requiring user attention when it is run. If you change +&cv-REGSVRFLAGS;, be sure to include the option. +For example, + + +env.SharedLibrary(target = 'bar', + source = ['bar.cxx', 'foo.obj'], + register=1) + + +will register bar.dll as a COM object +when it is done linking it. + + + + + +Builds an object file for +inclusion in a shared library. +Source files must have one of the same set of extensions +specified above for the +&b-StaticObject; +builder method. +On some platforms building a shared object requires additional +compiler option +(e.g. for gcc) +in addition to those needed to build a +normal (static) object, but on some platforms there is no difference between a +shared object and a normal (static) one. When there is a difference, SCons +will only allow shared objects to be linked into a shared library, and will +use a different suffix for shared objects. On platforms where there is no +difference, SCons will allow both normal (static) +and shared objects to be linked into a +shared library, and will use the same suffix for shared and normal +(static) objects. +The target object file prefix +(specified by the &cv-SHOBJPREFIX; construction variable; +by default, the same as &cv-OBJPREFIX;) +and suffix +(specified by the &cv-SHOBJSUFFIX; construction variable) +are automatically added to the target if not already present. +Examples: + + +env.SharedObject(target = 'ddd', source = 'ddd.c') +env.SharedObject(target = 'eee.o', source = 'eee.cpp') +env.SharedObject(target = 'fff.obj', source = 'fff.for') + + + + + + +Builds a static library given one or more object files +or C, C++, D or Fortran source files. +If any source files are given, +then they will be automatically +compiled to object files. +The static library prefix and suffix (if any) +are automatically added to the target. +The target library file prefix +(specified by the &cv-LIBPREFIX; construction variable; +by default, lib on POSIX systems, +nothing on Windows systems) +and suffix +(specified by the &cv-LIBSUFFIX; construction variable; +by default, .lib on Windows systems, +.a on POSIX systems) +are automatically added to the target if not already present. +Example: + + +env.StaticLibrary(target = 'bar', source = ['bar.c', 'foo.o']) + + +Any object files listed in the +source +must have been built for a static library +(that is, using the +&b-StaticObject; +builder method). +&scons; +will raise an error if there is any mismatch. + + + + + +Builds a static object file +from one or more C, C++, D, or Fortran source files. +Source files must have one of the following extensions: + + + .asm assembly language file + .ASM assembly language file + .c C file + .C WIN32: C file + POSIX: C++ file + .cc C++ file + .cpp C++ file + .cxx C++ file + .cxx C++ file + .c++ C++ file + .C++ C++ file + .d D file + .f Fortran file + .F WIN32: Fortran file + POSIX: Fortran file + C pre-processor + .for Fortran file + .FOR Fortran file + .fpp Fortran file + C pre-processor + .FPP Fortran file + C pre-processor + .s assembly language file + .S WIN32: assembly language file + POSIX: assembly language file + C pre-processor + .spp assembly language file + C pre-processor + .SPP assembly language file + C pre-processor + + +The target object file prefix +(specified by the &cv-OBJPREFIX; construction variable; nothing by default) +and suffix +(specified by the &cv-OBJSUFFIX; construction variable; +.obj on Windows systems, +.o on POSIX systems) +are automatically added to the target if not already present. +Examples: + + +env.StaticObject(target = 'aaa', source = 'aaa.c') +env.StaticObject(target = 'bbb.o', source = 'bbb.c++') +env.StaticObject(target = 'ccc.obj', source = 'ccc.f') + + + + + + +The version number of the C compiler. +This may or may not be set, +depending on the specific C compiler being used. + + + + + +The suffix for C source files. +This is used by the internal CFile builder +when generating C files from Lex (.l) or YACC (.y) input files. +The default suffix, of course, is +.c +(lower case). +On case-insensitive systems (like Win32), +SCons also treats +.C +(upper case) files +as C files. + + + + + +The version number of the C++ compiler. +This may or may not be set, +depending on the specific C++ compiler being used. + + + + + +The suffix for C++ source files. +This is used by the internal CXXFile builder +when generating C++ files from Lex (.ll) or YACC (.yy) input files. +The default suffix is +.cc. +SCons also treats files with the suffixes +.cpp, +.cxx, +.c++, +and +.C++ +as C++ files. +On case-sensitive systems (Linux, UNIX, and other POSIX-alikes), +SCons also treats +.C +(upper case) files +as C++ files. + + diff --git a/src/engine/SCons/Tool/aixc++.xml b/src/engine/SCons/Tool/aixc++.xml new file mode 100644 index 00000000..d3867794 --- /dev/null +++ b/src/engine/SCons/Tool/aixc++.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/aixcc.xml b/src/engine/SCons/Tool/aixcc.xml new file mode 100644 index 00000000..cb27adb2 --- /dev/null +++ b/src/engine/SCons/Tool/aixcc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/aixf77.xml b/src/engine/SCons/Tool/aixf77.xml new file mode 100644 index 00000000..7e7988c4 --- /dev/null +++ b/src/engine/SCons/Tool/aixf77.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/aixlink.xml b/src/engine/SCons/Tool/aixlink.xml new file mode 100644 index 00000000..378dcbfa --- /dev/null +++ b/src/engine/SCons/Tool/aixlink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/applelink.xml b/src/engine/SCons/Tool/applelink.xml new file mode 100644 index 00000000..d839be0d --- /dev/null +++ b/src/engine/SCons/Tool/applelink.xml @@ -0,0 +1,11 @@ + + + +On Mac OS X, +frameworks options to be added at +the end of a command +line building a loadable module. + + + + diff --git a/src/engine/SCons/Tool/ar.py b/src/engine/SCons/Tool/ar.py index ab232eeb..92cab59e 100644 --- a/src/engine/SCons/Tool/ar.py +++ b/src/engine/SCons/Tool/ar.py @@ -37,6 +37,7 @@ import SCons.Defaults import SCons.Tool import SCons.Util + def generate(env): """Add Builders and construction variables for ar to an Environment.""" SCons.Tool.createStaticLibBuilder(env) diff --git a/src/engine/SCons/Tool/ar.xml b/src/engine/SCons/Tool/ar.xml new file mode 100644 index 00000000..de3246f0 --- /dev/null +++ b/src/engine/SCons/Tool/ar.xml @@ -0,0 +1,48 @@ + + + +XXX + + + + + +The static library archiver. + + + + + +The command line used to generate a static library from object files. + + + + + +The string displayed when an object file +is generated from an assembly-language source file. +If this is not set, then &cv-ARCOM; (the command line) is displayed. + + +env = Environment(ARCOMSTR = "Archiving $TARGET") + + + + + + +General options passed to the static library archiver. + + + + + +The archive indexer. + + + + + +General options passed to the archive indexer. + + diff --git a/src/engine/SCons/Tool/as.xml b/src/engine/SCons/Tool/as.xml new file mode 100644 index 00000000..a9395dfd --- /dev/null +++ b/src/engine/SCons/Tool/as.xml @@ -0,0 +1,69 @@ + + + +XXX + + + + + +The assembler. + + + + + +The command line used to generate an object file +from an assembly-language source file. + + + + + +The string displayed when an object file +is generated from an assembly-language source file. +If this is not set, then &cv-ASCOM; (the command line) is displayed. + + +env = Environment(ASCOMSTR = "Assembling $TARGET") + + + + + + +General options passed to the assembler. + + + + + +The command line used to assemble an assembly-language +source file into an object file +after first running the file through the C preprocessor. +Any options specified in the &cv-ASFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when an object file +is generated from an assembly-language source file +after first running the file through the C preprocessor. +If this is not set, then &cv-ASPPCOM; (the command line) is displayed. + + +env = Environment(ASPPCOMSTR = "Assembling $TARGET") + + + + + + +General options when an assembling an assembly-language +source file into an object file +after first running the file through the C preprocessor. +The default is to use the value of &cv-ASFLAGS;. + + diff --git a/src/engine/SCons/Tool/bcc32.xml b/src/engine/SCons/Tool/bcc32.xml new file mode 100644 index 00000000..ded614c6 --- /dev/null +++ b/src/engine/SCons/Tool/bcc32.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/c++.xml b/src/engine/SCons/Tool/c++.xml new file mode 100644 index 00000000..eaa8e6c8 --- /dev/null +++ b/src/engine/SCons/Tool/c++.xml @@ -0,0 +1,76 @@ + + + +XXX + + + + + +The C++ compiler. + + + + + +The command line used to compile a C++ source file to an object file. +Any options specified in the &cv-CXXFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when a C++ source file +is compiled to a (static) object file. +If this is not set, then &cv-CXXCOM; (the command line) is displayed. + + +env = Environment(CXXCOMSTR = "Compiling static object $TARGET") + + + + + + +General options that are passed to the C++ compiler. +By default, this includes the value of &cv-CCFLAGS;, +so that setting &cv-CCFLAGS; affects both C and C++ compilation. +If you want to add C++-specific flags, +you must set or override the value of &cv-CXXFLAGS;. + + + + + +The C++ compiler used for generating shared-library objects. + + + + + +The command line used to compile a C++ source file +to a shared-library object file. +Any options specified in the &cv-SHCXXFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when a C++ source file +is compiled to a shared object file. +If this is not set, then &cv-SHCXXCOM; (the command line) is displayed. + + +env = Environment(SHCXXCOMSTR = "Compiling shared object $TARGET") + + + + + + +Options that are passed to the C++ compiler +to generate shared-library objects. + + diff --git a/src/engine/SCons/Tool/cc.xml b/src/engine/SCons/Tool/cc.xml new file mode 100644 index 00000000..fb688ade --- /dev/null +++ b/src/engine/SCons/Tool/cc.xml @@ -0,0 +1,111 @@ + + + +XXX + + + + + +The C compiler. + + + + + +The command line used to compile a C source file to a (static) object file. +Any options specified in the &cv-CCFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when a C source file +is compiled to a (static) object file. +If this is not set, then &cv-CCCOM; (the command line) is displayed. + + +env = Environment(CCCOMSTR = "Compiling static object $TARGET") + + + + + + +General options that are passed to the C compiler. + + + + + +User-specified C preprocessor options. +These will be included in any command that uses the C preprocessor, +including not just compilation of C and C++ source files +via the &cv-CCCOM;, &cv-SHCCCOM;, &cv-CXXCOM; and &cv-SHCXXCOM; command lines, +but also the &cv-FORTRANPPCOM;, &cv-SHFORTRANPPCOM;, +&cv-F77PPCOM; and &cv-SHF77PPCOM; command lines +used to compile a Fortran source file, +and the &cv-ASPPCOM; command line +used to assemble an assembly language source file, +after first running each file through the C preprocessor. +Note that this variable does +not +contain + +(or similar) include search path options +that scons generates automatically from &cv-CPPPATH;. +See &cv-link-_CPPINCFLAGS;, below, +for the variable that expands to those options. + + + + + +The list of suffixes of files that will be scanned +for C preprocessor implicit dependencies +(#include lines). +The default list is: + + +[".c", ".C", ".cxx", ".cpp", ".c++", ".cc", + ".h", ".H", ".hxx", ".hpp", ".hh", + ".F", ".fpp", ".FPP", + ".S", ".spp", ".SPP"] + + + + + + +The C compiler used for generating shared-library objects. + + + + + +The command line used to compile a C source file +to a shared-library object file. +Any options specified in the &cv-SHCCFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when a C source file +is compiled to a shared object file. +If this is not set, then &cv-SHCCCOM; (the command line) is displayed. + + +env = Environment(SHCCCOMSTR = "Compiling shared object $TARGET") + + + + + + +Options that are passed to the C compiler +to generate shared-library objects. + + diff --git a/src/engine/SCons/Tool/cvf.xml b/src/engine/SCons/Tool/cvf.xml new file mode 100644 index 00000000..bd848aed --- /dev/null +++ b/src/engine/SCons/Tool/cvf.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/default.xml b/src/engine/SCons/Tool/default.xml new file mode 100644 index 00000000..371e5bc3 --- /dev/null +++ b/src/engine/SCons/Tool/default.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/dmd.xml b/src/engine/SCons/Tool/dmd.xml new file mode 100644 index 00000000..99ca8d9a --- /dev/null +++ b/src/engine/SCons/Tool/dmd.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/dvipdf.xml b/src/engine/SCons/Tool/dvipdf.xml new file mode 100644 index 00000000..fbb49333 --- /dev/null +++ b/src/engine/SCons/Tool/dvipdf.xml @@ -0,0 +1,38 @@ + + + +XXX + + + + + +The TeX DVI file to PDF file converter. + + + + + +General options passed to the TeX DVI file to PDF file converter. + + + + + +The command line used to convert TeX DVI files into a PDF file. + + + + + +The string displayed when a TeX DVI file +is converted into a PDF file. +If this is not set, then &cv-DVIPDFCOM; (the command line) is displayed. + + + + + +A deprecated synonym for &cv-DVIPDFCOM;. + + diff --git a/src/engine/SCons/Tool/dvips.xml b/src/engine/SCons/Tool/dvips.xml new file mode 100644 index 00000000..c2904697 --- /dev/null +++ b/src/engine/SCons/Tool/dvips.xml @@ -0,0 +1,66 @@ + + + +XXX + + + + + +Builds a .ps file +from a .dvi input file +(or, by extension, a .tex, +.ltx, +or +.latex input file). +The suffix specified by the &cv-PSSUFFIX; construction variable +(.ps by default) +is added automatically to the target +if it is not already present. Example: + + +# builds from aaa.tex +env.PostScript(target = 'aaa.ps', source = 'aaa.tex') +# builds bbb.ps from bbb.dvi +env.PostScript(target = 'bbb', source = 'bbb.dvi') + + + + + + +The TeX DVI file to PostScript converter. + + + + + +General options passed to the TeX DVI file to PostScript converter. + + + + + +The command line used to convert TeX DVI files into a PostScript file. + + + + + +The string displayed when a TeX DVI file +is converted into a PostScript file. +If this is not set, then &cv-PSCOM; (the command line) is displayed. + + + + + +The prefix used for PostScript file names. + + + + + +The prefix used for PostScript file names. + + diff --git a/src/engine/SCons/Tool/f77.xml b/src/engine/SCons/Tool/f77.xml new file mode 100644 index 00000000..caf959fd --- /dev/null +++ b/src/engine/SCons/Tool/f77.xml @@ -0,0 +1,196 @@ + + + +XXX + + + + + +The Fortran 77 compiler. +You should normally set the &cv-FORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-F77; if you need to use a specific compiler +or compiler version for Fortran 77 files. + + + + + +The command line used to compile a Fortran 77 source file to an object file. +You only need to set &cv-F77COM; if you need to use a specific +command line for Fortran 77 files. +You should normally set the &cv-FORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 77 source file +is compiled to an object file. +If this is not set, then &cv-F77COM; or &cv-FORTRANCOM; +(the command line) is displayed. + + + + + +General user-specified options that are passed to the Fortran 77 compiler. +Note that this variable does +not +contain + +(or similar) include search path options +that scons generates automatically from &cv-F77PATH;. +See +&cv-_F77INCFLAGS; +below, +for the variable that expands to those options. +You only need to set &cv-F77FLAGS; if you need to define specific +user options for Fortran 77 files. +You should normally set the &cv-FORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +An automatically-generated construction variable +containing the Fortran 77 compiler command-line options +for specifying directories to be searched for include files. +The value of &cv-_F77INCFLAGS; is created +by appending &cv-INCPREFIX; and &cv-INCSUFFIX; +to the beginning and end +of each directory in &cv-F77PATH;. + + + + + +The list of directories that the Fortran 77 compiler will search for include +directories. The implicit dependency scanner will search these +directories for include files. Don't explicitly put include directory +arguments in &cv-F77FLAGS; because the result will be non-portable +and the directories will not be searched by the dependency scanner. Note: +directory names in &cv-F77PATH; will be looked-up relative to the SConscript +directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: +You only need to set &cv-F77PATH; if you need to define a specific +include path for Fortran 77 files. +You should normally set the &cv-FORTRANPATH; variable, +which specifies the include path +for the default Fortran compiler +for all Fortran versions. + + +env = Environment(F77PATH='#/include') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +include = Dir('include') +env = Environment(F77PATH=include) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_F77INCFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-INCPREFIX; and &cv-INCSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-F77PATH;. +Any command lines you define that need +the F77PATH directory list should +include &cv-_F77INCFLAGS;: + + +env = Environment(F77COM="my_compiler $_F77INCFLAGS -c -o $TARGET $SOURCE") + + + + + + +The command line used to compile a Fortran 77 source file to an object file +after first running the file through the C preprocessor. +Any options specified in the &cv-F77FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-F77PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 77 files. +You should normally set the &cv-FORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + + + + +The Fortran 77 compiler used for generating shared-library objects. +You should normally set the &cv-SHFORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-SHF77; if you need to use a specific compiler +or compiler version for Fortran 77 files. + + + + + +The command line used to compile a Fortran 77 source file +to a shared-library object file. +You only need to set &cv-SHF77COM; if you need to use a specific +command line for Fortran 77 files. +You should normally set the &cv-SHFORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 77 source file +is compiled to a shared-library object file. +If this is not set, then &cv-SHF77COM; or &cv-SHFORTRANCOM; +(the command line) is displayed. + + + + + +Options that are passed to the Fortran 77 compiler +to generated shared-library objects. +You only need to set &cv-SHF77FLAGS; if you need to define specific +user options for Fortran 77 files. +You should normally set the &cv-SHFORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +The command line used to compile a Fortran 77 source file to a +shared-library object file +after first running the file through the C preprocessor. +Any options specified in the &cv-SHF77FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-SHF77PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 77 files. +You should normally set the &cv-SHFORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + diff --git a/src/engine/SCons/Tool/f90.xml b/src/engine/SCons/Tool/f90.xml new file mode 100644 index 00000000..b2f08576 --- /dev/null +++ b/src/engine/SCons/Tool/f90.xml @@ -0,0 +1,196 @@ + + + +XXX + + + + + +The Fortran 90 compiler. +You should normally set the &cv-FORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-F90; if you need to use a specific compiler +or compiler version for Fortran 90 files. + + + + + +The command line used to compile a Fortran 90 source file to an object file. +You only need to set &cv-F90COM; if you need to use a specific +command line for Fortran 90 files. +You should normally set the &cv-FORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 90 source file +is compiled to an object file. +If this is not set, then &cv-F90COM; or &cv-FORTRANCOM; +(the command line) is displayed. + + + + + +General user-specified options that are passed to the Fortran 90 compiler. +Note that this variable does +not +contain + +(or similar) include search path options +that scons generates automatically from &cv-F90PATH;. +See +&cv-_F90INCFLAGS; +below, +for the variable that expands to those options. +You only need to set &cv-F90FLAGS; if you need to define specific +user options for Fortran 90 files. +You should normally set the &cv-FORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +An automatically-generated construction variable +containing the Fortran 90 compiler command-line options +for specifying directories to be searched for include files. +The value of &cv-_F90INCFLAGS; is created +by appending &cv-INCPREFIX; and &cv-INCSUFFIX; +to the beginning and end +of each directory in &cv-F90PATH;. + + + + + +The list of directories that the Fortran 90 compiler will search for include +directories. The implicit dependency scanner will search these +directories for include files. Don't explicitly put include directory +arguments in &cv-F90FLAGS; because the result will be non-portable +and the directories will not be searched by the dependency scanner. Note: +directory names in &cv-F90PATH; will be looked-up relative to the SConscript +directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: +You only need to set &cv-F90PATH; if you need to define a specific +include path for Fortran 90 files. +You should normally set the &cv-FORTRANPATH; variable, +which specifies the include path +for the default Fortran compiler +for all Fortran versions. + + +env = Environment(F90PATH='#/include') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +include = Dir('include') +env = Environment(F90PATH=include) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_F90INCFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-INCPREFIX; and &cv-INCSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-F90PATH;. +Any command lines you define that need +the F90PATH directory list should +include &cv-_F90INCFLAGS;: + + +env = Environment(F90COM="my_compiler $_F90INCFLAGS -c -o $TARGET $SOURCE") + + + + + + +The command line used to compile a Fortran 90 source file to an object file +after first running the file through the C preprocessor. +Any options specified in the &cv-F90FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-F90PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 90 files. +You should normally set the &cv-FORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + + + + +The Fortran 90 compiler used for generating shared-library objects. +You should normally set the &cv-SHFORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-SHF90; if you need to use a specific compiler +or compiler version for Fortran 90 files. + + + + + +The command line used to compile a Fortran 90 source file +to a shared-library object file. +You only need to set &cv-SHF90COM; if you need to use a specific +command line for Fortran 90 files. +You should normally set the &cv-SHFORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 90 source file +is compiled to a shared-library object file. +If this is not set, then &cv-SHF90COM; or &cv-SHFORTRANCOM; +(the command line) is displayed. + + + + + +Options that are passed to the Fortran 90 compiler +to generated shared-library objects. +You only need to set &cv-SHF90FLAGS; if you need to define specific +user options for Fortran 90 files. +You should normally set the &cv-SHFORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +The command line used to compile a Fortran 90 source file to a +shared-library object file +after first running the file through the C preprocessor. +Any options specified in the &cv-SHF90FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-SHF90PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 90 files. +You should normally set the &cv-SHFORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + diff --git a/src/engine/SCons/Tool/f95.xml b/src/engine/SCons/Tool/f95.xml new file mode 100644 index 00000000..df744222 --- /dev/null +++ b/src/engine/SCons/Tool/f95.xml @@ -0,0 +1,196 @@ + + + +XXX + + + + + +The Fortran 95 compiler. +You should normally set the &cv-FORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-F95; if you need to use a specific compiler +or compiler version for Fortran 95 files. + + + + + +The command line used to compile a Fortran 95 source file to an object file. +You only need to set &cv-F95COM; if you need to use a specific +command line for Fortran 95 files. +You should normally set the &cv-FORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 95 source file +is compiled to an object file. +If this is not set, then &cv-F95COM; or &cv-FORTRANCOM; +(the command line) is displayed. + + + + + +General user-specified options that are passed to the Fortran 95 compiler. +Note that this variable does +not +contain + +(or similar) include search path options +that scons generates automatically from &cv-F95PATH;. +See +&cv-_F95INCFLAGS; +below, +for the variable that expands to those options. +You only need to set &cv-F95FLAGS; if you need to define specific +user options for Fortran 95 files. +You should normally set the &cv-FORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +An automatically-generated construction variable +containing the Fortran 95 compiler command-line options +for specifying directories to be searched for include files. +The value of &cv-_F95INCFLAGS; is created +by appending &cv-INCPREFIX; and &cv-INCSUFFIX; +to the beginning and end +of each directory in &cv-F95PATH;. + + + + + +The list of directories that the Fortran 95 compiler will search for include +directories. The implicit dependency scanner will search these +directories for include files. Don't explicitly put include directory +arguments in &cv-F95FLAGS; because the result will be non-portable +and the directories will not be searched by the dependency scanner. Note: +directory names in &cv-F95PATH; will be looked-up relative to the SConscript +directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: +You only need to set &cv-F95PATH; if you need to define a specific +include path for Fortran 95 files. +You should normally set the &cv-FORTRANPATH; variable, +which specifies the include path +for the default Fortran compiler +for all Fortran versions. + + +env = Environment(F95PATH='#/include') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +include = Dir('include') +env = Environment(F95PATH=include) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_F95INCFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-INCPREFIX; and &cv-INCSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-F95PATH;. +Any command lines you define that need +the F95PATH directory list should +include &cv-_F95INCFLAGS;: + + +env = Environment(F95COM="my_compiler $_F95INCFLAGS -c -o $TARGET $SOURCE") + + + + + + +The command line used to compile a Fortran 95 source file to an object file +after first running the file through the C preprocessor. +Any options specified in the &cv-F95FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-F95PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 95 files. +You should normally set the &cv-FORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + + + + +The Fortran 95 compiler used for generating shared-library objects. +You should normally set the &cv-SHFORTRAN; variable, +which specifies the default Fortran compiler +for all Fortran versions. +You only need to set &cv-SHF95; if you need to use a specific compiler +or compiler version for Fortran 95 files. + + + + + +The command line used to compile a Fortran 95 source file +to a shared-library object file. +You only need to set &cv-SHF95COM; if you need to use a specific +command line for Fortran 95 files. +You should normally set the &cv-SHFORTRANCOM; variable, +which specifies the default command line +for all Fortran versions. + + + + + +The string displayed when a Fortran 95 source file +is compiled to a shared-library object file. +If this is not set, then &cv-SHF95COM; or &cv-SHFORTRANCOM; +(the command line) is displayed. + + + + + +Options that are passed to the Fortran 95 compiler +to generated shared-library objects. +You only need to set &cv-SHF95FLAGS; if you need to define specific +user options for Fortran 95 files. +You should normally set the &cv-SHFORTRANFLAGS; variable, +which specifies the user-specified options +passed to the default Fortran compiler +for all Fortran versions. + + + + + +The command line used to compile a Fortran 95 source file to a +shared-library object file +after first running the file through the C preprocessor. +Any options specified in the &cv-SHF95FLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. +You only need to set &cv-SHF95PPCOM; if you need to use a specific +C-preprocessor command line for Fortran 95 files. +You should normally set the &cv-SHFORTRANPPCOM; variable, +which specifies the default C-preprocessor command line +for all Fortran versions. + + diff --git a/src/engine/SCons/Tool/fortran.xml b/src/engine/SCons/Tool/fortran.xml new file mode 100644 index 00000000..4282f302 --- /dev/null +++ b/src/engine/SCons/Tool/fortran.xml @@ -0,0 +1,240 @@ + + + +XXX + + + + + +The default Fortran compiler +for all versions of Fortran. + + + + + +The command line used to compile a Fortran source file to an object file. +By default, any options specified +in the &cv-FORTRANFLAGS;, &cv-CPPFLAGS;, &cv-_CPPDEFFLAGS;, +&cv-_FORTRANMODFLAG;, and &cv-_FORTRANINCFLAGS; construction variables +are included on this command line. + + + + + +The string displayed when a Fortran source file +is compiled to an object file. +If this is not set, then &cv-FORTRANCOM; +(the command line) is displayed. + + + + + +General user-specified options that are passed to the Fortran compiler. +Note that this variable does +not +contain + +(or similar) include or module search path options +that scons generates automatically from &cv-FORTRANPATH;. +See +&cv-_FORTRANINCFLAGS; and &cv-_FORTRANMODFLAG;, +below, +for the variables that expand those options. + + + + + +An automatically-generated construction variable +containing the Fortran compiler command-line options +for specifying directories to be searched for include +files and module files. +The value of &cv-_FORTRANINCFLAGS; is created +by prepending/appending &cv-INCPREFIX; and &cv-INCSUFFIX; +to the beginning and end +of each directory in &cv-FORTRANPATH;. + + + + + +Directory location where the Fortran compiler should place +any module files it generates. This variable is empty, by default. Some +Fortran compilers will internally append this directory in the search path +for module files, as well + + + + + +The prefix used to specify a module directory on the Fortran compiler command +line. +This will be appended to the beginning of the directory +in the &cv-FORTRANMODDIR; construction variables +when the &cv-_FORTRANMODFLAG; variables is automatically generated. + + + + + +The suffix used to specify a module directory on the Fortran compiler command +line. +This will be appended to the beginning of the directory +in the &cv-FORTRANMODDIR; construction variables +when the &cv-_FORTRANMODFLAG; variables is automatically generated. + + + + + +An automatically-generated construction variable +containing the Fortran compiler command-line option +for specifying the directory location where the Fortran +compiler should place any module files that happen to get +generated during compilation. +The value of &cv-_FORTRANMODFLAG; is created +by prepending/appending &cv-FORTRANMODDIRPREFIX; and &cv-FORTRANMODDIRSUFFIX; +to the beginning and end of the directory in &cv-FORTRANMODDIR;. + + + + + +The module file prefix used by the Fortran compiler. SCons assumes that +the Fortran compiler follows the quasi-standard naming convention for +module files of +module_name.mod. +As a result, this variable is left empty, by default. For situations in +which the compiler does not necessarily follow the normal convention, +the user may use this variable. Its value will be appended to every +module file name as scons attempts to resolve dependencies. + + + + + +The module file suffix used by the Fortran compiler. SCons assumes that +the Fortran compiler follows the quasi-standard naming convention for +module files of +module_name.mod. +As a result, this variable is set to ".mod", by default. For situations +in which the compiler does not necessarily follow the normal convention, +the user may use this variable. Its value will be appended to every +module file name as scons attempts to resolve dependencies. + + + + + +The list of directories that the Fortran compiler will search for +include files and (for some compilers) module files. The Fortran implicit +dependency scanner will search these directories for include files (but +not module files since they are autogenerated and, as such, may not +actually exist at the time the scan takes place). Don't explicitly put +include directory arguments in FORTRANFLAGS because the result will be +non-portable and the directories will not be searched by the dependency +scanner. Note: directory names in FORTRANPATH will be looked-up relative +to the SConscript directory when they are used in a command. To force +&scons; +to look-up a directory relative to the root of the source tree use #: + + +env = Environment(FORTRANPATH='#/include') + + +The directory look-up can also be forced using the +&Dir;() +function: + + +include = Dir('include') +env = Environment(FORTRANPATH=include) + + +The directory list will be added to command lines +through the automatically-generated +&cv-_FORTRANINCFLAGS; +construction variable, +which is constructed by +appending the values of the +&cv-INCPREFIX; and &cv-INCSUFFIX; +construction variables +to the beginning and end +of each directory in &cv-FORTRANPATH;. +Any command lines you define that need +the FORTRANPATH directory list should +include &cv-_FORTRANINCFLAGS;: + + +env = Environment(FORTRANCOM="my_compiler $_FORTRANINCFLAGS -c -o $TARGET $SOURCE") + + + + + + +The command line used to compile a Fortran source file to an object file +after first running the file through the C preprocessor. +By default, any options specified in the &cv-FORTRANFLAGS;, &cv-CPPFLAGS;, +_CPPDEFFLAGS, &cv-_FORTRANMODFLAG;, and &cv-_FORTRANINCFLAGS; +construction variables are included on this command line. + + + + + +The list of suffixes of files that will be scanned +for Fortran implicit dependencies +(INCLUDE lines and USE statements). +The default list is: + + +[".f", ".F", ".for", ".FOR", ".ftn", ".FTN", ".fpp", ".FPP", +".f77", ".F77", ".f90", ".F90", ".f95", ".F95"] + + + + + + +The default Fortran compiler used for generating shared-library objects. + + + + + +The command line used to compile a Fortran source file +to a shared-library object file. + + + + + +The string displayed when a Fortran source file +is compiled to a shared-library object file. +If this is not set, then &cv-SHFORTRANCOM; +(the command line) is displayed. + + + + + +Options that are passed to the Fortran compiler +to generate shared-library objects. + + + + + +The command line used to compile a Fortran source file to a +shared-library object file +after first running the file through the C preprocessor. +Any options specified +in the &cv-SHFORTRANFLAGS; and &cv-CPPFLAGS; construction variables +are included on this command line. + + diff --git a/src/engine/SCons/Tool/g++.xml b/src/engine/SCons/Tool/g++.xml new file mode 100644 index 00000000..b6fb5b07 --- /dev/null +++ b/src/engine/SCons/Tool/g++.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/g77.xml b/src/engine/SCons/Tool/g77.xml new file mode 100644 index 00000000..94f415a2 --- /dev/null +++ b/src/engine/SCons/Tool/g77.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/gas.xml b/src/engine/SCons/Tool/gas.xml new file mode 100644 index 00000000..29179e2b --- /dev/null +++ b/src/engine/SCons/Tool/gas.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/gcc.xml b/src/engine/SCons/Tool/gcc.xml new file mode 100644 index 00000000..51dac073 --- /dev/null +++ b/src/engine/SCons/Tool/gcc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/gnulink.xml b/src/engine/SCons/Tool/gnulink.xml new file mode 100644 index 00000000..d7c1a426 --- /dev/null +++ b/src/engine/SCons/Tool/gnulink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/gs.xml b/src/engine/SCons/Tool/gs.xml new file mode 100644 index 00000000..377bfc34 --- /dev/null +++ b/src/engine/SCons/Tool/gs.xml @@ -0,0 +1,34 @@ + + + +XXX + + + + + +The Ghostscript program used to convert PostScript to PDF files. + + + + + +The Ghostscript command line used to convert PostScript to PDF files. + + + + + +The string displayed when +Ghostscript is used to convert +a PostScript file to a PDF file. +If this is not set, then &cv-GSCOM; (the command line) is displayed. + + + + + +General options passed to the Ghostscript program +when converting PostScript to PDF files. + + diff --git a/src/engine/SCons/Tool/hpc++.xml b/src/engine/SCons/Tool/hpc++.xml new file mode 100644 index 00000000..5c13718e --- /dev/null +++ b/src/engine/SCons/Tool/hpc++.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/hpcc.xml b/src/engine/SCons/Tool/hpcc.xml new file mode 100644 index 00000000..db2fccd6 --- /dev/null +++ b/src/engine/SCons/Tool/hpcc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/hplink.xml b/src/engine/SCons/Tool/hplink.xml new file mode 100644 index 00000000..71f5e225 --- /dev/null +++ b/src/engine/SCons/Tool/hplink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/icc.xml b/src/engine/SCons/Tool/icc.xml new file mode 100644 index 00000000..a6fdea2d --- /dev/null +++ b/src/engine/SCons/Tool/icc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/icl.xml b/src/engine/SCons/Tool/icl.xml new file mode 100644 index 00000000..be20912c --- /dev/null +++ b/src/engine/SCons/Tool/icl.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/ifl.xml b/src/engine/SCons/Tool/ifl.xml new file mode 100644 index 00000000..34dfecb5 --- /dev/null +++ b/src/engine/SCons/Tool/ifl.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/ifort.xml b/src/engine/SCons/Tool/ifort.xml new file mode 100644 index 00000000..2cb889bd --- /dev/null +++ b/src/engine/SCons/Tool/ifort.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/ilink.xml b/src/engine/SCons/Tool/ilink.xml new file mode 100644 index 00000000..4f868833 --- /dev/null +++ b/src/engine/SCons/Tool/ilink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/ilink32.xml b/src/engine/SCons/Tool/ilink32.xml new file mode 100644 index 00000000..0d62be49 --- /dev/null +++ b/src/engine/SCons/Tool/ilink32.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/intelc.xml b/src/engine/SCons/Tool/intelc.xml new file mode 100644 index 00000000..47cfbecb --- /dev/null +++ b/src/engine/SCons/Tool/intelc.xml @@ -0,0 +1,14 @@ + + + +XXX + + + + + +Set by the "intelc" Tool +to the major version number of the Intel C compiler +selected for use. + + diff --git a/src/engine/SCons/Tool/jar.xml b/src/engine/SCons/Tool/jar.xml new file mode 100644 index 00000000..b89468d9 --- /dev/null +++ b/src/engine/SCons/Tool/jar.xml @@ -0,0 +1,82 @@ + + + +XXX + + + + + +Builds a Java archive (.jar) file +from a source tree of .class files. +If the &cv-JARCHDIR; value is set, the +&jar; +command will change to the specified directory using the + +option. +If the contents any of the source files begin with the string +Manifest-Version, +the file is assumed to be a manifest +and is passed to the +&jar; +command with the + +option set. + + +env.Jar(target = 'foo.jar', source = 'classes') + + + + + + +The Java archive tool. + + + + + +The directory to which the Java archive tool should change +(using the + +option). + + + + + +The command line used to call the Java archive tool. + + + + + +The string displayed when the Java archive tool +is called +If this is not set, then &cv-JARCOM; (the command line) is displayed. + + +env = Environment(JARCOMSTR = "JARchiving $SOURCES into $TARGET") + + + + + + +General options passed to the Java archive tool. +By default this is set to + +to create the necessary +jar +file. + + + + + +The suffix for Java archives: +.jar +by default. + + diff --git a/src/engine/SCons/Tool/javac.xml b/src/engine/SCons/Tool/javac.xml new file mode 100644 index 00000000..9cd40b54 --- /dev/null +++ b/src/engine/SCons/Tool/javac.xml @@ -0,0 +1,109 @@ + + + +XXX + + + + + +Builds one or more Java class files +from one or more source trees of .java files. +The class files will be placed underneath +the specified target directory. +SCons will parse each source .java file +to find the classes +(including inner classes) +defined within that file, +and from that figure out the +target .class files that will be created. +SCons will also search each Java file +for the Java package name, +which it assumes can be found on a line +beginning with the string +package +in the first column; +the resulting .class files +will be placed in a directory reflecting +the specified package name. +For example, +the file +Foo.java +defining a single public +Foo +class and +containing a package name of +sub.dir +will generate a corresponding +sub/dir/Foo.class +class file. + +Example: + + +env.Java(target = 'classes', source = 'src') +env.Java(target = 'classes', source = ['src1', 'src2']) + + + + + + +The Java compiler. + + + + + +The command line used to compile a directory tree containing +Java source files to +corresponding Java class files. +Any options specified in the &cv-JAVACFLAGS; construction variable +are included on this command line. + + + + + +The string displayed when compiling +a directory tree of Java source files to +corresponding Java class files. +If this is not set, then &cv-JAVACCOM; (the command line) is displayed. + + +env = Environment(JAVACCOMSTR = "Compiling class files $TARGETS from $SOURCES") + + + + + + +General options that are passed to the Java compiler. + + + + + +The directory in which Java class files may be found. +This is stripped from the beginning of any Java .class +file names supplied to the +JavaH +builder. + + + + + +The suffix for Java class files; +.class +by default. + + + + + +The suffix for Java files; +.java +by default. + + diff --git a/src/engine/SCons/Tool/javah.xml b/src/engine/SCons/Tool/javah.xml new file mode 100644 index 00000000..76997840 --- /dev/null +++ b/src/engine/SCons/Tool/javah.xml @@ -0,0 +1,82 @@ + + + +XXX + + + + + +Builds C header and source files for +implementing Java native methods. +The target can be either a directory +in which the header files will be written, +or a header file name which +will contain all of the definitions. +The source can be either the names of .class files, +or the objects returned from the +&b-Java; +builder method. + +If the construction variable +&cv-JAVACLASSDIR; +is set, either in the environment +or in the call to the +&b-JavaH; +builder method itself, +then the value of the variable +will be stripped from the +beginning of any .class file names. + +Examples: + + +# builds java_native.h +classes = env.Java(target = 'classdir', source = 'src') +env.JavaH(target = 'java_native.h', source = classes) + +# builds include/package_foo.h and include/package_bar.h +env.JavaH(target = 'include', + source = ['package/foo.class', 'package/bar.class']) + +# builds export/foo.h and export/bar.h +env.JavaH(target = 'export', + source = ['classes/foo.class', 'classes/bar.class'], + JAVACLASSDIR = 'classes') + + + + + + +The Java generator for C header and stub files. + + + + + +The command line used to generate C header and stub files +from Java classes. +Any options specified in the &cv-JAVAHFLAGS; construction variable +are included on this command line. + + + + + +The string displayed when C header and stub files +are generated from Java classes. +If this is not set, then &cv-JAVAHCOM; (the command line) is displayed. + + +env = Environment(JAVAHCOMSTR = "Generating header/stub file(s) $TARGETS from $SOURCES") + + + + + + +General options passed to the C header and stub file generator +for Java classes. + + diff --git a/src/engine/SCons/Tool/latex.xml b/src/engine/SCons/Tool/latex.xml new file mode 100644 index 00000000..6a415f78 --- /dev/null +++ b/src/engine/SCons/Tool/latex.xml @@ -0,0 +1,36 @@ + + + +XXX + + + + + +The LaTeX structured formatter and typesetter. + + + + + +The command line used to call the LaTeX structured formatter and typesetter. + + + + + +The string displayed when calling +the LaTeX structured formatter and typesetter. +If this is not set, then &cv-LATEXCOM; (the command line) is displayed. + + +env = Environment(LATEXCOMSTR = "Building $TARGET from LaTeX input $SOURCES") + + + + + + +General options passed to the LaTeX structured formatter and typesetter. + + diff --git a/src/engine/SCons/Tool/lex.py b/src/engine/SCons/Tool/lex.py index 4a17faec..3331f6cc 100644 --- a/src/engine/SCons/Tool/lex.py +++ b/src/engine/SCons/Tool/lex.py @@ -33,17 +33,19 @@ selection method. __revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__" -import SCons.Defaults +import SCons.Action import SCons.Tool import SCons.Util +LexAction = SCons.Action.Action("$LEXCOM", "$LEXCOMSTR") + def generate(env): """Add Builders and construction variables for lex to an Environment.""" c_file, cxx_file = SCons.Tool.createCFileBuilders(env) - c_file.add_action('.l', SCons.Defaults.LexAction) - c_file.add_action('.lex', SCons.Defaults.LexAction) - cxx_file.add_action('.ll', SCons.Defaults.LexAction) + c_file.add_action('.l', LexAction) + c_file.add_action('.lex', LexAction) + cxx_file.add_action('.ll', LexAction) env['LEX'] = env.Detect('flex') or 'lex' env['LEXFLAGS'] = SCons.Util.CLVar('') diff --git a/src/engine/SCons/Tool/lex.xml b/src/engine/SCons/Tool/lex.xml new file mode 100644 index 00000000..3fb62e11 --- /dev/null +++ b/src/engine/SCons/Tool/lex.xml @@ -0,0 +1,37 @@ + + + +XXX + + + + + +The lexical analyzer generator. + + + + + +The command line used to call the lexical analyzer generator +to generate a source file. + + + + + +The string displayed when generating a source file +using the lexical analyzer generator. +If this is not set, then &cv-LEXCOM; (the command line) is displayed. + + +env = Environment(LEXCOMSTR = "Lex'ing $TARGET from $SOURCES") + + + + + + +General options passed to the lexical analyzer generator. + + diff --git a/src/engine/SCons/Tool/link.xml b/src/engine/SCons/Tool/link.xml new file mode 100644 index 00000000..420a5b70 --- /dev/null +++ b/src/engine/SCons/Tool/link.xml @@ -0,0 +1,146 @@ + + + +XXX + + + + + +The linker for building loadable modules. +By default, this is the same as &cv-SHLINK;. + + + + + +The command line for building loadable modules. +On Mac OS X, this uses the &cv-LDMODULE;, +&cv-LDMODULEFLAGS; and &cv-FRAMEWORKSFLAGS; variables. +On other systems, this is the same as &cv-SHLINK;. + + + + + +The string displayed when building loadable modules. +If this is not set, then &cv-LDMODULECOM; (the command line) is displayed. + + + + + +General user options passed to the linker for building loadable modules. + + + + + +The prefix used for loadable module file names. +On Mac OS X, this is null; +on other systems, this is +the same as &cv-SHLIBPREFIX;. + + + + + +The suffix used for loadable module file names. +On Mac OS X, this is null; +on other systems, this is +the same as $SHLIBSUFFIX. + + + + + +The linker. + + + + + +The command line used to link object files into an executable. + + + + + +The string displayed when object files +are linked into an executable. +If this is not set, then &cv-LINKCOM; (the command line) is displayed. + + +env = Environment(LINKCOMSTR = "Linking $TARGET") + + + + + + +General user options passed to the linker. +Note that this variable should +not +contain + +(or similar) options for linking with the libraries listed in &cv-LIBS;, +nor + +(or similar) library search path options +that scons generates automatically from &cv-LIBPATH;. +See +&cv-_LIBFLAGS; +above, +for the variable that expands to library-link options, +and +&cv-_LIBDIRFLAGS; +above, +for the variable that expands to library search path options. + + + + + +The linker for programs that use shared libraries. + + + + + +The command line used to link programs using shared libaries. + + + + + +The string displayed when programs using shared libraries are linked. +If this is not set, then &cv-SHLINKCOM; (the command line) is displayed. + + +env = Environment(SHLINKCOMSTR = "Linking shared $TARGET") + + + + + + +General user options passed to the linker for programs using shared libraries. +Note that this variable should +not +contain + +(or similar) options for linking with the libraries listed in &cv-LIBS;, +nor + +(or similar) include search path options +that scons generates automatically from &cv-LIBPATH;. +See +&cv-_LIBFLAGS; +above, +for the variable that expands to library-link options, +and +&cv-_LIBDIRFLAGS; +above, +for the variable that expands to library search path options. + + diff --git a/src/engine/SCons/Tool/linkloc.xml b/src/engine/SCons/Tool/linkloc.xml new file mode 100644 index 00000000..12a9d50e --- /dev/null +++ b/src/engine/SCons/Tool/linkloc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/m4.xml b/src/engine/SCons/Tool/m4.xml new file mode 100644 index 00000000..1f917703 --- /dev/null +++ b/src/engine/SCons/Tool/m4.xml @@ -0,0 +1,48 @@ + + + +XXX + + + + + +Builds an output file from an M4 input file. +This uses a default &cv-M4FLAGS; value of +, +which considers all warnings to be fatal +and stops on the first warning +when using the GNU version of m4. +Example: + + +env.M4(target = 'foo.c', source = 'foo.c.m4') + + + + + + +The M4 macro preprocessor. + + + + + +The command line used to pass files through the M4 macro preprocessor. + + + + + +The string displayed when +a file is passed through the M4 macro preprocessor. +If this is not set, then &cv-M4COM; (the command line) is displayed. + + + + + +General options passed to the M4 macro preprocessor. + + diff --git a/src/engine/SCons/Tool/masm.xml b/src/engine/SCons/Tool/masm.xml new file mode 100644 index 00000000..82c14cfd --- /dev/null +++ b/src/engine/SCons/Tool/masm.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/midl.xml b/src/engine/SCons/Tool/midl.xml new file mode 100644 index 00000000..4d5c7e0f --- /dev/null +++ b/src/engine/SCons/Tool/midl.xml @@ -0,0 +1,29 @@ + + + +XXX + + + + + +Builds a Windows type library (.tlb) +file from an input IDL file (.idl). +In addition, it will build the associated inteface stub and +proxy source files, +naming them according to the base name of the .idl file. +For example, + + +env.TypeLibrary(source="foo.idl") + + +Will create foo.tlb, +foo.h, +foo_i.c, +foo_p.c +and +foo_data.c +files. + + diff --git a/src/engine/SCons/Tool/mingw.xml b/src/engine/SCons/Tool/mingw.xml new file mode 100644 index 00000000..273a8612 --- /dev/null +++ b/src/engine/SCons/Tool/mingw.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/mslib.xml b/src/engine/SCons/Tool/mslib.xml new file mode 100644 index 00000000..7da4365e --- /dev/null +++ b/src/engine/SCons/Tool/mslib.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/mslink.xml b/src/engine/SCons/Tool/mslink.xml new file mode 100644 index 00000000..82249e7f --- /dev/null +++ b/src/engine/SCons/Tool/mslink.xml @@ -0,0 +1,105 @@ + + + +XXX + + + + + +When set to non-zero, +suppresses creation of a corresponding Win32 static import lib by the +SharedLibrary +builder when used with +MinGW, Microsoft Visual Studio or Metrowerks. +This also suppresses creation +of an export (.exp) file +when using Microsoft Visual Studio. + + + + + +The Microsoft Visual C++ PDB file that will store debugging information for +object files, shared libraries, and programs. This variable is ignored by +tools other than Microsoft Visual C++. +When this variable is +defined SCons will add options to the compiler and linker command line to +cause them to generate external debugging information, and will also set up the +dependencies for the PDB file. Example: + + +env['PDB'] = 'hello.pdb' + + + + + + +The program used on WIN32 systems +to register a newly-built DLL library +whenever the &b-SharedLibrary; builder +is passed a keyword argument of register=1. + + + + + +The command line used on WIN32 systems +to register a newly-built DLL library +whenever the &b-SharedLibrary; builder +is passed a keyword argument of register=1. + + + + + +The string displayed when registering a newly-built DLL file. +If this is not set, then &cv-REGSVRCOM; (the command line) is displayed. + + + + + +Flags passed to the DLL registration program +on WIN32 systems when a newly-built DLL library is registered. +By default, +this includes the +that prevents dialog boxes from popping up +and requiring user attention. + + + + + +When this is set to true, +a library build of a WIN32 shared library (.dll file) +will also build a corresponding .def file at the same time, +if a .def file is not already listed as a build target. +The default is 0 (do not build a .def file). + + + + + +The prefix used for WIN32 .def file names. + + + + + +The suffix used for WIN32 .def file names. + + + + + +XXX The prefix used for WIN32 .def file names. + + + + + +XXX The suffix used for WIN32 .def file names. + + diff --git a/src/engine/SCons/Tool/msvc.xml b/src/engine/SCons/Tool/msvc.xml new file mode 100644 index 00000000..426014b1 --- /dev/null +++ b/src/engine/SCons/Tool/msvc.xml @@ -0,0 +1,112 @@ + + + +XXX + + + + + +Builds a Microsoft Visual C++ precompiled header. +Calling this builder method +returns a list of two targets: the PCH as the first element, and the object +file as the second element. Normally the object file is ignored. +This builder method is only +provided when Microsoft Visual C++ is being used as the compiler. +The PCH builder method is generally used in +conjuction with the PCH construction variable to force object files to use +the precompiled header: + + +env['PCH'] = env.PCH('StdAfx.cpp')[0] + + + + + + +Builds a Microsoft Visual C++ resource file. +This builder method is only provided +when Microsoft Visual C++ or MinGW is being used as the compiler. The +.res +(or +.o +for MinGW) suffix is added to the target name if no other suffix is given. +The source +file is scanned for implicit dependencies as though it were a C file. Example: + + +env.RES('resource.rc') + + + + + + +The Microsoft Visual C++ precompiled header that will be used when compiling +object files. This variable is ignored by tools other than Microsoft Visual C++. +When this variable is +defined SCons will add options to the compiler command line to +cause it to use the precompiled header, and will also set up the +dependencies for the PCH file. Example: + + +env['PCH'] = 'StdAfx.pch' + + + + + + +The command line used by the +&b-PCH; +builder to generated a precompiled header. + + + + + +The string displayed when generating a precompiled header. +If this is not set, then &cv-PCHCOM; (the command line) is displayed. + + + + + +This variable specifies how much of a source file is precompiled. This +variable is ignored by tools other than Microsoft Visual C++, or when +the PCH variable is not being used. When this variable is define it +must be a string that is the name of the header that +is included at the end of the precompiled portion of the source files, or +the empty string if the "#pragma hrdstop" construct is being used: + + +env['PCHSTOP'] = 'StdAfx.h' + + + + + + +The resource compiler used by the RES builder. + + + + + +The command line used by the RES builder. + + + + + +The string displayed when invoking the resource compiler. +If this is not set, then &cv-RCCOM; (the command line) is displayed. + + + + + +The flags passed to the resource compiler by the RES builder. + + diff --git a/src/engine/SCons/Tool/msvs.xml b/src/engine/SCons/Tool/msvs.xml new file mode 100644 index 00000000..4103ce1e --- /dev/null +++ b/src/engine/SCons/Tool/msvs.xml @@ -0,0 +1,266 @@ + + + +XXX + + + + + +Builds Microsoft Visual Studio project files. +This builds a Visual Studio project file, based on the version of +Visual Studio that is configured (either the latest installed version, +or the version set by +&cv-MSVS_VERSION; +in the Environment constructor). +For VS 6, it will generate +.dsp +and +.dsw +files, for VS 7, it will +generate +.vcproj +and +.sln +files. + +It takes several lists of filenames to be placed into the project +file, currently these are limited to +srcs, +incs, +localincs, +resources, +and +misc. +These are pretty self explanatory, but it +should be noted that the srcs list +is NOT added to the &cv-SOURCES; +construction variable. This is because it represents a list of files +to be added to the project file, not the source used to build the +project file (in this case, the "source" is the &SConscript; file used +to call MSVSProject). + +In addition to these values (which are all optional, although not +specifying any of them results in an empty project file), the +following values must be specified: + +target: The name of the target +.dsp +or +.vcproj +file. The correct +suffix for the version of Visual Studio must be used, but the +&cv-MSVSPROJECTSUFFIX; +construction value +will be defined to the correct value (see example below). + +variant: The name of this particular variant. These are typically +things like "Debug" or "Release", but really can be anything you want. +Multiple calls to MSVSProject with different variants are allowed: all +variants will be added to the project file with their appropriate +build targets and sources. + +buildtarget: A list of SCons.Node.FS objects which is returned from +the command which builds the target. This is used to tell SCons what +to build when the 'build' button is pressed inside of the IDE. + +Example usage: + + +barsrcs = ['bar.cpp'], +barincs = ['bar.h'], +barlocalincs = ['StdAfx.h'] +barresources = ['bar.rc','resource.h'] +barmisc = ['bar_readme.txt'] + +dll = local.SharedLibrary(target = 'bar.dll', + source = barsrcs) + +local.MSVSProject(target = 'Bar' + env['MSVSPROJECTSUFFIX'], + srcs = barsrcs, + incs = barincs, + localincs = barlocalincs, + resources = barresources, + misc = barmisc, + buildtarget = dll, + variant = 'Release') + + + + + + +When the Microsoft Visual Studio tools are initialized, they set up +this dictionary with the following keys: + +VERSION +the version of MSVS being used (can be set via +MSVS_VERSION) + +VERSIONS +the available versions of MSVS installed + +VCINSTALLDIR +installed directory of Visual C++ + +VSINSTALLDIR +installed directory of Visual Studio + +FRAMEWORKDIR +installed directory of the .NET framework + +FRAMEWORKVERSIONS +list of installed versions of the .NET framework, sorted latest to oldest. + +FRAMEWORKVERSION +latest installed version of the .NET framework + +FRAMEWORKSDKDIR +installed location of the .NET SDK. + +PLATFORMSDKDIR +installed location of the Platform SDK. + +PLATFORMSDK_MODULES +dictionary of installed Platform SDK modules, +where the dictionary keys are keywords for the various modules, and +the values are 2-tuples where the first is the release date, and the +second is the version number. + +If a value isn't set, it wasn't available in the registry. + + + + + +Tells the MS Visual Studio tools to use minimal INCLUDE, LIB, and PATH settings, +instead of the settings from the IDE. + +For Visual Studio, SCons will (by default) automatically determine +where MSVS is installed, and use the LIB, INCLUDE, and PATH variables +set by the IDE. You can override this behavior by setting these +variables after Environment initialization, or by setting +MSVS_IGNORE_IDE_PATHS = 1 +in the Environment initialization. +Specifying this will not leave these unset, but will set them to a +minimal set of paths needed to run the tools successfully. + +For VS6, the mininimal set is: + + INCLUDE:'VSDir\VC98\ATL\include;VSDir\VC98\MFC\include;VSDir\VC98\include' + LIB:'VSDir\VC98\MFC\lib;VSDir\VC98\lib' + PATH:'VSDir\Common\MSDev98\bin;VSDir\VC98\bin' + +For VS7, it is: + + INCLUDE:'VSDir\Vc7\atlmfc\include;VSDir\Vc7\include' + LIB:'VSDir\Vc7\atlmfc\lib;VSDir\Vc7\lib' + PATH:'VSDir\Common7\Tools\bin;VSDir\Common7\Tools;VSDir\Vc7\bin' + + +Where 'VSDir' is the installed location of Visual Studio. + + + + + +Tells the MS Visual Studio tool(s) to use +the MFC directories in its default paths +for compiling and linking. +Under MSVS version 6, +setting +MSVS_USE_MFC_DIRS +to a non-zero value +adds the +ATL\include +and +MFC\include +directories to +the default +INCLUDE +external environment variable, +and adds the +MFC\lib +directory to +the default +LIB +external environment variable. +Under MSVS version 7, +setting +MSVS_USE_MFC_DIRS +to a non-zero value +adds the +atlmfc\include +directory to the default +INCLUDE +external environment variable, +and adds the +atlmfc\lib +directory to the default +LIB +external environment variable. +The current default value is +1 +which means these directories +are added to the paths by default. +This default value is likely to change +in a future release, +so users who want the ATL and MFC +values included in their paths +are encouraged to enable the +MSVS_USE_MFC_DIRS +value explicitly +to avoid future incompatibility. +This variable has no effect if the +INCLUDE +or +LIB +environment variables are set explictly. + + + + + +Sets the preferred version of MSVS to use. + +SCons will (by default) select the latest version of MSVS +installed on your machine. So, if you have version 6 and version 7 +(MSVS .NET) installed, it will prefer version 7. You can override this by +specifying the +MSVS_VERSION +variable in the Environment initialization, setting it to the +appropriate version ('6.0' or '7.0', for example). +If the given version isn't installed, tool initialization will fail. + + + + + +The action used to generate Microsoft Visual Studio +project and solution files. + + + + + +The suffix used for Microsoft Visual Studio project (DSP) files. +The default value is +.vcproj +when using Visual Studio version 7.x (.NET), +and +.dsp +when using earlier versions of Visual Studio. + + + + + +The suffix used for Microsoft Visual Studio solution (DSW) files. +The default value is +.sln +when using Visual Studio version 7.x (.NET), +and +.dsw +when using earlier versions of Visual Studio. + + diff --git a/src/engine/SCons/Tool/mwcc.xml b/src/engine/SCons/Tool/mwcc.xml new file mode 100644 index 00000000..83eaab3f --- /dev/null +++ b/src/engine/SCons/Tool/mwcc.xml @@ -0,0 +1,20 @@ + + + +XXX + + + + + +The version number of the MetroWerks CodeWarrior C compiler +to be used. + + + + + +A list of installed versions of the MetroWerks CodeWarrior C compiler +on this system. + + diff --git a/src/engine/SCons/Tool/mwld.xml b/src/engine/SCons/Tool/mwld.xml new file mode 100644 index 00000000..ade98488 --- /dev/null +++ b/src/engine/SCons/Tool/mwld.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/nasm.xml b/src/engine/SCons/Tool/nasm.xml new file mode 100644 index 00000000..328386e2 --- /dev/null +++ b/src/engine/SCons/Tool/nasm.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/pdflatex.xml b/src/engine/SCons/Tool/pdflatex.xml new file mode 100644 index 00000000..78780798 --- /dev/null +++ b/src/engine/SCons/Tool/pdflatex.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/pdftex.xml b/src/engine/SCons/Tool/pdftex.xml new file mode 100644 index 00000000..701a2809 --- /dev/null +++ b/src/engine/SCons/Tool/pdftex.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/qt.xml b/src/engine/SCons/Tool/qt.xml new file mode 100644 index 00000000..b5335b61 --- /dev/null +++ b/src/engine/SCons/Tool/qt.xml @@ -0,0 +1,274 @@ + + + +XXX + + + + + +Builds an output file from a moc input file. Moc input files are either +header files or cxx files. This builder is only available after using the +tool 'qt'. See the &cv-QTDIR; variable for more information. +Example: + + +env.Moc('foo.h') # generates moc_foo.cc +env.Moc('foo.cpp') # generates foo.moc + + + + + + +Builds a header file, an implementation file and a moc file from an ui file. +and returns the corresponding nodes in the above order. +This builder is only available after using the tool 'qt'. Note: you can +specify .ui files directly as source +files to the &b-Program;, +&b-Library; and &b-SharedLibrary; builders +without using this builder. Using this builder lets you override the standard +naming conventions (be careful: prefixes are always prepended to names of +built files; if you don't want prefixes, you may set them to ``). +See the &cv-QTDIR; variable for more information. +Example: + + +env.Uic('foo.ui') # -> ['foo.h', 'uic_foo.cc', 'moc_foo.cc'] +env.Uic(target = Split('include/foo.h gen/uicfoo.cc gen/mocfoo.cc'), + source = 'foo.ui') # -> ['include/foo.h', 'gen/uicfoo.cc', 'gen/mocfoo.cc'] + + + + + + +The qt tool tries to take this from os.environ. +It also initializes all QT_* +construction variables listed below. +(Note that all paths are constructed +with python's os.path.join() method, +but are listed here with the '/' separator +for easier reading.) +In addition, the construction environment +variables &cv-CPPPATH;, &cv-LIBPATH; and &cv-LIBS; may be modified +and the variables +PROGEMITTER, SHLIBEMITTER and LIBEMITTER +are modified. Because the build-performance is affected when using this tool, +you have to explicitly specify it at Environment creation: + + +Environment(tools=['default','qt']) + + +The qt tool supports the following operations: + +.B Automatic moc file generation from header files. +You do not have to specify moc files explicitly, the tool does it for you. +However, there are a few preconditions to do so: Your header file must have +the same filebase as your implementation file and must stay in the same +directory. It must have one of the suffixes .h, .hpp, .H, .hxx, .hh. You +can turn off automatic moc file generation by setting QT_AUTOSCAN to 0. +See also the corresponding builder method +.B Moc() + +.B Automatic moc file generation from cxx files. +As stated in the qt documentation, include the moc file at the end of +the cxx file. Note that you have to include the file, which is generated +by the transformation ${QT_MOCCXXPREFIX}basename${QT_MOCCXXSUFFIX}, by default +basename.moc. A warning is generated after building the moc file, if you +do not include the correct file. If you are using BuildDir, you may +need to specify duplicate=1. You can turn off automatic moc file generation +by setting QT_AUTOSCAN to 0. See also the corresponding builder method +.B Moc() + +.B Automatic handling of .ui files. +The implementation files generated from .ui files are handled much the same +as yacc or lex files. Each .ui file given as a source of Program, Library or +SharedLibrary will generate three files, the declaration file, the +implementation file and a moc file. Because there are also generated headers, +you may need to specify duplicate=1 in calls to BuildDir. See also the corresponding builder method +.B Uic() + + + + + +Turn off scanning for mocable files. Use the Moc Builder to explicitely +specify files to run moc on. + + + + + +The path where the qt binaries are installed. +The default value is '&cv-QTDIR;/bin'. + + + + + +The path where the qt header files are installed. +The default value is '&cv-QTDIR;/include'. +Note: If you set this variable to None, the tool won't change the &cv-CPPPATH; +construction variable. + + + + + +Prints lots of debugging information while scanning for moc files. + + + + + +Default value is 'qt'. You may want to set this to 'qt-mt'. Note: If you set +this variable to None, the tool won't change the &cv-LIBS; variable. + + + + + +The path where the qt libraries are installed. +The default value is '&cv-QTDIR;/lib'. +Note: If you set this variable to None, the tool won't change the &cv-LIBPATH; +construction variable. + + + + + +Default value is '&cv-QT_BINPATH;/bin/moc'. + + + + + +Default value is ''. Prefix for moc output files, when source is a cxx file. + + + + + +Default value is '.moc'. Suffix for moc output files, when source is a cxx +file. + + + + + +Default value is '-i'. These flags are passed to moc, when moccing a +cpp file. + + + + + +Command to generate a moc file from a cpp file. + + + + + +The string displayed when generating a moc file from a cpp file. +If this is not set, then &cv-QT_MOCFROMCXXCOM; (the command line) is displayed. + + + + + +Command to generate a moc file from a header. + + + + + +The string displayed when generating a moc file from a cpp file. +If this is not set, then &cv-QT_MOCFROMHCOM; (the command line) is displayed. + + + + + +Default value is ''. These flags are passed to moc, when moccing a header +file. + + + + + +Default value is 'moc_'. Prefix for moc output files, when source is a header. + + + + + +Default value is '&cv-CXXFILESUFFIX;'. Suffix for moc output files, when source is +a header. + + + + + +Default value is '&cv-QT_BINPATH;/uic'. + + + + + +Command to generate header files from .ui files. + + + + + +The string displayed when generating header files from .ui files. +If this is not set, then &cv-QT_UICCOM; (the command line) is displayed. + + + + + +Default value is ''. These flags are passed to uic, when creating a a h +file from a .ui file. + + + + + +Default value is ''. Prefix for uic generated header files. + + + + + +Default value is '.h'. Suffix for uic generated header files. + + + + + +Default value is ''. These flags are passed to uic, when creating a cxx +file from a .ui file. + + + + + +Default value is 'uic_'. Prefix for uic generated implementation files. + + + + + +Default value is '&cv-CXXFILESUFFIX;'. Suffix for uic generated implementation +files. + + + + + +Default value is '.ui'. Suffix of designer input files. + + diff --git a/src/engine/SCons/Tool/rmic.xml b/src/engine/SCons/Tool/rmic.xml new file mode 100644 index 00000000..390aaafa --- /dev/null +++ b/src/engine/SCons/Tool/rmic.xml @@ -0,0 +1,79 @@ + + + +XXX + + + + + +Builds stub and skeleton class files +for remote objects +from Java .class files. +The target is a directory +relative to which the stub +and skeleton class files will be written. +The source can be the names of .class files, +or the objects return from the +&b-Java; +builder method. + +If the construction variable +&cv-JAVACLASSDIR; +is set, either in the environment +or in the call to the +&b-RMIC; +builder method itself, +then the value of the variable +will be stripped from the +beginning of any .class +file names. + + +classes = env.Java(target = 'classdir', source = 'src') +env.RMIC(target = 'outdir1', source = classes) + +env.RMIC(target = 'outdir2', + source = ['package/foo.class', 'package/bar.class']) + +env.RMIC(target = 'outdir3', + source = ['classes/foo.class', 'classes/bar.class'], + JAVACLASSDIR = 'classes') + + + + + + +The Java RMI stub compiler. + + + + + +The command line used to compile stub +and skeleton class files +from Java classes that contain RMI implementations. +Any options specified in the &cv-RMICFLAGS; construction variable +are included on this command line. + + + + + +The string displayed when compiling +stub and skeleton class files +from Java classes that contain RMI implementations. +If this is not set, then &cv-RMICCOM; (the command line) is displayed. + + +env = Environment(RMICCOMSTR = "Generating stub/skeleton class files $TARGETS from $SOURCES") + + + + + + +General options passed to the Java RMI stub compiler. + + diff --git a/src/engine/SCons/Tool/rpcgen.xml b/src/engine/SCons/Tool/rpcgen.xml new file mode 100644 index 00000000..9fdf13e5 --- /dev/null +++ b/src/engine/SCons/Tool/rpcgen.xml @@ -0,0 +1,122 @@ + + + +XXX + + + + + +Generates an RPC client stub (_clnt.c) file +from a specified RPC (.x) source file. +Because rpcgen only builds output files +in the local directory, +the command will be executed +in the source file's directory by default. + + +# Builds src/rpcif_clnt.c +env.RPCGenClient('src/rpcif.x') + + + + + + +Generates an RPC header (.h) file +from a specified RPC (.x) source file. +Because rpcgen only builds output files +in the local directory, +the command will be executed +in the source file's directory by default. + + +# Builds src/rpcif.h +env.RPCGenHeader('src/rpcif.x') + + + + + + +Generates an RPC server-skeleton (_svc.c) file +from a specified RPC (.x) source file. +Because rpcgen only builds output files +in the local directory, +the command will be executed +in the source file's directory by default. + + +# Builds src/rpcif_svc.c +env.RPCGenClient('src/rpcif.x') + + + + + + +Generates an RPC XDR routine (_xdr.c) file +from a specified RPC (.x) source file. +Because rpcgen only builds output files +in the local directory, +the command will be executed +in the source file's directory by default. + + +# Builds src/rpcif_xdr.c +env.RPCGenClient('src/rpcif.x') + + + + + + +The RPC protocol compiler. + + + + + +Options passed to the RPC protocol compiler +when generating client side stubs. +These are in addition to any flags specified in the +&cv-RPCGENFLAGS; +construction variable. + + + + + +General options passed to the RPC protocol compiler. + + + + + +Options passed to the RPC protocol compiler +when generating a header file. +These are in addition to any flags specified in the +&cv-RPCGENFLAGS; +construction variable. + + + + + +Options passed to the RPC protocol compiler +when generating server side stubs. +These are in addition to any flags specified in the +&cv-RPCGENFLAGS; +construction variable. + + + + + +Options passed to the RPC protocol compiler +when generating XDR routines. +These are in addition to any flags specified in the +&cv-RPCGENFLAGS; +construction variable. + + diff --git a/src/engine/SCons/Tool/sgiar.xml b/src/engine/SCons/Tool/sgiar.xml new file mode 100644 index 00000000..cd1d4140 --- /dev/null +++ b/src/engine/SCons/Tool/sgiar.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sgic++.xml b/src/engine/SCons/Tool/sgic++.xml new file mode 100644 index 00000000..318ebbf2 --- /dev/null +++ b/src/engine/SCons/Tool/sgic++.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sgicc.xml b/src/engine/SCons/Tool/sgicc.xml new file mode 100644 index 00000000..bd752ec0 --- /dev/null +++ b/src/engine/SCons/Tool/sgicc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sgilink.xml b/src/engine/SCons/Tool/sgilink.xml new file mode 100644 index 00000000..64eecb86 --- /dev/null +++ b/src/engine/SCons/Tool/sgilink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sunar.xml b/src/engine/SCons/Tool/sunar.xml new file mode 100644 index 00000000..b94443ca --- /dev/null +++ b/src/engine/SCons/Tool/sunar.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sunc++.xml b/src/engine/SCons/Tool/sunc++.xml new file mode 100644 index 00000000..fcd6b0ae --- /dev/null +++ b/src/engine/SCons/Tool/sunc++.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/suncc.xml b/src/engine/SCons/Tool/suncc.xml new file mode 100644 index 00000000..ab86294d --- /dev/null +++ b/src/engine/SCons/Tool/suncc.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/sunlink.xml b/src/engine/SCons/Tool/sunlink.xml new file mode 100644 index 00000000..127651ee --- /dev/null +++ b/src/engine/SCons/Tool/sunlink.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/swig.xml b/src/engine/SCons/Tool/swig.xml new file mode 100644 index 00000000..5c08412b --- /dev/null +++ b/src/engine/SCons/Tool/swig.xml @@ -0,0 +1,80 @@ + + + +XXX + + + + + +The scripting language wrapper and interface generator. + + + + + +The suffix that will be used for intermediate C +source files generated by +the scripting language wrapper and interface generator. +The default value is +_wrap&cv-CFILESUFFIX;. +By default, this value is used whenever the + +option is +not +specified as part of the +&cv-SWIGFLAGS; +construction variable. + + + + + +The command line used to call +the scripting language wrapper and interface generator. + + + + + +The string displayed when calling +the scripting language wrapper and interface generator. +If this is not set, then &cv-SWIGCOM; (the command line) is displayed. + + + + + +The suffix that will be used for intermediate C++ +source files generated by +the scripting language wrapper and interface generator. +The default value is +_wrap&cv-CFILESUFFIX;. +By default, this value is used whenever the +-c++ +option is specified as part of the +&cv-SWIGFLAGS; +construction variable. + + + + + +General options passed to +the scripting language wrapper and interface generator. +This is where you should set +, +, +, +or whatever other options you want to specify to SWIG. +If you set the + +option in this variable, +&scons; +will, by default, +generate a C++ intermediate source file +with the extension that is specified as the +&cv-CXXFILESUFFIX; +variable. + + diff --git a/src/engine/SCons/Tool/tar.xml b/src/engine/SCons/Tool/tar.xml new file mode 100644 index 00000000..c00910a6 --- /dev/null +++ b/src/engine/SCons/Tool/tar.xml @@ -0,0 +1,75 @@ + + + +XXX + + + + + +Builds a tar archive of the specified files +and/or directories. +Unlike most builder methods, +the +&b-Tar; +builder method may be called multiple times +for a given target; +each additional call +adds to the list of entries +that will be built into the archive. + + +env.Tar('src.tar', 'src') + +# Create the stuff.tar file. +env.Tar('stuff', ['subdir1', 'subdir2']) +# Also add "another" to the stuff.tar file. +env.Tar('stuff', 'another') + +# Set TARFLAGS to create a gzip-filtered archive. +env = Environment(TARFLAGS = '-c -z') +env.Tar('foo.tar.gz', 'foo') + +# Also set the suffix to .tgz. +env = Environment(TARFLAGS = '-c -z', + TARSUFFIX = '.tgz') +env.Tar('foo') + + + + + + +The tar archiver. + + + + + +The command line used to call the tar archiver. + + + + + +The string displayed when archiving files +using the tar archiver. +If this is not set, then &cv-TARCOM; (the command line) is displayed. + + +env = Environment(TARCOMSTR = "Archiving $TARGET") + + + + + + +General options passed to the tar archiver. + + + + + +The suffix used for tar file names. + + diff --git a/src/engine/SCons/Tool/tex.xml b/src/engine/SCons/Tool/tex.xml new file mode 100644 index 00000000..4f690413 --- /dev/null +++ b/src/engine/SCons/Tool/tex.xml @@ -0,0 +1,70 @@ + + + +XXX + + + + + +The bibliography generator for the TeX formatter and typesetter and the +LaTeX structured formatter and typesetter. + + + + + +The command line used to call the bibliography generator for the +TeX formatter and typesetter and the LaTeX structured formatter and +typesetter. + + + + + +The string displayed when generating a bibliography +for TeX or LaTeX. +If this is not set, then &cv-BIBTEXCOM; (the command line) is displayed. + + +env = Environment(BIBTEXCOMSTR = "Generating bibliography $TARGET") + + + + + + +General options passed to the bibliography generator for the TeX formatter +and typesetter and the LaTeX structured formatter and typesetter. + + + + + +The TeX formatter and typesetter. + + + + + +The command line used to call the TeX formatter and typesetter. + + + + + +The string displayed when calling +the TeX formatter and typesetter. +If this is not set, then &cv-TEXCOM; (the command line) is displayed. + + +env = Environment(TEXCOMSTR = "Building $TARGET from TeX input $SOURCES") + + + + + + +General options passed to the TeX formatter and typesetter. + + diff --git a/src/engine/SCons/Tool/tlib.xml b/src/engine/SCons/Tool/tlib.xml new file mode 100644 index 00000000..03515685 --- /dev/null +++ b/src/engine/SCons/Tool/tlib.xml @@ -0,0 +1,6 @@ + + + +XXX + + diff --git a/src/engine/SCons/Tool/yacc.py b/src/engine/SCons/Tool/yacc.py index 2c93b7c5..da88aa22 100644 --- a/src/engine/SCons/Tool/yacc.py +++ b/src/engine/SCons/Tool/yacc.py @@ -39,6 +39,8 @@ import SCons.Defaults import SCons.Tool import SCons.Util +YaccAction = SCons.Action.Action("$YACCCOM", "$YACCCOMSTR") + def _yaccEmitter(target, source, env, ysuf, hsuf): # If -d is specified on the command line, yacc will emit a .h # or .hpp file as well as a .c or .cpp file, depending on whether @@ -60,9 +62,9 @@ def generate(env): """Add Builders and construction variables for yacc to an Environment.""" c_file, cxx_file = SCons.Tool.createCFileBuilders(env) - c_file.add_action('.y', SCons.Defaults.YaccAction) - c_file.add_action('.yacc', SCons.Defaults.YaccAction) - cxx_file.add_action('.yy', SCons.Defaults.YaccAction) + c_file.add_action('.y', YaccAction) + c_file.add_action('.yacc', YaccAction) + cxx_file.add_action('.yy', YaccAction) c_file.add_emitter('.y', yEmitter) c_file.add_emitter('.yacc', yEmitter) cxx_file.add_emitter('.yy', yyEmitter) diff --git a/src/engine/SCons/Tool/yacc.xml b/src/engine/SCons/Tool/yacc.xml new file mode 100644 index 00000000..59735af3 --- /dev/null +++ b/src/engine/SCons/Tool/yacc.xml @@ -0,0 +1,42 @@ + + + +XXX + + + + + +The parser generator. + + + + + +The command line used to call the parser generator +to generate a source file. + + + + + +The string displayed when generating a source file +using the parser generator. +If this is not set, then &cv-YACCCOM; (the command line) is displayed. + + +env = Environment(YACCCOMSTR = "Yacc'ing $TARGET from $SOURCES") + + + + + + +General options passed to the parser generator. +If &cv-YACCFLAGS; contains a option, +SCons assumes that the call will also create a .h file +(if the yacc source file ends in a .y suffix) +or a .hpp file +(if the yacc source file ends in a .yy suffix) + + diff --git a/src/engine/SCons/Tool/zip.xml b/src/engine/SCons/Tool/zip.xml new file mode 100644 index 00000000..4e33c158 --- /dev/null +++ b/src/engine/SCons/Tool/zip.xml @@ -0,0 +1,83 @@ + + + +XXX + + + + + +Builds a zip archive of the specified files +and/or directories. +Unlike most builder methods, +the +&b-Zip; +builder method may be called multiple times +for a given target; +each additional call +adds to the list of entries +that will be built into the archive. + + +env.Zip('src.zip', 'src') + +# Create the stuff.zip file. +env.Zip('stuff', ['subdir1', 'subdir2']) +# Also add "another" to the stuff.tar file. +env.Zip('stuff', 'another') + + + + + + +The zip compression and file packaging utility. + + + + + +The command line used to call the zip utility, +or the internal Python function used to create a +zip archive. + + + + + +The string displayed when archiving files +using the zip utility. +If this is not set, then &cv-ZIPCOM; +(the command line or internal Python function) is displayed. + + +env = Environment(ZIPCOMSTR = "Zipping $TARGET") + + + + + + +The +compression +flag +from the Python +zipfile +module used by the internal Python function +to control whether the zip archive +is compressed or not. +The default value is +zipfile.ZIP_DEFLATED, +which creates a compressed zip archive. +This value has no effect when using Python 1.5.2 +or if the +zipfile +module is otherwise unavailable. + + + + + +General options passed to the zip utility. + + diff --git a/src/test_copyrights.py b/src/test_copyrights.py index 1671dbd0..44dc8fa9 100644 --- a/src/test_copyrights.py +++ b/src/test_copyrights.py @@ -93,6 +93,7 @@ src_remove_list = [ 'gentoo', 'config', 'MANIFEST.in', + 'MANIFEST-xml.in', ] # XXX Remove '*-stamp' when we get rid of those.