From cd4e5879ebd4fe71c5e95d83cdf4a2ebd2fd1e06 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Fonseca?= Date: Tue, 13 Apr 2010 19:40:48 +0900 Subject: [PATCH] scons: Fix exception when llvm-config is not present. --- common.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/common.py b/common.py index 8372176edd7..742dabf4c45 100644 --- a/common.py +++ b/common.py @@ -34,10 +34,15 @@ else: default_machine = _platform.machine() default_machine = _machine_map.get(default_machine, 'generic') -if 'LLVM' in os.environ or subprocess.call(['llvm-config', '--version'], stdout=subprocess.PIPE) == 0: +if 'LLVM' in os.environ: default_llvm = 'yes' else: default_llvm = 'no' + try: + if subprocess.call(['llvm-config', '--version'], stdout=subprocess.PIPE) == 0: + default_llvm = 'yes' + except: + pass if default_platform in ('linux', 'freebsd'): default_dri = 'yes' -- 2.30.2