Home | History | Annotate | Download | only in auxiliary
      1 Import('*')
      2 
      3 from sys import executable as python_cmd
      4 
      5 env.Append(CPPPATH = [
      6     '#src',
      7     'indices',
      8     'util',
      9 ])
     10 
     11 env = env.Clone()
     12 
     13 env.MSVC2013Compat()
     14 
     15 env.CodeGenerate(
     16     target = 'indices/u_indices_gen.c',
     17     script = 'indices/u_indices_gen.py',
     18     source = [],
     19     command = python_cmd + ' $SCRIPT > $TARGET'
     20 )
     21 
     22 env.CodeGenerate(
     23     target = 'indices/u_unfilled_gen.c',
     24     script = 'indices/u_unfilled_gen.py',
     25     source = [],
     26     command = python_cmd + ' $SCRIPT > $TARGET'
     27 )
     28 
     29 env.CodeGenerate(
     30     target = 'util/u_format_table.c',
     31     script = '#src/gallium/auxiliary/util/u_format_table.py',
     32     source = ['#src/gallium/auxiliary/util/u_format.csv'],
     33     command = python_cmd + ' $SCRIPT $SOURCE > $TARGET'
     34 )
     35 
     36 env.Depends('util/u_format_table.c', [
     37     '#src/gallium/auxiliary/util/u_format_parse.py',
     38     'util/u_format_pack.py',
     39 ])
     40 
     41 source = env.ParseSourceList('Makefile.sources', [
     42     'C_SOURCES',
     43     'VL_STUB_SOURCES',
     44     'GENERATED_SOURCES'
     45 ])
     46 
     47 if env['llvm']:
     48     source += env.ParseSourceList('Makefile.sources', [
     49         'GALLIVM_SOURCES',
     50     ])
     51 
     52 gallium = env.ConvenienceLibrary(
     53     target = 'gallium',
     54     source = source,
     55 )
     56 
     57 env.Alias('gallium', gallium)
     58 
     59 Export('gallium')
     60