diff options
author | Sam Thursfield <sam@afuera.me.uk> | 2021-07-12 13:25:14 +0200 |
---|---|---|
committer | António Fernandes <antoniof@gnome.org> | 2023-05-07 15:57:16 +0000 |
commit | 58f69d1b52f4f58813cfebb409ce8379c607d712 (patch) | |
tree | 39db82c96bf54b1f8a152299fba02c1506877902 | |
parent | e7da20bb88f66208882647a7e21654fc3ae0ba7f (diff) | |
download | nautilus-58f69d1b52f4f58813cfebb409ce8379c607d712.tar.gz |
flatpak: Set Tracker Miners domain using config optionsam/tracker-domain-argument
The current approach dates from before the 'domain_prefix' option
existed in Tracker Miners.
It is already used by Totem[1] and should be used by all apps that
bundle Tracker Miners.
1. https://gitlab.gnome.org/GNOME/totem/-/blob/master/flatpak/org.gnome.Totem.Devel.json#L164
-rw-r--r-- | build-aux/flatpak/org.gnome.Nautilus.json | 2 | ||||
-rw-r--r-- | data/meson.build | 1 | ||||
-rw-r--r-- | data/tracker/meson.build | 31 | ||||
-rw-r--r-- | data/tracker/org.gnome.Nautilus.Tracker3.Miner.Extract.service.in | 7 | ||||
-rw-r--r-- | data/tracker/org.gnome.Nautilus.Tracker3.Miner.Files.service.in | 7 | ||||
-rw-r--r-- | data/tracker/org.gnome.Nautilus.domain.rule.in | 21 |
6 files changed, 2 insertions, 67 deletions
diff --git a/build-aux/flatpak/org.gnome.Nautilus.json b/build-aux/flatpak/org.gnome.Nautilus.json index b8df9f52d..f854e93f0 100644 --- a/build-aux/flatpak/org.gnome.Nautilus.json +++ b/build-aux/flatpak/org.gnome.Nautilus.json @@ -77,10 +77,12 @@ "/share/dbus-1/services/org.freedesktop.Tracker3.Miner.Files.Control.service" ], "config-opts": [ + "-Ddomain_prefix=org.gnome.NautilusDevel", "-Dextract=true", "-Dgeneric_media_extractor=none", "-Dman=false", "-Dminer_fs=true", + "-Dminer_fs_cache_location=$XDG_CACHE_HOME/nautilus/miner/files", "-Dminer_rss=false", "-Dsystemd_user_services=false", "-Dwriteback=false", diff --git a/data/meson.build b/data/meson.build index 2df5a226c..708ad9504 100644 --- a/data/meson.build +++ b/data/meson.build @@ -135,4 +135,3 @@ if appstream_util.found() endif subdir('ontology') -subdir('tracker') diff --git a/data/tracker/meson.build b/data/tracker/meson.build deleted file mode 100644 index 5320af164..000000000 --- a/data/tracker/meson.build +++ /dev/null @@ -1,31 +0,0 @@ -# Files needed for running Tracker inside the Flatpak sandbox, for systems -# which don't have a suitable version of Tracker in the host OS. -# -# We must export the .service files from the sandbox so they work on the -# session bus. This means the Tracker domain name must correspond with the -# application ID. - -domain_ontologies_dir = get_option('datadir') / 'tracker3' / 'domain-ontologies' -dbus_services_dir = get_option('datadir') / 'dbus-1' / 'services' - -tracker_domain_config = configuration_data() -tracker_domain_config.set('application_id', application_id) -tracker_domain_config.set('domain_rule', get_option('prefix') / domain_ontologies_dir / application_id + '.domain.rule') - -configure_file( - input: 'org.gnome.Nautilus.domain.rule.in', - output: application_id + '.domain.rule', - configuration: tracker_domain_config, - install_dir: domain_ontologies_dir) - -configure_file( - input: 'org.gnome.Nautilus.Tracker3.Miner.Extract.service.in', - output: application_id + '.Tracker3.Miner.Extract.service', - configuration: tracker_domain_config, - install_dir: dbus_services_dir) - -configure_file( - input: 'org.gnome.Nautilus.Tracker3.Miner.Files.service.in', - output: application_id + '.Tracker3.Miner.Files.service', - configuration: tracker_domain_config, - install_dir: dbus_services_dir) diff --git a/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Extract.service.in b/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Extract.service.in deleted file mode 100644 index eb7a87aa6..000000000 --- a/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Extract.service.in +++ /dev/null @@ -1,7 +0,0 @@ -[D-BUS Service] -Name=@application_id@.Tracker3.Miner.Extract -Exec=/app/libexec/tracker-extract-3 --domain-ontology @domain_rule@ - -# Miner details needed for tracker-control -Path=/org/freedesktop/Tracker3/Miner/Extract -NameSuffix=Miner.Files diff --git a/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Files.service.in b/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Files.service.in deleted file mode 100644 index 4fa7371d1..000000000 --- a/data/tracker/org.gnome.Nautilus.Tracker3.Miner.Files.service.in +++ /dev/null @@ -1,7 +0,0 @@ -[D-BUS Service] -Name=@application_id@.Tracker3.Miner.Files -Exec=/app/libexec/tracker-miner-fs-3 --domain-ontology @domain_rule@ --initial-sleep 0 - -# Miner details needed for tracker-control -Path=/org/freedesktop/Tracker3/Miner/Files -NameSuffix=Miner.Files diff --git a/data/tracker/org.gnome.Nautilus.domain.rule.in b/data/tracker/org.gnome.Nautilus.domain.rule.in deleted file mode 100644 index ec0808e30..000000000 --- a/data/tracker/org.gnome.Nautilus.domain.rule.in +++ /dev/null @@ -1,21 +0,0 @@ -# This defines a private Tracker domain for Nautilus. -# -# It's used to run the Tracker indexer inside a Flatpak sandbox, when Nautilus -# is running on a host that doesn't have a suitable version of Tracker -# installed. - -[DomainOntology] -# Location for the Tracker database -CacheLocation=$XDG_CACHE_HOME/nautilus/miner/files - -# Name of the ontology to use, must be one located in -# $(sharedir)/tracker/ontologies -OntologyName=nepomuk - -# DBus name for the owner (not optional). Tracker will use -# the domain as the prefix of the DBus name for all the -# services related to this domain ontology. -Domain=@application_id@ - -# List of miners we expect to run in this domain. -Miners=Miner.Files;Miner.Extract |