summaryrefslogtreecommitdiff
path: root/src/engine/SCons/Action.py
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2015-06-21 07:55:31 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2015-06-21 07:55:31 +0200
commit39fa0bace059116d9a45e09fcd18691390b166bd (patch)
tree77f5abf2964bd92dc9e338654a4ffaaffc24d9ce /src/engine/SCons/Action.py
parentf9b0c331d8b9d03be91b56e324f59424af45302b (diff)
parentf7e5d2b46b03cc4bc09c38f7e0873378bb9c3b78 (diff)
Merge tag 'upstream/2.3.5'
Upstream version 2.3.5
Diffstat (limited to 'src/engine/SCons/Action.py')
-rw-r--r--src/engine/SCons/Action.py38
1 files changed, 18 insertions, 20 deletions
diff --git a/src/engine/SCons/Action.py b/src/engine/SCons/Action.py
index aec164f..ca3eddf 100644
--- a/src/engine/SCons/Action.py
+++ b/src/engine/SCons/Action.py
@@ -76,7 +76,7 @@ way for wrapping up the functions.
"""
-# Copyright (c) 2001 - 2014 The SCons Foundation
+# Copyright (c) 2001 - 2015 The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -97,9 +97,7 @@ way for wrapping up the functions.
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-__revision__ = "src/engine/SCons/Action.py 2014/09/27 12:51:43 garyo"
-
-import SCons.compat
+__revision__ = "src/engine/SCons/Action.py pchdll:3325:cd517fae59a4 2015/06/18 06:53:27 bdbaddog"
import dis
import os
@@ -112,7 +110,6 @@ import subprocess
import SCons.Debug
from SCons.Debug import logInstanceCreation
import SCons.Errors
-import SCons.Executor
import SCons.Util
import SCons.Subst
@@ -357,21 +354,6 @@ def _do_create_action(act, kw):
if isinstance(act, ActionBase):
return act
- if is_List(act):
- return CommandAction(act, **kw)
-
- if callable(act):
- try:
- gen = kw['generator']
- del kw['generator']
- except KeyError:
- gen = 0
- if gen:
- action_type = CommandGeneratorAction
- else:
- action_type = FunctionAction
- return action_type(act, kw)
-
if is_String(act):
var=SCons.Util.get_environment_var(act)
if var:
@@ -388,6 +370,22 @@ def _do_create_action(act, kw):
# The list of string commands may include a LazyAction, so we
# reprocess them via _do_create_list_action.
return _do_create_list_action(commands, kw)
+
+ if is_List(act):
+ return CommandAction(act, **kw)
+
+ if callable(act):
+ try:
+ gen = kw['generator']
+ del kw['generator']
+ except KeyError:
+ gen = 0
+ if gen:
+ action_type = CommandGeneratorAction
+ else:
+ action_type = FunctionAction
+ return action_type(act, kw)
+
# Catch a common error case with a nice message:
if isinstance(act, int) or isinstance(act, float):
raise TypeError("Don't know how to create an Action from a number (%s)"%act)