diff options
author | Steven Knight <knight@baldmt.com> | 2002-03-16 04:38:43 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2002-03-16 04:38:43 (GMT) |
commit | 0bfa6712f6b0ba40f7df806ec35a40fa056f026f (patch) | |
tree | 821e70780eb384562d222a2e8cbfe8f4e78a430d /doc | |
parent | d274d685b3fae62354a7c3deb0622e2edd81b0c7 (diff) | |
download | SCons-0bfa6712f6b0ba40f7df806ec35a40fa056f026f.zip SCons-0bfa6712f6b0ba40f7df806ec35a40fa056f026f.tar.gz SCons-0bfa6712f6b0ba40f7df806ec35a40fa056f026f.tar.bz2 |
Make FunctionAction arguments be Nodes, not strings. (Charles Crain)
Diffstat (limited to 'doc')
-rw-r--r-- | doc/man/scons.1 | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/doc/man/scons.1 b/doc/man/scons.1 index 6e4b72b..5d8a0a5 100644 --- a/doc/man/scons.1 +++ b/doc/man/scons.1 @@ -1285,9 +1285,9 @@ If the argument is a Python function, a function Action is returned. The Python function takes three keyword arguments, .B target -(the name of the target file), +(a Node object representing the target file), .B source -(the name of the source file) +(a Node object representing the source file) and .BR env (the construction environment @@ -1296,8 +1296,15 @@ The .B target and .B source -arguments may be lists of strings if there is +arguments may be lists of Node objects if there is more than one target file or source file. +The actual target and source file name(s) may +be retrieved from their Node objects +via the built-in Python str() function: +.ES +target_file_name = str(target) +source_file_names = map(lambda x: str(x), source) +.EE .IP The function should return .B 0 |