summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Mikhaylenko <alexm@gnome.org>2020-07-31 16:10:21 +0500
committerAlexander Mikhaylenko <alexm@gnome.org>2020-07-31 16:10:48 +0500
commitf5009d099da6f92b5aa292ba80f495ee824c5783 (patch)
tree1bf521e1df89a3d093f1ae52663a9a13abfd8a96
parent7675ff942680834c7108c8662c79aca04052d59b (diff)
downloadgnome-screenshot-f5009d099da6f92b5aa292ba80f495ee824c5783.tar.gz
build: Add libhandy dependency
-rw-r--r--meson.build2
-rw-r--r--org.gnome.Screenshot.json17
-rw-r--r--src/meson.build1
-rw-r--r--src/screenshot-application.c5
4 files changed, 25 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 4b1ab82..0544d5a 100644
--- a/meson.build
+++ b/meson.build
@@ -31,12 +31,14 @@ gnome_screenshot_schemadir = join_paths(gnome_screenshot_datadir, 'glib-2.0', 's
glib_req_version = '>= 2.35.1'
gtk_req_version = '>= 3.12.0'
+libhandy_req_version = '>= 0.85.0'
mathlib_dep = cc.find_library('m', required: false)
x11_dep = dependency('x11', required: get_option ('x11'))
xext_dep = dependency('xext', required: get_option ('x11'))
glib_dep = dependency('glib-2.0', version: glib_req_version)
gtk_dep = dependency('gtk+-3.0', version: gtk_req_version)
+libhandy_dep = dependency('libhandy-1', version: libhandy_req_version)
canberra_dep = dependency('libcanberra-gtk3')
config_h = configuration_data()
diff --git a/org.gnome.Screenshot.json b/org.gnome.Screenshot.json
index ecd27d1..c133fd9 100644
--- a/org.gnome.Screenshot.json
+++ b/org.gnome.Screenshot.json
@@ -51,6 +51,23 @@
]
},
{
+ "name" : "libhandy",
+ "buildsystem" : "meson",
+ "config-opts" : [
+ "-Dexamples=false",
+ "-Dglade_catalog=disabled",
+ "-Dintrospection=disabled",
+ "-Dtests=false",
+ "-Dvapi=false"
+ ],
+ "sources" : [
+ {
+ "type" : "git",
+ "url" : "https://gitlab.gnome.org/GNOME/libhandy.git"
+ }
+ ]
+ },
+ {
"name" : "gnome-screenshot",
"buildsystem" : "meson",
"builddir" : true,
diff --git a/src/meson.build b/src/meson.build
index 4436485..5c014a2 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -26,6 +26,7 @@ dependencies = [
xext_dep,
glib_dep,
gtk_dep,
+ libhandy_dep,
canberra_dep
]
diff --git a/src/screenshot-application.c b/src/screenshot-application.c
index 815b618..80f9d94 100644
--- a/src/screenshot-application.c
+++ b/src/screenshot-application.c
@@ -31,6 +31,9 @@
#include <glib/gi18n.h>
#include <gio/gio.h>
+#define HANDY_USE_UNSTABLE_API
+#include <handy.h>
+
#include "screenshot-application.h"
#include "screenshot-area-selection.h"
#include "screenshot-config.h"
@@ -810,6 +813,8 @@ screenshot_application_startup (GApplication *app)
G_APPLICATION_CLASS (screenshot_application_parent_class)->startup (app);
+ hdy_init ();
+
screenshot_load_config ();
g_set_application_name (_("Screenshot"));