Changeset 189 for SConstruct


Ignore:
Timestamp:
04/24/10 00:49:10 (15 years ago)
Author:
tim
Message:

additional work on new build system

File:
1 edited

Legend:

Unmodified
Added
Removed
  • SConstruct

    r188 r189  
     1
    12build_cmds='''
    23rm -rf .release;
    3 mkdir -p `dirname .release/$SOURCE`;
    4 svn export svn+ssh://sentinelchicken.org/home/projects/subversion/reglookup/$SOURCE .release/$SOURCE;
     4svn export svn+ssh://sentinelchicken.org/home/projects/subversion/reglookup/$SOURCE .release/%s;
    55#XXX: Can this be less of a hack?
    6 cd .release/$SOURCE && scons doc && cd ..;
    7 cd .release && tar cf $SOURCE.tar $SOURCE && gzip -9 $SOURCE.tar;
    8 mv .release/$SOURCE.tar.gz ..
     6cd .release/%s && scons doc
     7cd .release && tar cf %s.tar %s && gzip -9 %s.tar;
     8mv .release/%s.tar.gz . && rm -rf .release
    99'''
    10 release_builder = Builder(action=build_cmds)
     10
     11buildable_files=('reglookup-trunk.tar.gz',)
     12
     13def generate_cmds(source, target, env, for_signature):
     14    ret_val = ''
     15    for t in target:
     16        if str(t) in buildable_files:
     17            t_base = str(t).split('.')[0]
     18            ret_val += build_cmds % (t_base,t_base,t_base,
     19                                     t_base,t_base,t_base)
     20        else:
     21            return '#ERROR: cannot build "%s".  Acceptable targets: %s' % (t, repr(buildable_files))
     22
     23    return ret_val
     24
     25
     26release_builder = Builder(generator = generate_cmds,
     27                          suffix = '.tar.gz',
     28                          src_suffix = '',
     29                          prefix='reglookup-')
    1130
    1231env = Environment()
     
    1433
    1534
    16 env.Release('trunk')
    17 
    18 
    19 
     35env.Release(Dir('trunk'))
     36#env.Release('reglookup-0.13.0.tar.gz', Dir('releases/0.13.0'))
    2037
    2138Default(None)
Note: See TracChangeset for help on using the changeset viewer.