From fa59fa55e20a34b5c60217d9ba54d646160f6290 Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Thu, 1 Sep 2016 21:58:41 +0300 Subject: [PATCH] Use absolute paths for dep files in Visual Studio. --- mesonbuild/backend/backends.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py index b5b3b5ae2..e5dafc91f 100644 --- a/mesonbuild/backend/backends.py +++ b/mesonbuild/backend/backends.py @@ -568,7 +568,10 @@ class Backend(): elif '@DEPFILE@' in i: if target.depfile is None: raise MesonException('Custom target %s has @DEPFILE@ but no depfile keyword argument.' % target.name) - dfilename = os.path.join(self.get_target_private_dir(target), target.depfile) + if absolute_paths: + dfilename = os.path.join(self.get_target_private_dir_abs(target), target.depfile) + else: + dfilename = os.path.join(self.get_target_private_dir(target), target.depfile) i = i.replace('@DEPFILE@', dfilename) elif '@PRIVATE_OUTDIR_' in i: match = re.search('@PRIVATE_OUTDIR_(ABS_)?([-a-zA-Z0-9.@:]*)@', i)