summaryrefslogtreecommitdiff
path: root/src/gallium/tests/unit/SConscript
blob: 359759e22b264cb3fb9ad58432c8f066ce6e5b1b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
Import('*')

env = env.Clone()

env.Prepend(LIBS = [gallium])

if platform in ('freebsd8', 'sunos5'):
    env.Append(LIBS = ['m'])

if platform == 'freebsd8':
    env.Append(LIBS = ['pthread'])

progs = [
    'pipe_barrier_test',
    'u_cache_test',
    'u_format_test',
    'u_format_compatible_test',
    'u_half_test',
    'translate_test'
]

for prog in progs:
    prog = env.Program(
        target = prog,
        source = prog + '.c',
    )
    
    env.InstallProgram(prog)

    # http://www.scons.org/wiki/UnitTests
    test_alias = env.Alias('unit', [prog], prog[0].abspath)
    AlwaysBuild(test_alias)