[nautilus/wip/oholy/gexiv2-deprecation] extensions/image-properties: Replace deprecated symbols
- From: Ondrej Holy <oholy src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/wip/oholy/gexiv2-deprecation] extensions/image-properties: Replace deprecated symbols
- Date: Fri, 9 Jul 2021 13:47:09 +0000 (UTC)
commit 8c5fa3eb080203432d7bf07af27aa27604e44ed1
Author: Ondrej Holy <oholy redhat com>
Date: Fri Jun 4 14:39:06 2021 +0200
extensions/image-properties: Replace deprecated symbols
The build log contains warnings about deprecated gexiv2 functions. Let's
port to the new API, unpin exiv3 and gexiv2 dependencies in flatpak manifests
and bump the build dependency accordingly to get rid of the warnings.
build-aux/flatpak/org.gnome.Nautilus.json | 12 ++++++------
build-aux/flatpak/org.gnome.Nautilus.yml | 10 +++++-----
build-aux/flatpak/org.gnome.NautilusMaster.yml | 7 ++++---
extensions/image-properties/nautilus-image-properties-page.c | 6 +++---
meson.build | 2 +-
5 files changed, 19 insertions(+), 18 deletions(-)
---
diff --git a/build-aux/flatpak/org.gnome.Nautilus.json b/build-aux/flatpak/org.gnome.Nautilus.json
index 52e6333a7..c4b5687e0 100644
--- a/build-aux/flatpak/org.gnome.Nautilus.json
+++ b/build-aux/flatpak/org.gnome.Nautilus.json
@@ -34,9 +34,9 @@
"buildsystem": "cmake-ninja",
"sources": [
{
- "type": "archive",
- "url": "https://github.com/Exiv2/exiv2/archive/v0.26.tar.gz",
- "sha256": "51cffa8d19d67e1da6c1d0f570a75b8f6c814113367318c2c0407691888c5f01"
+ "type": "git",
+ "url": "https://github.com/Exiv2/exiv2.git",
+ "branch": "main"
}
]
},
@@ -46,13 +46,13 @@
"builddir": true,
"config-opts": [
"--libdir=/app/lib",
- "-Ddisable-introspection=True"
+ "-Dintrospection=false",
+ "-Dpython3_girdir=no"
],
"sources": [
{
"type": "git",
- "url": "https://gitlab.gnome.org/GNOME/gexiv2.git",
- "tag": "gexiv2-0.10.10"
+ "url": "https://gitlab.gnome.org/GNOME/gexiv2.git"
}
]
},
diff --git a/build-aux/flatpak/org.gnome.Nautilus.yml b/build-aux/flatpak/org.gnome.Nautilus.yml
index 4a15c4c53..d3497fe68 100644
--- a/build-aux/flatpak/org.gnome.Nautilus.yml
+++ b/build-aux/flatpak/org.gnome.Nautilus.yml
@@ -30,19 +30,19 @@ modules:
- "-DCMAKE_INSTALL_LIBDIR=/app/lib"
buildsystem: cmake-ninja
sources:
- - type: archive
- url: https://github.com/Exiv2/exiv2/archive/v0.26.tar.gz
- sha256: 51cffa8d19d67e1da6c1d0f570a75b8f6c814113367318c2c0407691888c5f01
+ - type: git
+ url: https://github.com/Exiv2/exiv2.git
+ branch: main
- name: gexiv2
buildsystem: meson
builddir: true
config-opts:
- "--libdir=/app/lib"
- - "-Ddisable-introspection=True"
+ - "-Dintrospection=false"
+ - "-Dpython3_girdir=no"
sources:
- type: git
url: https://gitlab.gnome.org/GNOME/gexiv2.git
- tag: gexiv2-0.10.10
- name: tracker-miners
buildsystem: meson
cleanup:
diff --git a/build-aux/flatpak/org.gnome.NautilusMaster.yml b/build-aux/flatpak/org.gnome.NautilusMaster.yml
index bc1771627..72da8d7d4 100644
--- a/build-aux/flatpak/org.gnome.NautilusMaster.yml
+++ b/build-aux/flatpak/org.gnome.NautilusMaster.yml
@@ -30,15 +30,16 @@ modules:
- "-DCMAKE_INSTALL_LIBDIR=/app/lib"
buildsystem: cmake-ninja
sources:
- - type: archive
- url: https://github.com/Exiv2/exiv2/archive/v0.26.tar.gz
- sha256: 51cffa8d19d67e1da6c1d0f570a75b8f6c814113367318c2c0407691888c5f01
+ - type: git
+ url: https://github.com/Exiv2/exiv2.git
+ branch: main
- name: gexiv2
buildsystem: meson
builddir: true
config-opts:
- "--libdir=/app/lib"
- "-Dintrospection=false"
+ - "-Dpython3_girdir=no"
sources:
- type: git
url: https://gitlab.gnome.org/GNOME/gexiv2.git
diff --git a/extensions/image-properties/nautilus-image-properties-page.c
b/extensions/image-properties/nautilus-image-properties-page.c
index 23aca4986..9b7485f58 100644
--- a/extensions/image-properties/nautilus-image-properties-page.c
+++ b/extensions/image-properties/nautilus-image-properties-page.c
@@ -196,11 +196,11 @@ append_gexiv2_tag (NautilusImagesPropertiesPage *page,
{
g_autofree char *tag_value = NULL;
- tag_value = gexiv2_metadata_get_tag_interpreted_string (page->md, *i);
+ tag_value = gexiv2_metadata_try_get_tag_interpreted_string (page->md, *i, NULL);
if (description == NULL)
{
- description = gexiv2_metadata_get_tag_description (*i);
+ description = gexiv2_metadata_try_get_tag_description (*i, NULL);
}
/* don't add empty tags - try next one */
@@ -262,7 +262,7 @@ append_gexiv2_info (NautilusImagesPropertiesPage *page)
append_gexiv2_tag (page, rights, _("Copyright"));
append_gexiv2_tag (page, rating, _("Rating"));
- if (gexiv2_metadata_get_gps_info (page->md, &longitude, &latitude, &altitude))
+ if (gexiv2_metadata_try_get_gps_info (page->md, &longitude, &latitude, &altitude, NULL))
{
g_autofree char *gps_coords = NULL;
diff --git a/meson.build b/meson.build
index 12a7cd601..1d28f4e6c 100644
--- a/meson.build
+++ b/meson.build
@@ -109,7 +109,7 @@ libgd_dep = libgd.get_variable('libgd_dep')
libm = cc.find_library('m')
if get_option('extensions')
- gexiv = dependency('gexiv2', version: '>= 0.10.0')
+ gexiv = dependency('gexiv2', version: '>= 0.12.2')
gst_tag_dep = dependency('gstreamer-tag-1.0')
gst_pbutils_dep = dependency('gstreamer-pbutils-1.0')
endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]