summaryrefslogtreecommitdiff
path: root/src/engine/SCons/SConf.py
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2016-04-10 18:15:03 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2016-04-10 18:15:03 +0200
commit301edd26f23e3d954dcea5cffc1ad13f969822ca (patch)
treeb0dd8f1b1da7c48da076ae45fc9529e748d082f0 /src/engine/SCons/SConf.py
parente20c9557371eacec533588d33b4bebd543ba178f (diff)
Imported Upstream version 2.5.0+repackupstream/2.5.0+repack
Diffstat (limited to 'src/engine/SCons/SConf.py')
-rw-r--r--src/engine/SCons/SConf.py31
1 files changed, 10 insertions, 21 deletions
diff --git a/src/engine/SCons/SConf.py b/src/engine/SCons/SConf.py
index 5a15856..fb1124b 100644
--- a/src/engine/SCons/SConf.py
+++ b/src/engine/SCons/SConf.py
@@ -12,7 +12,7 @@ libraries are installed, if some command line options are supported etc.
"""
#
-# Copyright (c) 2001 - 2015 The SCons Foundation
+# Copyright (c) 2001 - 2016 The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -34,7 +34,7 @@ libraries are installed, if some command line options are supported etc.
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/SConf.py rel_2.4.1:3453:73fefd3ea0b0 2015/11/09 03:25:05 bdbaddog"
+__revision__ = "src/engine/SCons/SConf.py rel_2.5.0:3543:937e55cd78f7 2016/04/09 11:29:54 bdbaddog"
import SCons.compat
@@ -254,14 +254,7 @@ class SConfBuildTask(SCons.Taskmaster.AlwaysTask):
else:
self.display('Caught exception while building "%s":\n' %
self.targets[0])
- try:
- excepthook = sys.excepthook
- except AttributeError:
- # Earlier versions of Python don't have sys.excepthook...
- def excepthook(type, value, tb):
- traceback.print_tb(tb)
- print type, value
- excepthook(*self.exc_info())
+ sys.excepthook(*self.exc_info())
return SCons.Taskmaster.Task.failed(self)
def collect_node_states(self):
@@ -355,8 +348,6 @@ class SConfBuildTask(SCons.Taskmaster.AlwaysTask):
raise SCons.Errors.ExplicitExit(self.targets[0],exc_value.code)
except Exception, e:
for t in self.targets:
- #binfo = t.get_binfo()
- #binfo.__class__ = SConfBuildInfo
binfo = SConfBuildInfo()
binfo.merge(t.get_binfo())
binfo.set_build_result(1, s.getvalue())
@@ -375,8 +366,6 @@ class SConfBuildTask(SCons.Taskmaster.AlwaysTask):
raise e
else:
for t in self.targets:
- #binfo = t.get_binfo()
- #binfo.__class__ = SConfBuildInfo
binfo = SConfBuildInfo()
binfo.merge(t.get_binfo())
binfo.set_build_result(0, s.getvalue())
@@ -399,16 +388,16 @@ class SConfBase(object):
tests, be sure to call the Finish() method, which returns the modified
environment.
Some words about caching: In most cases, it is not necessary to cache
- Test results explicitely. Instead, we use the scons dependency checking
+ Test results explicitly. Instead, we use the scons dependency checking
mechanism. For example, if one wants to compile a test program
(SConf.TryLink), the compiler is only called, if the program dependencies
have changed. However, if the program could not be compiled in a former
- SConf run, we need to explicitely cache this error.
+ SConf run, we need to explicitly cache this error.
"""
def __init__(self, env, custom_tests = {}, conf_dir='$CONFIGUREDIR',
log_file='$CONFIGURELOG', config_h = None, _depth = 0):
- """Constructor. Pass additional tests in the custom_tests-dictinary,
+ """Constructor. Pass additional tests in the custom_tests-dictionary,
e.g. custom_tests={'CheckPrivate':MyPrivateTest}, where MyPrivateTest
defines a custom test.
Note also the conf_dir and log_file arguments (you may want to
@@ -766,10 +755,10 @@ class CheckContext(object):
A typical test is just a callable with an instance of CheckContext as
first argument:
- def CheckCustom(context, ...)
- context.Message('Checking my weird test ... ')
- ret = myWeirdTestFunction(...)
- context.Result(ret)
+ def CheckCustom(context, ...):
+ context.Message('Checking my weird test ... ')
+ ret = myWeirdTestFunction(...)
+ context.Result(ret)
Often, myWeirdTestFunction will be one of
context.TryCompile/context.TryLink/context.TryRun. The results of