summaryrefslogtreecommitdiff
path: root/properties
diff options
context:
space:
mode:
authorColomban Wendling <[email protected]>2025-11-05 17:53:55 +0100
committerOz Tiram <[email protected]>2025-12-23 06:44:55 +0100
commite516c118ab149773f707ac37098b245aacc27e25 (patch)
treeab825728160272f150737c6c7da1e3c3ef457683 /properties
parent6b84e019a66324266cc92754d6982c6a4f6cd65b (diff)
downloadatril-e516c118ab149773f707ac37098b245aacc27e25.tar.bz2
atril-e516c118ab149773f707ac37098b245aacc27e25.tar.xz
meson: Build and install the Caja extension
This is controlled by the `caja` feature, which defaults to enabled.
Diffstat (limited to 'properties')
-rw-r--r--properties/meson.build32
1 files changed, 32 insertions, 0 deletions
diff --git a/properties/meson.build b/properties/meson.build
index cc97aa0e..247abe67 100644
--- a/properties/meson.build
+++ b/properties/meson.build
@@ -18,3 +18,35 @@ libevproperties_dep = declare_dependency(
include_directories: properties_inc,
dependencies: [glib_dep, gtk]
)
+
+gtk_x11 = dependency('gtk+-x11-' + gtk_api_version, required: get_option('caja'))
+caja_extension = dependency('libcaja-extension', version: '>= 1.17.1', required: get_option('caja'))
+if gtk_x11.found() and caja_extension.found()
+ shared_module(
+ 'atril-properties-page',
+ ['ev-properties-main.c'],
+ include_directories: include_dirs,
+ dependencies: [gtk_x11, caja_extension, libdocument_dep, libevproperties_dep],
+ install: true,
+ install_dir: caja_extension.get_variable(pkgconfig: 'extensiondir')
+ )
+
+ caja_ext_conf = configuration_data()
+ caja_ext_conf.set('VERSION', meson.project_version())
+ caja_ext_conf.set('PACKAGE_URL', 'https://mate-desktop.org')
+
+ caja_ext = configure_file(
+ input: 'libatril-properties-page.caja-extension.desktop.in.in',
+ output: 'libatril-properties-page.caja-extension.desktop.in',
+ configuration: caja_ext_conf,
+ )
+
+ i18n.merge_file(
+ input: caja_ext,
+ output: 'libatril-properties-page.caja-extension',
+ type: 'desktop',
+ po_dir: po_dir,
+ install: true,
+ install_dir: join_paths(datadir, 'caja', 'extensions'),
+ )
+endif