[tracker] meson: Rearrange dependencies until things compile
- From: Sam Thursfield <sthursfield src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] meson: Rearrange dependencies until things compile
- Date: Mon, 3 Jul 2017 15:38:26 +0000 (UTC)
commit abbef681056d10324f8828251f9a9973329a7563
Author: Sam Thursfield <sam afuera me uk>
Date: Mon Jul 3 16:33:20 2017 +0100
meson: Rearrange dependencies until things compile
Targets far down the dependency chain were failing due to mysteriously
missing symbols. The use of -Wl,--as-needed seemed to be triggering the
issue.
This only occured with new versions of Meson. Previously circular
dependencies would be added recursively but this was removed with
<https://github.com/mesonbuild/meson/pull/1545>.
I'm not 100% sure how this fixes things, but I think that removing
or at least reshuffling circular dependencies of libtracker-sparql
means that libraries are passed to the linker in "correct" order.
src/libtracker-sparql-backend/meson.build | 19 ++++++++++++++-----
src/libtracker-sparql/meson.build | 1 -
2 files changed, 14 insertions(+), 6 deletions(-)
---
diff --git a/src/libtracker-sparql-backend/meson.build b/src/libtracker-sparql-backend/meson.build
index 17f2b53..a46d61b 100644
--- a/src/libtracker-sparql-backend/meson.build
+++ b/src/libtracker-sparql-backend/meson.build
@@ -1,17 +1,26 @@
libtracker_sparql = library('tracker-sparql-' + tracker_api_version,
- 'tracker-backend.vala',
'../libtracker-common/libtracker-common.vapi',
+ 'tracker-backend.vala',
+
c_args: ['-DTRACKER_COMPILATION'],
+
install: true,
install_rpath: tracker_internal_libs_dir,
- link_whole: libtracker_sparql_intermediate_c,
- dependencies: [tracker_sparql_intermediate_dep, tracker_sparql_remote_dep, tracker_sparql_bus_dep,
tracker_sparql_direct_dep],
+
+ link_whole: [libtracker_sparql_intermediate_c, libtracker_sparql_intermediate_vala],
+
+ # We need to pass this because link_whole doesn't trigger the .vapi
+ # to be included in some versions of Meson.
+ # https://github.com/mesonbuild/meson/pull/2030
+ link_with: libtracker_sparql_intermediate_vala,
+
+ dependencies: [tracker_common_dep, tracker_sparql_remote_dep, tracker_sparql_bus_dep,
tracker_sparql_direct_dep],
)
tracker_sparql_dep = declare_dependency(
- link_with: [libtracker_sparql, libtracker_common],
+ link_with: [libtracker_sparql, libtracker_sparql_intermediate_vala],
include_directories: srcinc,
- dependencies: [tracker_sparql_intermediate_dep, tracker_common_dep],
+ dependencies: [tracker_common_dep],
include_directories: srcinc,
)
diff --git a/src/libtracker-sparql/meson.build b/src/libtracker-sparql/meson.build
index 15bd9fa..2fe824c 100644
--- a/src/libtracker-sparql/meson.build
+++ b/src/libtracker-sparql/meson.build
@@ -12,7 +12,6 @@ tracker_sparql_intermediate_dependencies = [uuid]
# First build the Vala parts ...
libtracker_sparql_intermediate_vala = static_library('tracker-sparql-intermediate-vala',
- enums_c, enums_h,
'tracker-namespace.vala',
'tracker-builder.vala',
'tracker-connection.vala',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]