diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2017-06-27 19:01:00 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2017-06-27 19:01:00 +0300 |
commit | dfb0414d9c78cbea9faf1a4bf42059a55eb2dd4b (patch) | |
tree | c946eed90b0d07587de0d99c48dfffccc15d17b0 /mesonbuild | |
parent | e4daad369ac1f5518e114561ca1c7349a4b309ae (diff) | |
parent | efef8f4f387db3f7f9322504fd1c73afb7ea3179 (diff) | |
download | meson-dfb0414d9c78cbea9faf1a4bf42059a55eb2dd4b.zip meson-dfb0414d9c78cbea9faf1a4bf42059a55eb2dd4b.tar.gz meson-dfb0414d9c78cbea9faf1a4bf42059a55eb2dd4b.tar.bz2 |
Merged Genie support.
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/backend/backends.py | 2 | ||||
-rw-r--r-- | mesonbuild/backend/ninjabackend.py | 8 | ||||
-rw-r--r-- | mesonbuild/compilers/compilers.py | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py index 95b0026..d2ea467 100644 --- a/mesonbuild/backend/backends.py +++ b/mesonbuild/backend/backends.py @@ -307,7 +307,7 @@ class Backend: if isinstance(source, mesonlib.File): source = source.fname # foo.vala files compile down to foo.c and then foo.c.o, not foo.vala.o - if source.endswith('.vala'): + if source.endswith(('.vala', '.gs')): if is_unity: return source[:-5] + '.c.' + self.environment.get_object_suffix() source = os.path.join(self.get_target_private_dir(target), source[:-5] + '.c') diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py index e8090e7..61b5f18 100644 --- a/mesonbuild/backend/ninjabackend.py +++ b/mesonbuild/backend/ninjabackend.py @@ -1005,7 +1005,7 @@ int dummy; def split_vala_sources(self, t): """ - Splits the target's sources into .vala, .vapi, and other sources. + Splits the target's sources into .vala, .gs, .vapi, and other sources. Handles both pre-existing and generated sources. Returns a tuple (vala, vapi, others) each of which is a dictionary with @@ -1026,7 +1026,7 @@ int dummy; 'mesonlib.File, not {!r}'.format(t, s) raise InvalidArguments(msg) f = s.rel_to_builddir(self.build_to_src) - if s.endswith('.vala'): + if s.endswith(('.vala', '.gs')): srctype = vala elif s.endswith('.vapi'): srctype = vapi @@ -1037,7 +1037,7 @@ int dummy; for gensrc in t.get_generated_sources(): for s in gensrc.get_outputs(): f = self.get_target_generated_dir(t, gensrc, s) - if s.endswith('.vala'): + if s.endswith(('.vala', '.gs')): srctype = vala elif s.endswith('.vapi'): srctype = vapi @@ -1061,7 +1061,7 @@ int dummy; (vala_src, vapi_src, other_src) = self.split_vala_sources(target) extra_dep_files = [] if not vala_src: - msg = 'Vala library {!r} has no Vala source files.' + msg = 'Vala library {!r} has no Vala or Genie source files.' raise InvalidArguments(msg.format(target.name)) valac = target.compilers['vala'] diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py index a200c07..579988f 100644 --- a/mesonbuild/compilers/compilers.py +++ b/mesonbuild/compilers/compilers.py @@ -39,7 +39,7 @@ lang_suffixes = { 'objc': ('m',), 'objcpp': ('mm',), 'rust': ('rs',), - 'vala': ('vala', 'vapi'), + 'vala': ('vala', 'vapi', 'gs'), 'cs': ('cs',), 'swift': ('swift',), 'java': ('java',), |