From ccb60bb8d4aed269bdf4b6b38c44b346f7ac1188 Mon Sep 17 00:00:00 2001 From: Christian Dywan Date: Sun, 25 Apr 2010 23:36:53 +0200 Subject: [PATCH] Only pick up .vala files if Vala is available --- extensions/wscript_build | 4 ++-- tests/wscript_build | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/wscript_build b/extensions/wscript_build index aeaac361..d3d3d9ca 100644 --- a/extensions/wscript_build +++ b/extensions/wscript_build @@ -14,7 +14,7 @@ for extension in extensions: for fila in files: if fila[-2:] == '.c': source += ' ' + extension + os.sep + fila - elif fila[-5:] == '.vala': + elif 'VALAC' in bld.env and fila[-5:] == '.vala': source += ' ' + extension + os.sep + fila if not source: Utils.pprint ('RED', folder + ': No source files found') @@ -22,7 +22,7 @@ for extension in extensions: else: if extension[-2:] == '.c': target = extension[:-2] - elif extension[-5:] == '.vala': + elif 'VALAC' in bld.env and extension[-5:] == '.vala': target = extension[:-5] else: continue diff --git a/tests/wscript_build b/tests/wscript_build index 5cd3ae4d..34825ad6 100644 --- a/tests/wscript_build +++ b/tests/wscript_build @@ -14,7 +14,7 @@ for test in tests: for fila in files: if fila[-2:] == '.c': source += ' ' + test + os.sep + fila - elif file[-5:] == '.vala': + elif 'VALAC' in bld.env and file[-5:] == '.vala': source += ' ' + test + os.sep + fila if not source: Utils.pprint ('RED', folder + ': No source files found') @@ -22,7 +22,7 @@ for test in tests: else: if test[-2:] == '.c': target = test[:-2] - elif test[-5:] == '.vala': + elif 'VALAC' in bld.env and test[-5:] == '.vala': target = test[:-5] else: continue