aboutsummaryrefslogtreecommitdiff
path: root/backends.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2013-06-15 03:17:52 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2013-06-15 03:17:52 +0300
commitaf126c9d0ed95287d0a3a7511ccc06d9a9b7f1e9 (patch)
treea51a499135b658f98c0bb07f796ae971eed61100 /backends.py
parent45d51954941328342aecb710133785cefdacfe18 (diff)
downloadmeson-af126c9d0ed95287d0a3a7511ccc06d9a9b7f1e9.zip
meson-af126c9d0ed95287d0a3a7511ccc06d9a9b7f1e9.tar.gz
meson-af126c9d0ed95287d0a3a7511ccc06d9a9b7f1e9.tar.bz2
Dependency tracking works with MSVC.
Diffstat (limited to 'backends.py')
-rwxr-xr-xbackends.py17
1 files changed, 12 insertions, 5 deletions
diff --git a/backends.py b/backends.py
index e567ed5..7d43cdb 100755
--- a/backends.py
+++ b/backends.py
@@ -190,6 +190,7 @@ class Backend():
def generate_basic_compiler_flags(self, target, compiler):
commands = []
+ commands += compiler.get_always_flags()
commands += self.build.get_global_flags(compiler)
commands += target.get_extra_args(compiler.get_language())
if self.environment.coredata.buildtype != 'plain':
@@ -540,10 +541,13 @@ class NinjaBackend(Backend):
' '.join(compiler.get_output_flags('$out')),\
' '.join(compiler.get_compile_only_flags()))
description = ' description = Compiling %s object $out\n' % langname
- dep = ' depfile = $DEPFILE\n'
+ if compiler.get_id() == 'msvc':
+ deps = ' deps = msvc\n'
+ else:
+ deps = ' depfile = $DEPFILE\n'
outfile.write(rule)
outfile.write(command)
- outfile.write(dep)
+ outfile.write(deps)
outfile.write(description)
outfile.write('\n')
@@ -559,11 +563,14 @@ class NinjaBackend(Backend):
' '.join([qstr % d for d in depflags]),\
output,\
' '.join(compiler.get_compile_only_flags()))
- description = ' description = Precompilling header %s\n' % '$in'
- dep = ' depfile = $DEPFILE\n'
+ description = ' description = Precompiling header %s\n' % '$in'
+ if compiler.get_id() == 'msvc':
+ deps = ' deps = msvc\n'
+ else:
+ deps = ' depfile = $DEPFILE\n'
outfile.write(rule)
outfile.write(command)
- outfile.write(dep)
+ outfile.write(deps)
outfile.write(description)
outfile.write('\n')