aboutsummaryrefslogtreecommitdiff
path: root/ninjabackend.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2014-05-10 01:14:52 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2014-05-10 01:14:52 +0300
commit9c2364b51564f11815c2c04c08fdd53ae01ef1fa (patch)
tree3be449d608cbd37dfb07783683dc5673a4fbc607 /ninjabackend.py
parenteeaa5d06840345e869d9f87ffa6988a88e49c8f5 (diff)
downloadmeson-9c2364b51564f11815c2c04c08fdd53ae01ef1fa.zip
meson-9c2364b51564f11815c2c04c08fdd53ae01ef1fa.tar.gz
meson-9c2364b51564f11815c2c04c08fdd53ae01ef1fa.tar.bz2
Started work on Vala compilation.
Diffstat (limited to 'ninjabackend.py')
-rw-r--r--ninjabackend.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/ninjabackend.py b/ninjabackend.py
index 02c849f..cc40d73 100644
--- a/ninjabackend.py
+++ b/ninjabackend.py
@@ -484,11 +484,24 @@ class NinjaBackend(backends.Backend):
outfile.write(description)
outfile.write('\n')
+ def generate_vala_compile_rules(self, compiler, outfile):
+ rule = 'rule %s_COMPILER\n' % compiler.get_language()
+ invoc = ' '.join([ninja_quote(i) for i in compiler.get_exelist()])
+ command = ' command = %s $FLAGS $in\n' % invoc
+ description = ' description = Compiling Vala source $in.\n'
+ outfile.write(rule)
+ outfile.write(command)
+ outfile.write(description)
+ outfile.write('\n')
+
def generate_compile_rule_for(self, langname, compiler, qstr, is_cross, outfile):
if langname == 'java':
if not is_cross:
self.generate_java_compile_rule(compiler, outfile)
return
+ if langname == 'vala':
+ if not is_cross:
+ self.generate_vala_compile_rules(compiler, outfile)
if is_cross:
crstr = '_CROSS'
else: