Only run oneof test when protoc >= 2.6 is available

This commit is contained in:
Petteri Aimonen
2015-01-04 20:00:37 +02:00
parent 77a71ceb6d
commit 7135e2797a
2 changed files with 27 additions and 15 deletions

View File

@@ -72,6 +72,13 @@ if not env.GetOption('clean'):
else:
conf.env.Append(PROTOCPATH = '/usr/include')
# Check protoc version
status, output = conf.TryAction('protoc --version')
if status:
conf.env.Append(PROTOC_VERSION = output)
else:
conf.env.Append(PROTOC_VERSION = "")
# Check if libmudflap is available (only with GCC)
if 'gcc' in env['CC']:
if conf.CheckLib('mudflap'):