2
0
mirror of https://gitlab.com/ita1024/waf.git synced 2024-11-22 01:46:15 +01:00

eclipse: remove repeated entries in include paths for C/C++

Make sure just unique include paths (both system and local) are
added to prevent overcrowding with useless redundant include paths
that grow up a lot the generated XML file and make the usage of
the GUI messy.
The filter was already there for Java/Python.
This commit is contained in:
Federico Pellegrin 2021-09-03 10:18:24 +02:00 committed by Thomas Nagy
parent 229bf15ab2
commit 9c5945d85a

View File

@ -133,9 +133,11 @@ class eclipse(Build.BuildContext):
path = p.path_from(self.srcnode)
if (path.startswith("/")):
cpppath.append(path)
if path not in cpppath:
cpppath.append(path)
else:
workspace_includes.append(path)
if path not in workspace_includes:
workspace_includes.append(path)
if is_cc and path not in source_dirs:
source_dirs.append(path)