aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/backends.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2021-04-08 18:41:10 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2021-04-09 16:51:42 +0300
commit9fb0abb754b42839880489447f599c59bcff8371 (patch)
treee374158c66ab20c7d7fa1eb758c9f0e84095630e /mesonbuild/backend/backends.py
parent59306c45c525023cfab20a2f6466d812b008c473 (diff)
downloadmeson-9fb0abb754b42839880489447f599c59bcff8371.zip
meson-9fb0abb754b42839880489447f599c59bcff8371.tar.gz
meson-9fb0abb754b42839880489447f599c59bcff8371.tar.bz2
Write include dirs with absolute paths in the Xcode backend, relative ones do not seem to work.
Diffstat (limited to 'mesonbuild/backend/backends.py')
-rw-r--r--mesonbuild/backend/backends.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py
index 72e0e13..0a3875c 100644
--- a/mesonbuild/backend/backends.py
+++ b/mesonbuild/backend/backends.py
@@ -265,10 +265,13 @@ class Backend:
tmppath = os.path.normpath(os.path.join(self.build_to_src, curdir))
return compiler.get_include_args(tmppath, False)
- def get_build_dir_include_args(self, target, compiler):
- curdir = target.get_subdir()
- if curdir == '':
- curdir = '.'
+ def get_build_dir_include_args(self, target, compiler, *, absolute_path=False):
+ if absolute_path:
+ curdir = os.path.join(self.build_dir, target.get_subdir())
+ else:
+ curdir = target.get_subdir()
+ if curdir == '':
+ curdir = '.'
return compiler.get_include_args(curdir, False)
def get_target_filename_for_linking(self, target):