summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2004-02-28 07:25:33 (GMT)
committerSteven Knight <knight@baldmt.com>2004-02-28 07:25:33 (GMT)
commit5b26639256205eabd4e055040c7529b8ec868dcf (patch)
treeb96b3d5464cd6dd6ace593a33590834dc428e5eb
parentdfa9ded59f8641221328e2da7a06698a1b367ef1 (diff)
downloadSCons-5b26639256205eabd4e055040c7529b8ec868dcf.zip
SCons-5b26639256205eabd4e055040c7529b8ec868dcf.tar.gz
SCons-5b26639256205eabd4e055040c7529b8ec868dcf.tar.bz2
Document the dbm_module argument to SConsignFile().
-rw-r--r--doc/man/scons.121
-rw-r--r--test/Repository/variants.py12
2 files changed, 25 insertions, 8 deletions
diff --git a/doc/man/scons.1 b/doc/man/scons.1
index 0b0756a..46a5dda 100644
--- a/doc/man/scons.1
+++ b/doc/man/scons.1
@@ -3287,9 +3287,9 @@ SConscript('bar/SConscript') # will chdir to bar
'\"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
.TP
-.RI SConsignFile([ file ])
+.RI SConsignFile([ file , dbm_module ])
.TP
-.RI env.SConsignFile([ file ])
+.RI env.SConsignFile([ file , dbm_module ])
This tells
.B scons
to store all file signatures
@@ -3306,6 +3306,23 @@ is not an absolute path name,
the file is placed in the same directory as the top-level
.B SConstruct
file.
+
+The optional
+.I dbm_module
+argument can be used to specify
+which Python database module
+The default is to use
+.B dumbdbm
+if the specified
+.I file
+does not already exist,
+and to use
+.B anydbm
+to auto-detect the database format
+if the
+.I file
+already exists.
+
Examples:
.ES
diff --git a/test/Repository/variants.py b/test/Repository/variants.py
index 7e438ec..a0cc2af 100644
--- a/test/Repository/variants.py
+++ b/test/Repository/variants.py
@@ -78,13 +78,13 @@ opts = "-Y " + test.workpath('repository')
test.write(['repository', 'SConstruct'], r"""
OS = ARGUMENTS.get('OS', '')
build1_os = "#build1/" + OS
-default_ccflags = Environment()['CCFLAGS']
+default = Environment()
ccflags = {
'' : '',
'foo' : '-DFOO',
'bar' : '-DBAR',
}
-env1 = Environment(CCFLAGS = default_ccflags + ' ' + ccflags[OS],
+env1 = Environment(CCFLAGS = default.subst('$CCFLAGS %s' % ccflags[OS]),
CPPPATH = build1_os)
BuildDir(build1_os, 'src1')
SConscript(build1_os + '/SConscript', "env1")
@@ -101,8 +101,8 @@ env1.Program('xxx', ['aaa.c', 'bbb.c', 'main.c'])
test.write(['repository', 'build2', 'foo', 'SConscript'], r"""
BuildDir('src2', '#src2')
-default_ccflags = Environment()['CCFLAGS']
-env2 = Environment(CCFLAGS = default_ccflags + ' -DFOO',
+default = Environment()
+env2 = Environment(CCFLAGS = default.subst('$CCFLAGS -DFOO'),
CPPPATH = ['#src2/xxx', '#src2/include'])
SConscript('src2/xxx/SConscript', "env2")
@@ -111,8 +111,8 @@ SConscript('src2/xxx/SConscript', "env2")
test.write(['repository', 'build2', 'bar', 'SConscript'], r"""
BuildDir('src2', '#src2')
-default_ccflags = Environment()['CCFLAGS']
-env2 = Environment(CCFLAGS = default_ccflags + ' -DBAR',
+default = Environment()
+env2 = Environment(CCFLAGS = default.subst('$CCFLAGS -DBAR'),
CPPPATH = ['#src2/xxx', '#src2/include'])
SConscript('src2/xxx/SConscript', "env2")