Permalink
Browse files

Merge pull request #594 from ssssam/sam/vala-target-name

Use target name to decide generated Vala .h & .vapi filenames
  • Loading branch information...
jpakkane committed Jun 16, 2016
2 parents c631cac + c76837a commit 217e0593ca3ad42aebdb5decfe3649abea45b957
Showing with 3 additions and 2 deletions.
  1. +1 −0 authors.txt
  2. +2 −2 mesonbuild/backend/ninjabackend.py
View
@@ -35,3 +35,4 @@ Rogiel Sulzbach
Tim-Philipp Müller
Emmanuele Bassi
Martin Hostettler
Sam Thursfield
@@ -772,7 +772,7 @@ def determine_dep_vapis(self, target):
if hasattr(i, 'fname'):
i = i.fname
if i.endswith('vala'):
vapiname = os.path.splitext(os.path.split(i)[1])[0] + '.vapi'
vapiname = dep.name + '.vapi'
fullname = os.path.join(self.get_target_dir(dep), vapiname)
result.append(fullname)
break
@@ -790,7 +790,7 @@ def generate_vala_compile(self, compiler, target, outfile):
vala_input_files.append(s.rel_to_builddir(self.build_to_src))
if len(src) == 0:
raise InvalidArguments('Vala library has no Vala source files.')
namebase = os.path.splitext(os.path.split(src[0].fname)[1])[0]
namebase = target.name
base_h = namebase + '.h'
base_vapi = namebase + '.vapi'
hname = os.path.normpath(os.path.join(self.get_target_dir(target), base_h))

0 comments on commit 217e059

Please sign in to comment.