scons: Handle Python OSError exception when missing libdrm_radeon.

Instead of crashing when libdrm_radeon is unavailable, the SCons build
just does not build r600g.
This commit is contained in:
Vinson Lee
2010-06-03 00:03:18 -07:00
parent 128190e4a9
commit d062d21416

View File

@@ -2,7 +2,11 @@ Import('*')
env = env.Clone()
env.ParseConfig('pkg-config --cflags libdrm_radeon')
try:
env.ParseConfig('pkg-config --cflags libdrm_radeon')
except OSError:
print 'warning: not building r600'
Return()
env.Append(CPPPATH = [
'#/include',