summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorIñigo Martínez <inigomartinez@gmail.com>2018-03-26 22:43:50 +0200
committerOndrej Holy <oholy@redhat.com>2018-04-03 17:54:23 +0200
commitf45605210db66306ed32f9a0c6057bf095e81bb3 (patch)
treec4788d0c5490790ee3f8fe8648a9db6f8ded6498 /common
parent528ac6f989beb2e89beb9732f7bfe9eefcd8e036 (diff)
downloadgvfs-f45605210db66306ed32f9a0c6057bf095e81bb3.tar.gz
build: Revise dependencies
gvfs is using a set of glib libraries (gio-2.0, gio-unix-2.0, glib, gobject-2.0) in almost all the created objects. However, these dependencies are not always necessary. gvfs' meson port also uses some internal dependencies formed by built libraries. This internal dependencies depend on other dependendecies as well. These both issues have been fixed by reviewing all the internal dependencies and built objects. https://bugzilla.gnome.org/show_bug.cgi?id=794365
Diffstat (limited to 'common')
-rw-r--r--common/meson.build46
1 files changed, 33 insertions, 13 deletions
diff --git a/common/meson.build b/common/meson.build
index e269cb7d..ab09c33a 100644
--- a/common/meson.build
+++ b/common/meson.build
@@ -26,13 +26,19 @@ dbus_sources = custom_target(
command: [codegen, gvfs_namespace + '.', name, namespace, meson.current_build_dir(), '@INPUT@', '@OUTPUT@']
)
+deps = [
+ gio_dep,
+ glib_dep,
+ gobject_dep
+]
+
cflags = common_cflags + ['-DREMOTE_VOLUME_MONITORS_DIR="@0@"'.format(gvfs_remote_volume_monitors_dir)]
libgvfscommon = shared_library(
'gvfscommon',
sources: sources + [dbus_sources],
include_directories: top_inc,
- dependencies: glib_deps,
+ dependencies: deps + [gio_unix_dep],
c_args: cflags,
install: true,
install_dir: gvfs_pkglibdir
@@ -40,11 +46,15 @@ libgvfscommon = shared_library(
libgvfscommon_dep = declare_dependency(
sources: dbus_sources[1],
- link_with: libgvfscommon,
- include_directories: common_inc
+ include_directories: common_inc,
+ dependencies: deps,
+ link_with: libgvfscommon
)
-deps = glib_deps
+deps = [
+ gio_dep,
+ glib_dep
+]
if enable_bluray
deps += libbluray_dep
@@ -60,8 +70,9 @@ libgvfscommon_monitor = static_library(
)
libgvfscommon_monitor_dep = declare_dependency(
- link_with: libgvfscommon_monitor,
- include_directories: common_inc
+ include_directories: common_inc,
+ dependencies: gio_dep,
+ link_with: libgvfscommon_monitor
)
if enable_dnssd
@@ -70,9 +81,11 @@ if enable_dnssd
'gvfsdnssdutils.c'
)
- deps = glib_deps + [
+ deps = [
avahi_client_dep,
- avahi_glib_dep
+ avahi_glib_dep,
+ gio_dep,
+ glib_dep
]
libgvfscommon_dnssd = static_library(
@@ -85,21 +98,28 @@ if enable_dnssd
)
libgvfscommon_dnssd_dep = declare_dependency(
- link_with: libgvfscommon_dnssd,
- include_directories: common_inc
+ include_directories: common_inc,
+ dependencies: gio_dep,
+ link_with: libgvfscommon_dnssd
)
endif
if enable_mtp or enable_gphoto2
+ deps = [
+ glib_dep,
+ gudev_dep
+ ]
+
libgvfscommon_gphoto2 = static_library(
'gvfscommon-gphoto2',
sources: 'gvfsgphoto2utils.c',
include_directories: top_inc,
- dependencies: gudev_dep
+ dependencies: deps
)
libgvfscommon_gphoto2_dep = declare_dependency(
- link_with: libgvfscommon_gphoto2,
- include_directories: common_inc
+ include_directories: common_inc,
+ dependencies: deps,
+ link_with: libgvfscommon_gphoto2
)
endif