aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/ninjabackend.py
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/backend/ninjabackend.py')
-rw-r--r--mesonbuild/backend/ninjabackend.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py
index c80d832..68af1af 100644
--- a/mesonbuild/backend/ninjabackend.py
+++ b/mesonbuild/backend/ninjabackend.py
@@ -2013,7 +2013,8 @@ https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47485'''))
# own target build dir.
if not isinstance(i, (build.CustomTarget, build.CustomTargetIndex)):
continue
- idir = self.get_target_dir(i)
+ # NOTE: if we want to use os.path.realpath() for include path only! CK
+ idir = os.path.normpath(self.get_target_dir(i))
if not idir:
idir = '.'
if idir not in custom_target_include_dirs:
@@ -2027,10 +2028,12 @@ https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47485'''))
def generate_inc_dir(self, compiler, d, basedir, is_system):
# Avoid superfluous '/.' at the end of paths when d is '.'
if d not in ('', '.'):
- expdir = os.path.join(basedir, d)
+ # NOTE: if we want to use os.path.realpath() for include path only! CK
+ expdir = os.path.normpath(os.path.join(basedir, d))
else:
expdir = basedir
- srctreedir = os.path.join(self.build_to_src, expdir)
+ # NOTE: if we want to use os.path.realpath() for include path only! CK
+ srctreedir = os.path.normpath(os.path.join(self.build_to_src, expdir))
sargs = compiler.get_include_args(srctreedir, is_system)
# There may be include dirs where a build directory has not been
# created for some source dir. For example if someone does this: