scons: Use libdrm options only where needed.

Prevents needless recompiles when switching dri=yes to no.
This commit is contained in:
José Fonseca 2010-04-10 02:00:33 +01:00
parent 9faf9529f3
commit 9fc93b8041
2 changed files with 2 additions and 10 deletions

View File

@ -167,16 +167,6 @@ if platform in ('posix', 'linux', 'freebsd', 'darwin'):
'dl',
])
# DRI
if dri:
env.ParseConfig('pkg-config --cflags --libs libdrm')
env.Append(CPPDEFINES = [
('USE_EXTERNAL_DXTN_LIB', '1'),
'IN_DRI_DRIVER',
'GLX_DIRECT_RENDERING',
'GLX_INDIRECT_RENDERING',
])
# LLVM support in the Draw module
if drawllvm:
env.Append(CPPDEFINES = ['DRAW_LLVM'])

View File

@ -7,6 +7,8 @@ if env['dri']:
env = env.Clone()
env.ParseConfig('pkg-config --cflags --libs libdrm')
env.Append(CPPPATH = [
'#/src/mesa',
'#/src/gallium/state_trackers/dri/common',