Changeset 760 for branches


Ignore:
Timestamp:
07/09/06 00:55:59 (6 years ago)
Author:
wd
Message:

Switch to 0.96.92 scons (whoops)

Location:
branches/ithildin-scons/build
Files:
151 added
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • branches/ithildin-scons/build/scons.py

    r759 r760  
    2525# 
    2626 
    27 __revision__ = "/home/scons/scons/branch.0/baseline/src/script/scons.py 0.96.1.D001 2004/08/23 09:55:29 knight" 
     27__revision__ = "/home/scons/scons/branch.0/branch.96/baseline/src/script/scons.py 0.96.92.D002 2006/04/11 07:39:43 knight" 
    2828 
    29 __version__ = "0.96.1" 
     29__version__ = "0.96.92" 
    3030 
    31 __build__ = "D001" 
     31__build__ = "D002" 
    3232 
    33 __buildsys__ = "casablanca" 
     33__buildsys__ = "roxbury" 
    3434 
    35 __date__ = "2004/08/23 09:55:29" 
     35__date__ = "2006/04/11 07:39:43" 
    3636 
    3737__developer__ = "knight" 
     
    130130    prefs = temp 
    131131 
     132    # Add the parent directory of the current python's library to the 
     133    # preferences.  On SuSE-91/AMD64, for example, this is /usr/lib64, 
     134    # not /usr/lib. 
     135    try: 
     136        libpath = os.__file__ 
     137    except AttributeError: 
     138        pass 
     139    else: 
     140        while libpath: 
     141            libpath, tail = os.path.split(libpath) 
     142            if tail[:6] == "python": 
     143                break 
     144        if libpath: 
     145            # Python library is in /usr/libfoo/python*; 
     146            # check /usr/libfoo/scons*. 
     147            prefs.append(libpath) 
     148 
    132149# Look first for 'scons-__version__' in all of our preference libs, 
    133150# then for 'scons'. 
  • branches/ithildin-scons/build/sconsign.py

    r759 r760  
    2525# 
    2626 
    27 __revision__ = "/home/scons/scons/branch.0/baseline/src/script/sconsign.py 0.96.1.D001 2004/08/23 09:55:29 knight" 
    28  
    29 __version__ = "0.96.1" 
    30  
    31 __build__ = "D001" 
    32  
    33 __buildsys__ = "casablanca" 
    34  
    35 __date__ = "2004/08/23 09:55:29" 
     27__revision__ = "/home/scons/scons/branch.0/branch.96/baseline/src/script/sconsign.py 0.96.92.D002 2006/04/11 07:39:43 knight" 
     28 
     29__version__ = "0.96.92" 
     30 
     31__build__ = "D002" 
     32 
     33__buildsys__ = "roxbury" 
     34 
     35__date__ = "2006/04/11 07:39:43" 
    3636 
    3737__developer__ = "knight" 
     
    131131    prefs = temp 
    132132 
     133    # Add the parent directory of the current python's library to the 
     134    # preferences.  On SuSE-91/AMD64, for example, this is /usr/lib64, 
     135    # not /usr/lib. 
     136    try: 
     137        libpath = os.__file__ 
     138    except AttributeError: 
     139        pass 
     140    else: 
     141        while libpath: 
     142            libpath, tail = os.path.split(libpath) 
     143            if tail[:6] == "python": 
     144                break 
     145        if libpath: 
     146            # Python library is in /usr/libfoo/python*; 
     147            # check /usr/libfoo/scons*. 
     148            prefs.append(libpath) 
     149 
    133150# Look first for 'scons-__version__' in all of our preference libs, 
    134151# then for 'scons'. 
     
    185202Verbose = 0 
    186203Readable = 0 
     204Raw = 0 
    187205 
    188206def default_mapper(entry, name): 
     
    225243} 
    226244 
    227 def printfield(name, entry): 
    228     def field(name, verbose=Verbose, entry=entry): 
    229         if not Print_Flags[name]: 
    230             return None 
    231         fieldname = map_name.get(name, name) 
    232         mapper = map_field.get(fieldname, default_mapper) 
    233         val = mapper(entry, name) 
    234         if verbose: 
    235             val = name + ": " + val 
    236         return val 
    237  
    238     fieldlist = ["timestamp", "bsig", "csig"] 
    239     outlist = [name+":"] + filter(None, map(field, fieldlist)) 
    240     sep = Verbose and "\n    " or " " 
    241     print string.join(outlist, sep) 
    242  
    243     outlist = field("implicit", 0) 
     245def field(name, entry, verbose=Verbose): 
     246    if not Print_Flags[name]: 
     247        return None 
     248    fieldname = map_name.get(name, name) 
     249    mapper = map_field.get(fieldname, default_mapper) 
     250    val = mapper(entry, name) 
     251    if verbose: 
     252        val = name + ": " + val 
     253    return val 
     254 
     255def nodeinfo_raw(name, ninfo, prefix=""): 
     256    # This does essentially what the pprint module does, 
     257    # except that it sorts the keys for deterministic output. 
     258    d = ninfo.__dict__ 
     259    keys = d.keys() 
     260    keys.sort() 
     261    l = [] 
     262    for k in keys: 
     263        l.append('%s: %s' % (repr(k), repr(d[k]))) 
     264    return name + ': {' + string.join(l, ', ') + '}' 
     265 
     266def nodeinfo_string(name, ninfo, prefix=""): 
     267    fieldlist = ["bsig", "csig", "timestamp", "size"] 
     268    f = lambda x, ni=ninfo, v=Verbose: field(x, ni, v) 
     269    outlist = [name+":"] + filter(None, map(f, fieldlist)) 
     270    if Verbose: 
     271        sep = "\n    " + prefix 
     272    else: 
     273        sep = " " 
     274    return string.join(outlist, sep) 
     275 
     276def printfield(name, entry, prefix=""): 
     277    if Raw: 
     278        print nodeinfo_raw(name, entry.ninfo, prefix) 
     279    else: 
     280        print nodeinfo_string(name, entry.ninfo, prefix) 
     281 
     282    outlist = field("implicit", entry, 0) 
    244283    if outlist: 
    245284        if Verbose: 
     
    257296                printfield(name, entry) 
    258297    else: 
    259         for name, e in entries.items(): 
    260             printfield(name, e) 
     298        names = entries.keys() 
     299        names.sort() 
     300        for name in names: 
     301            printfield(name, entries[name]) 
    261302 
    262303class Do_SConsignDB: 
     
    346387  -i, --implicit              Print implicit dependency information. 
    347388  -r, --readable              Print timestamps in human-readable form. 
     389  --raw                       Print raw Python object representations. 
     390  -s, --size                  Print file sizes. 
    348391  -t, --timestamp             Print timestamp information. 
    349392  -v, --verbose               Verbose, describe each field. 
    350393""" 
    351394 
    352 opts, args = getopt.getopt(sys.argv[1:], "bcd:e:f:hirtv", 
     395opts, args = getopt.getopt(sys.argv[1:], "bcd:e:f:hirstv", 
    353396                            ['bsig', 'csig', 'dir=', 'entry=', 
    354397                             'format=', 'help', 'implicit', 
    355                              'readable', 'timestamp', 'verbose']) 
     398                             'raw', 'readable', 
     399                             'size', 'timestamp', 'verbose']) 
    356400 
    357401 
     
    384428    elif o in ('-i', '--implicit'): 
    385429        Print_Flags['implicit'] = 1 
     430    elif o in ('--raw',): 
     431        Raw = 1 
    386432    elif o in ('-r', '--readable'): 
    387433        Readable = 1 
     434    elif o in ('-s', '--size'): 
     435        Print_Flags['size'] = 1 
    388436    elif o in ('-t', '--timestamp'): 
    389437        Print_Flags['timestamp'] = 1 
Note: See TracChangeset for help on using the changeset viewer.