aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/ninjabackend.py
diff options
context:
space:
mode:
authorOle André Vadla RavnÄs <oleavr@gmail.com>2017-05-13 22:14:03 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2017-05-14 11:54:42 +0300
commit9b5df6e442672f8e7d6ead666a766234ccf41277 (patch)
tree3a8e4e6a8f9817da0cf7dbe8629e947b4e7d0fa3 /mesonbuild/backend/ninjabackend.py
parent1472f419ea14850cf0e3b01a72e66e67a1bccdf1 (diff)
downloadmeson-9b5df6e442672f8e7d6ead666a766234ccf41277.zip
meson-9b5df6e442672f8e7d6ead666a766234ccf41277.tar.gz
meson-9b5df6e442672f8e7d6ead666a766234ccf41277.tar.bz2
ninja: Deduplicate dependent vapis
The Vala compiler does not like being fed the same .vapi multiple times.
Diffstat (limited to 'mesonbuild/backend/ninjabackend.py')
-rw-r--r--mesonbuild/backend/ninjabackend.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py
index f7e84dc..d08d560 100644
--- a/mesonbuild/backend/ninjabackend.py
+++ b/mesonbuild/backend/ninjabackend.py
@@ -20,7 +20,7 @@ from .. import mlog
from .. import dependencies
from .. import compilers
from ..compilers import CompilerArgs
-from ..mesonlib import File, MesonException
+from ..mesonlib import File, MesonException, OrderedSet
from ..mesonlib import get_meson_script, get_compiler_for_source, Popen_safe
from .backends import CleanTrees, InstallData
from ..build import InvalidArguments
@@ -976,7 +976,7 @@ int dummy;
the same name as the BuildTarget and return the path to it relative to
the build directory.
"""
- result = []
+ result = OrderedSet()
for dep in target.link_targets:
for i in dep.sources:
if hasattr(i, 'fname'):
@@ -984,9 +984,9 @@ int dummy;
if i.endswith('vala'):
vapiname = dep.name + '.vapi'
fullname = os.path.join(self.get_target_dir(dep), vapiname)
- result.append(fullname)
+ result.add(fullname)
break
- return result
+ return list(result)
def split_vala_sources(self, t):
"""