Import('*')

env = env.Clone()

try:
    env.ParseConfig('pkg-config --cflags libdrm_radeon')
except OSError:
    print 'warning: not building r600'
    Return()

env.Append(CPPPATH = [
    '#/include', 
    '#/src/mesa',
])

r600 = env.ConvenienceLibrary(
    target = 'r600',
    source = [
        'r600_asm.c',
        'r600_buffer.c',
        'r600_blit.c',
        'r600_helper.c',
        'r600_pipe.c',
        'r600_query.c',
        'r600_resource.c',
        'r600_shader.c',
        'r600_state.c',
        'r600_state_common.c',
        'r600_texture.c',
        'r600_translate.c',
        'r600_upload.c',
        'r700_asm.c',
        'evergreen_state.c',
        'eg_asm.c',
    ])

env.Alias('r600', r600)

Export('r600')
