~ubuntu-branches/ubuntu/trusty/mapnik/trusty

« back to all changes in this revision

Viewing changes to scons/scons-local-1.2.0/SCons/Options/__init__.py

  • Committer: Bazaar Package Importer
  • Author(s): Andres Rodriguez
  • Date: 2009-05-20 15:39:58 UTC
  • mfrom: (3.1.2 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090520153958-cf6z1ql9zva4y4dq
Tags: 0.6.0-1ubuntu1
* Merge from debian unstable (LP: #378819), remaining changes:
  - debian/control:
    + Change bdeps from python2.5-dev to python-all-dev (>= 2.5)
    + Change XS-Python-Version from 2.5 to >= 2.5
  - debian/rules:
    + Various changes to enable python2.5 and python2.6 builds
* debian/patches/libtool2_2.diff Dropped. Included upsteam.
* Removed quilt support.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 The SCons Foundation
 
3
#
 
4
# Permission is hereby granted, free of charge, to any person obtaining
 
5
# a copy of this software and associated documentation files (the
 
6
# "Software"), to deal in the Software without restriction, including
 
7
# without limitation the rights to use, copy, modify, merge, publish,
 
8
# distribute, sublicense, and/or sell copies of the Software, and to
 
9
# permit persons to whom the Software is furnished to do so, subject to
 
10
# the following conditions:
 
11
#
 
12
# The above copyright notice and this permission notice shall be included
 
13
# in all copies or substantial portions of the Software.
 
14
#
 
15
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
 
16
# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
 
17
# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
 
18
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
 
19
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
 
20
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 
21
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
22
#
 
23
 
 
24
__revision__ = "src/engine/SCons/Options/__init__.py 3842 2008/12/20 22:59:52 scons"
 
25
 
 
26
__doc__ = """Place-holder for the old SCons.Options module hierarchy
 
27
 
 
28
This is for backwards compatibility.  The new equivalent is the Variables/
 
29
class hierarchy.  These will have deprecation warnings added (some day),
 
30
and will then be removed entirely (some day).
 
31
"""
 
32
 
 
33
import SCons.Variables
 
34
import SCons.Warnings
 
35
 
 
36
from BoolOption import BoolOption  # okay
 
37
from EnumOption import EnumOption  # okay
 
38
from ListOption import ListOption  # naja
 
39
from PackageOption import PackageOption # naja
 
40
from PathOption import PathOption # okay
 
41
 
 
42
warned = False
 
43
 
 
44
class Options(SCons.Variables.Variables):
 
45
    def __init__(self, *args, **kw):
 
46
        global warned
 
47
        if not warned:
 
48
            msg = "The Options class is deprecated; use the Variables class instead."
 
49
            SCons.Warnings.warn(SCons.Warnings.DeprecatedOptionsWarning, msg)
 
50
            warned = True
 
51
        apply(SCons.Variables.Variables.__init__,
 
52
              (self,) + args,
 
53
              kw)
 
54
 
 
55
    def AddOptions(self, *args, **kw):
 
56
        return apply(SCons.Variables.Variables.AddVariables,
 
57
                     (self,) + args,
 
58
                     kw)
 
59
 
 
60
    def UnknownOptions(self, *args, **kw):
 
61
        return apply(SCons.Variables.Variables.UnknownVariables,
 
62
                     (self,) + args,
 
63
                     kw)
 
64
 
 
65
    def FormatOptionHelpText(self, *args, **kw):
 
66
        return apply(SCons.Variables.Variables.FormatVariableHelpText,
 
67
                     (self,) + args,
 
68
                     kw)