summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2004-09-03 17:08:11 (GMT)
committerSteven Knight <knight@baldmt.com>2004-09-03 17:08:11 (GMT)
commit94279041d8533f385e2b2b970ad48bd0307a6acc (patch)
treecaba165331b44caffa931a42293a382d560af2cd /src
parent24b9be093766cb2d566cd1220b15a94a193d2708 (diff)
downloadSCons-94279041d8533f385e2b2b970ad48bd0307a6acc.zip
SCons-94279041d8533f385e2b2b970ad48bd0307a6acc.tar.gz
SCons-94279041d8533f385e2b2b970ad48bd0307a6acc.tar.bz2
Remove all features deprecated in 0.93 or earlier.
Diffstat (limited to 'src')
-rw-r--r--src/CHANGES.txt6
-rw-r--r--src/RELEASE.txt7
-rw-r--r--src/engine/SCons/Options/OptionsTests.py23
-rw-r--r--src/engine/SCons/Options/__init__.py7
-rw-r--r--src/engine/SCons/Script/SConscript.py38
5 files changed, 13 insertions, 68 deletions
diff --git a/src/CHANGES.txt b/src/CHANGES.txt
index 3d32281..5fdc59d 100644
--- a/src/CHANGES.txt
+++ b/src/CHANGES.txt
@@ -20,6 +20,12 @@ RELEASE 0.97 - XXX
- When compiling with Microsoft Visual Studio, don't include the ATL and
MFC directories in the default INCLUDE and LIB environment variables.
+ - Remove the following deprecated features: the ParseConfig()
+ global function (deprecated in 0.93); the misspelled "validater"
+ keyword to the Options.Add() method (deprecated in 0.91); the
+ SetBuildSignatureType(), SetContentSignatureType(), SetJobs() and
+ GetJobs() global functions (deprecated in 0.14).
+
From Gary Oberbrunner:
- Add an Environment.Dump() method to print the contents of a
diff --git a/src/RELEASE.txt b/src/RELEASE.txt
index 73cc941..802be53 100644
--- a/src/RELEASE.txt
+++ b/src/RELEASE.txt
@@ -42,6 +42,13 @@ RELEASE 0.97 - XXX
env = Environment(MSVS_USE_MFC_DIRS = 1)
+ - The following deprecated global functions have been removed:
+ ParseConfig(), SetBuildSignatureType(), SetContentSignatureType(),
+ SetJobs() and GetJobs().
+
+ - The deprecated "validater" keyword to the Options.Add() method
+ has been removed.
+
Please note the following important changes since release 0.95:
- All Builder calls (both built-in like Program(), Library(),
diff --git a/src/engine/SCons/Options/OptionsTests.py b/src/engine/SCons/Options/OptionsTests.py
index ab931e2..afcb4d3 100644
--- a/src/engine/SCons/Options/OptionsTests.py
+++ b/src/engine/SCons/Options/OptionsTests.py
@@ -96,29 +96,6 @@ class OptionsTestCase(unittest.TestCase):
test_it('foo-bar')
test_it('foo.bar')
- save = {}
- save['warn'] = SCons.Warnings.warn
- save['DeprecatedWarning'] = SCons.Warnings.DeprecatedWarning
- def warn(type, message, save=save):
- save['type'] = type
- save['message'] = message
- SCons.Warnings.warn = warn
- SCons.Warnings.DeprecatedWarning = "xyzzy"
-
- try:
- opts.Add('MISSPELLED',
- 'test using the old validater keyword',
- "42",
- validater=check,
- converter=lambda x: int(x) + 12)
- finally:
- SCons.Warnings.DeprecatedWarning = save['DeprecatedWarning']
- SCons.Warnings.warn = save['warn']
- assert save['type'] == "xyzzy", save['type']
- assert string.find(save['message'], "keyword of the Options.Add() method", save['message'] != -1), save['message']
- o = opts.options[2]
- o.validator(o.key, o.converter(o.default), {})
-
def test_AddOptions(self):
"""Test adding a list of options to an Options object"""
opts = SCons.Options.Options()
diff --git a/src/engine/SCons/Options/__init__.py b/src/engine/SCons/Options/__init__.py
index 6236102..521171c 100644
--- a/src/engine/SCons/Options/__init__.py
+++ b/src/engine/SCons/Options/__init__.py
@@ -97,13 +97,6 @@ class Options:
not SCons.Util.is_valid_construction_var(key):
raise SCons.Errors.UserError, "Illegal Options.Add() key `%s'" % str(key)
- if kw.has_key('validater'):
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The 'validater' keyword of the Options.Add() method is deprecated\n" +\
- "and should be changed to 'validator'.")
- if validator is None:
- validator = kw['validater']
-
self._do_add(key, help, default, validator, converter)
diff --git a/src/engine/SCons/Script/SConscript.py b/src/engine/SCons/Script/SConscript.py
index c9a6108..fab0d82 100644
--- a/src/engine/SCons/Script/SConscript.py
+++ b/src/engine/SCons/Script/SConscript.py
@@ -529,37 +529,6 @@ SCons.Environment.Environment = SConsEnvironment
def Options(files=None, args=Arguments):
return SCons.Options.Options(files, args)
-def SetBuildSignatureType(type):
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The SetBuildSignatureType() function has been deprecated;\n" +\
- "\tuse the TargetSignatures() function instead.")
- SCons.Defaults.DefaultEnvironment().TargetSignatures(type)
-
-def SetContentSignatureType(type):
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The SetContentSignatureType() function has been deprecated;\n" +\
- "\tuse the SourceSignatures() function instead.")
- SCons.Defaults.DefaultEnvironment().SourceSignatures(type)
-
-def GetJobs():
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The GetJobs() function has been deprecated;\n" +\
- "\tuse GetOption('num_jobs') instead.")
-
- return GetOption('num_jobs')
-
-def SetJobs(num):
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The SetJobs() function has been deprecated;\n" +\
- "\tuse SetOption('num_jobs', num) instead.")
- SetOption('num_jobs', num)
-
-def ParseConfig(env, command, function=None):
- SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
- "The ParseConfig() function has been deprecated;\n" +\
- "\tuse the env.ParseConfig() method instead.")
- return env.ParseConfig(command, function)
-
#
_DefaultEnvironmentProxy = None
@@ -711,13 +680,6 @@ def BuildDefaultGlobals():
globals['CScan'] = SCons.Defaults.CScan
globals['DefaultEnvironment'] = SCons.Defaults.DefaultEnvironment
- # Deprecated functions, leave these here for now.
- globals['GetJobs'] = GetJobs
- globals['ParseConfig'] = ParseConfig
- globals['SetBuildSignatureType'] = SetBuildSignatureType
- globals['SetContentSignatureType'] = SetContentSignatureType
- globals['SetJobs'] = SetJobs
-
globals.update(GlobalDict)
return globals