diff options
-rw-r--r-- | mesonbuild/modules/gnome.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py index b7d1438..e9a4a8a 100644 --- a/mesonbuild/modules/gnome.py +++ b/mesonbuild/modules/gnome.py @@ -385,7 +385,13 @@ class GnomeModule: # spurious dependencies) but building GStreamer fails if they # are not used here. cflags, ldflags, gi_includes = self.get_dependencies_flags(deps, state, depends) - scan_command += list(cflags) + list(ldflags) + scan_command += list(cflags) + # need to put our output directory first as we need to use the + # generated libraries instead of any possibly installed system/prefix + # ones. + if isinstance(girtarget, build.SharedLibrary): + scan_command += ["-L@PRIVATE_OUTDIR_ABS_%s@" % girtarget.get_id()] + scan_command += list(ldflags) for i in gi_includes: scan_command += ['--add-include-path=%s' % i] @@ -403,7 +409,6 @@ class GnomeModule: if isinstance(girtarget, build.Executable): scan_command += ['--program', girtarget] elif isinstance(girtarget, build.SharedLibrary): - scan_command += ["-L@PRIVATE_OUTDIR_ABS_%s@" % girtarget.get_id()] libname = girtarget.get_basename() scan_command += ['--library', libname] scankwargs = {'output' : girfile, |