diff --git a/.evince.metadata b/.evince.metadata index 49ed704..b379673 100644 --- a/.evince.metadata +++ b/.evince.metadata @@ -1 +1 @@ -7b24678035c50c4ccaf76bdd64e228b1c1912d4b SOURCES/evince-3.22.1.tar.xz +b9eee551124ec1da7baf6f7656afe8285670b28e SOURCES/evince-3.28.2.tar.xz diff --git a/.gitignore b/.gitignore index fdc8e8b..ac1c29c 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/evince-3.22.1.tar.xz +SOURCES/evince-3.28.2.tar.xz diff --git a/SOURCES/0001-Resolves-rhbz-1358249-page-up-down.patch b/SOURCES/0001-Resolves-rhbz-1358249-page-up-down.patch index adc3863..30a52f4 100644 --- a/SOURCES/0001-Resolves-rhbz-1358249-page-up-down.patch +++ b/SOURCES/0001-Resolves-rhbz-1358249-page-up-down.patch @@ -4,7 +4,7 @@ 1 file changed, 2 insertions(+), 2 deletions(-) --- a/shell/ev-application.c +++ a/shell/ev-application.c -@@ -1066,8 +1066,8 @@ ev_application_startup (GApplication *gapplication) +@@ -1044,8 +1044,8 @@ ev_application_startup (GApplication *gapplication) "win.select-page", "L", NULL, "win.go-backwards", "Page_Up", NULL, "win.go-forward", "Page_Down", NULL, @@ -12,7 +12,7 @@ - "win.go-previous-page", "p", NULL, + "win.go-next-page", "n", "Page_Down", NULL, + "win.go-previous-page", "p", "Page_Up", NULL, - "win.go-back-history", "P", NULL, - "win.go-forward-history", "N", NULL, + "win.go-back-history", "P", "Back", NULL, + "win.go-forward-history", "N", "Forward", NULL, "win.sizing-mode::fit-page", "f", NULL, -- diff --git a/SOURCES/0001-Resolves-rhbz-1404656-crash-on-opening-second-evince.patch b/SOURCES/0001-Resolves-rhbz-1404656-crash-on-opening-second-evince.patch deleted file mode 100644 index 7fae308..0000000 --- a/SOURCES/0001-Resolves-rhbz-1404656-crash-on-opening-second-evince.patch +++ /dev/null @@ -1,77 +0,0 @@ -From ca83dd9054abdaae93308f27bdf927e050230027 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= -Date: Tue, 10 Jan 2017 12:04:58 +0000 -Subject: [PATCH] Resolves: rhbz#1404656 crash on opening second evince window - -e.g. - -export G_SLICE=always-malloc -open https://www.antennahouse.com/XSLsample/pdf/sample-link_1.pdf -right click on the first link and open in new window -close the new window -repeat -crash - -This is similar to https://bugzilla.gnome.org/show_bug.cgi?id=726812 ---- - shell/ev-window.c | 34 ++++++++++++++++++++++++---------- - 1 file changed, 24 insertions(+), 10 deletions(-) - -diff --git a/shell/ev-window.c b/shell/ev-window.c -index 11f2fd5..a648ed7 100644 ---- a/shell/ev-window.c -+++ b/shell/ev-window.c -@@ -6666,10 +6666,32 @@ _gtk_css_provider_load_from_resource (GtkCssProvider *provider, - } - - static void -+ev_window_init_css (void) -+{ -+ static gsize initialization_value = 0; -+ -+ if (g_once_init_enter (&initialization_value)) { -+ GtkCssProvider *css_provider; -+ GError *error = NULL; -+ -+ css_provider = gtk_css_provider_new (); -+ _gtk_css_provider_load_from_resource (css_provider, -+ "/org/gnome/evince/ui/evince.css", -+ &error); -+ g_assert_no_error (error); -+ gtk_style_context_add_provider_for_screen (gdk_screen_get_default (), -+ GTK_STYLE_PROVIDER (css_provider), -+ GTK_STYLE_PROVIDER_PRIORITY_APPLICATION); -+ g_object_unref (css_provider); -+ -+ g_once_init_leave (&initialization_value, 1); -+ } -+} -+ -+static void - ev_window_init (EvWindow *ev_window) - { - GtkBuilder *builder; -- GtkCssProvider *css_provider; - GError *error = NULL; - GtkWidget *sidebar_widget; - GtkWidget *overlay; -@@ -6748,15 +6770,7 @@ ev_window_init (EvWindow *ev_window) - actions, G_N_ELEMENTS (actions), - ev_window); - -- css_provider = gtk_css_provider_new (); -- _gtk_css_provider_load_from_resource (css_provider, -- "/org/gnome/evince/ui/evince.css", -- &error); -- g_assert_no_error (error); -- gtk_style_context_add_provider_for_screen (gtk_widget_get_screen (GTK_WIDGET (ev_window)), -- GTK_STYLE_PROVIDER (css_provider), -- GTK_STYLE_PROVIDER_PRIORITY_APPLICATION); -- g_object_unref (css_provider); -+ ev_window_init_css (); - - ev_window->priv->recent_manager = gtk_recent_manager_get_default (); - --- -2.9.3 - diff --git a/SOURCES/0001-comics-Remove-support-for-tar-and-tar-like-commands.patch b/SOURCES/0001-comics-Remove-support-for-tar-and-tar-like-commands.patch deleted file mode 100644 index a547ba1..0000000 --- a/SOURCES/0001-comics-Remove-support-for-tar-and-tar-like-commands.patch +++ /dev/null @@ -1,131 +0,0 @@ -From 717df38fd8509bf883b70d680c9b1b3cf36732ee Mon Sep 17 00:00:00 2001 -From: Bastien Nocera -Date: Thu, 6 Jul 2017 20:02:00 +0200 -Subject: [PATCH] comics: Remove support for tar and tar-like commands - -When handling tar files, or using a command with tar-compatible syntax, -to open comic-book archives, both the archive name (the name of the -comics file) and the filename (the name of a page within the archive) -are quoted to not be interpreted by the shell. - -But the filename is completely with the attacker's control and can start -with "--" which leads to tar interpreting it as a command line flag. - -This can be exploited by creating a CBT file (a tar archive with the -.cbt suffix) with an embedded file named something like this: -"--checkpoint-action=exec=bash -c 'touch ~/hacked;'.jpg" - -CBT files are infinitely rare (CBZ is usually used for DRM-free -commercial releases, CBR for those from more dubious provenance), so -removing support is the easiest way to avoid the bug triggering. All -this code was rewritten in the development release for GNOME 3.26 to not -shell out to any command, closing off this particular attack vector. - -This also removes the ability to use libarchive's bsdtar-compatible -binary for CBZ (ZIP), CB7 (7zip), and CBR (RAR) formats. The first two -are already supported by unzip and 7zip respectively. libarchive's RAR -support is limited, so unrar is a requirement anyway. - -Discovered by Felix Wilhelm from the Google Security Team. - -https://bugzilla.gnome.org/show_bug.cgi?id=784630 ---- - backend/comics/comics-document.c | 40 +--------------------------------------- - configure.ac | 2 +- - 2 files changed, 2 insertions(+), 40 deletions(-) - -diff --git a/backend/comics/comics-document.c b/backend/comics/comics-document.c -index 4c747310..641d7856 100644 ---- a/backend/comics/comics-document.c -+++ b/backend/comics/comics-document.c -@@ -56,8 +56,7 @@ typedef enum - RARLABS, - GNAUNRAR, - UNZIP, -- P7ZIP, -- TAR -+ P7ZIP - } ComicBookDecompressType; - - typedef struct _ComicsDocumentClass ComicsDocumentClass; -@@ -117,9 +116,6 @@ static const ComicBookDecompressCommand command_usage_def[] = { - - /* 7zip */ - {NULL , "%s l -- %s" , "%s x -y %s -o%s", FALSE, OFFSET_7Z}, -- -- /* tar */ -- {"%s -xOf" , "%s -tf %s" , NULL , FALSE, NO_OFFSET} - }; - - static GSList* get_supported_image_extensions (void); -@@ -364,13 +360,6 @@ comics_check_decompress_command (gchar *mime_type, - comics_document->command_usage = GNAUNRAR; - return TRUE; - } -- comics_document->selected_command = -- g_find_program_in_path ("bsdtar"); -- if (comics_document->selected_command) { -- comics_document->command_usage = TAR; -- return TRUE; -- } -- - } else if (g_content_type_is_a (mime_type, "application/x-cbz") || - g_content_type_is_a (mime_type, "application/zip")) { - /* InfoZIP's unzip program */ -@@ -396,12 +385,6 @@ comics_check_decompress_command (gchar *mime_type, - comics_document->command_usage = P7ZIP; - return TRUE; - } -- comics_document->selected_command = -- g_find_program_in_path ("bsdtar"); -- if (comics_document->selected_command) { -- comics_document->command_usage = TAR; -- return TRUE; -- } - - } else if (g_content_type_is_a (mime_type, "application/x-cb7") || - g_content_type_is_a (mime_type, "application/x-7z-compressed")) { -@@ -425,27 +408,6 @@ comics_check_decompress_command (gchar *mime_type, - comics_document->command_usage = P7ZIP; - return TRUE; - } -- comics_document->selected_command = -- g_find_program_in_path ("bsdtar"); -- if (comics_document->selected_command) { -- comics_document->command_usage = TAR; -- return TRUE; -- } -- } else if (g_content_type_is_a (mime_type, "application/x-cbt") || -- g_content_type_is_a (mime_type, "application/x-tar")) { -- /* tar utility (Tape ARchive) */ -- comics_document->selected_command = -- g_find_program_in_path ("tar"); -- if (comics_document->selected_command) { -- comics_document->command_usage = TAR; -- return TRUE; -- } -- comics_document->selected_command = -- g_find_program_in_path ("bsdtar"); -- if (comics_document->selected_command) { -- comics_document->command_usage = TAR; -- return TRUE; -- } - } else { - g_set_error (error, - EV_DOCUMENT_ERROR, -diff --git a/configure.ac b/configure.ac -index 9e9f8316..7eb0f1f3 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -795,7 +795,7 @@ AC_SUBST(TIFF_MIME_TYPES) - AC_SUBST(APPDATA_TIFF_MIME_TYPES) - AM_SUBST_NOTMAKE(APPDATA_TIFF_MIME_TYPES) - if test "x$enable_comics" = "xyes"; then -- COMICS_MIME_TYPES="application/x-cbr;application/x-cbz;application/x-cb7;application/x-cbt;application/x-ext-cbr;application/x-ext-cbz;application/vnd.comicbook+zip;application/x-ext-cb7;application/x-ext-cbt" -+ COMICS_MIME_TYPES="application/x-cbr;application/x-cbz;application/x-cb7;application/x-ext-cbr;application/x-ext-cbz;application/vnd.comicbook+zip;application/x-ext-cb7" - APPDATA_COMICS_MIME_TYPES=$(echo "$COMICS_MIME_TYPES" | sed -e 's/;/<\/mimetype>\n /g') - if test -z "$EVINCE_MIME_TYPES"; then - EVINCE_MIME_TYPES="${COMICS_MIME_TYPES}" --- -2.13.0 - diff --git a/SOURCES/0001-gnome-692552-don-t-complain-about-inability-to-copy-.patch b/SOURCES/0001-gnome-692552-don-t-complain-about-inability-to-copy-.patch deleted file mode 100644 index 16e4d7b..0000000 --- a/SOURCES/0001-gnome-692552-don-t-complain-about-inability-to-copy-.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 15e7b658315d0a9254e5c2ff7fcc1a15a15dceef Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= -Date: Fri, 9 Dec 2016 12:09:02 +0000 -Subject: [PATCH] gnome#692552 don't complain about inability to copy metadata - -related rhbz#1022649 - -nautilus just takes the view that copying metadata is a "nice to have", -but if it doesn't work it's not a hard error so just do that ---- - libview/ev-jobs.c | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/libview/ev-jobs.c b/libview/ev-jobs.c -index dea5aa4..f24808b 100644 ---- a/libview/ev-jobs.c -+++ b/libview/ev-jobs.c -@@ -1574,8 +1574,10 @@ ev_job_save_run (EvJob *job) - ev_tmp_uri_unlink (local_uri); - - /* Copy the metadata from the original file */ -- if (!error) -- ev_file_copy_metadata (job_save->document_uri, job_save->uri, &error); -+ if (!error) { -+ /* Ignore errors here. Failure to copy metadata is not a hard error */ -+ ev_file_copy_metadata (job_save->document_uri, job_save->uri, NULL); -+ } - - if (error) { - ev_job_failed_from_error (job, error); --- -2.9.3 - diff --git a/SOURCES/0001-sidebar-thumbnails-fix-clunky-scrolling.patch b/SOURCES/0001-sidebar-thumbnails-fix-clunky-scrolling.patch deleted file mode 100644 index f1cb117..0000000 --- a/SOURCES/0001-sidebar-thumbnails-fix-clunky-scrolling.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 6480c7039bdf7e8f15f7d1415460db255910c40b Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Nelson=20Ben=C3=ADtez=20Le=C3=B3n?= - -Date: Sun, 28 May 2017 22:35:05 +0500 -Subject: [PATCH] sidebar-thumbnails: fix clunky scrolling - -Caused by GtkIconView doing an invalidate and relayout of *all* -items in the view anytime we update model data in any indiviual -item (which happens with all the items that are getting in and out -of the scrolling area while we scroll). This caused GtkIconView to -machine-gunned us with "size-allocate" signals, a signal we were -using to update thumbnails when the sidebar is resized. - -Fixed by connecting to the GtkTreeModel "row-changed" signal before -GtkIconView does it, and stop emission from there. - -As we don't depend now on "size-allocate" signals to show thumbnails -while we scroll, just queue a draw on the icon view when a -thumbnail finish rendering. - -Thanks Jose Aliste for first spotting the problem. - -https://bugzilla.gnome.org/show_bug.cgi?id=691448 ---- - shell/ev-sidebar-thumbnails.c | 24 ++++++++++++++++++++++++ - 1 file changed, 24 insertions(+) - -diff --git a/shell/ev-sidebar-thumbnails.c b/shell/ev-sidebar-thumbnails.c -index 253eabf..c22e92e 100644 ---- a/shell/ev-sidebar-thumbnails.c -+++ b/shell/ev-sidebar-thumbnails.c -@@ -802,9 +802,26 @@ ev_sidebar_thumbnails_device_scale_factor_changed_cb (EvSidebarThumbnails *sideb - } - - static void -+ev_sidebar_thumbnails_row_changed (GtkTreeModel *model, -+ GtkTreePath *path, -+ GtkTreeIter *iter, -+ gpointer data) -+{ -+ guint signal_id; -+ -+ signal_id = GPOINTER_TO_UINT (data); -+ -+ /* PREVENT GtkIconView "row-changed" handler to be reached, as it will -+ * perform a full invalidate and relayout of all items, See bug: -+ * https://bugzilla.gnome.org/show_bug.cgi?id=691448#c9 */ -+ g_signal_stop_emission (model, signal_id, 0); -+} -+ -+static void - ev_sidebar_thumbnails_init (EvSidebarThumbnails *ev_sidebar_thumbnails) - { - EvSidebarThumbnailsPrivate *priv; -+ guint signal_id; - - priv = ev_sidebar_thumbnails->priv = EV_SIDEBAR_THUMBNAILS_GET_PRIVATE (ev_sidebar_thumbnails); - -@@ -814,6 +831,11 @@ ev_sidebar_thumbnails_init (EvSidebarThumbnails *ev_sidebar_thumbnails) - G_TYPE_BOOLEAN, - EV_TYPE_JOB_THUMBNAIL); - -+ signal_id = g_signal_lookup ("row-changed", GTK_TYPE_TREE_MODEL); -+ g_signal_connect (GTK_TREE_MODEL (priv->list_store), "row-changed", -+ G_CALLBACK (ev_sidebar_thumbnails_row_changed), -+ GUINT_TO_POINTER (signal_id)); -+ - priv->swindow = gtk_scrolled_window_new (NULL, NULL); - - gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (priv->swindow), -@@ -962,6 +984,8 @@ thumbnail_job_completed_callback (EvJobThumbnail *job, - COLUMN_JOB, NULL, - -1); - cairo_surface_destroy (surface); -+ -+ gtk_widget_queue_draw (priv->icon_view); - } - - static void --- -2.9.4 - diff --git a/SOURCES/evince-3.28.2-application-id.patch b/SOURCES/evince-3.28.2-application-id.patch new file mode 100644 index 0000000..6b61d75 --- /dev/null +++ b/SOURCES/evince-3.28.2-application-id.patch @@ -0,0 +1,36 @@ +From 9363553a3087c7dbfa93e1d342283600ceb5993b Mon Sep 17 00:00:00 2001 +From: Marek Kasik +Date: Fri, 22 Jun 2018 17:00:20 +0200 +Subject: shell: Set application-id + +Set "application-id" property for evince's GApplication +to "org.gnome.evince.Application". +An assertion warning is shown in shell if it is not set. + +Even though we use G_APPLICATION_NON_UNIQUE, the application +ID is still required. See: +https://bugzilla.gnome.org/show_bug.cgi?id=646985#c2 + +Closes: https://gitlab.gnome.org/GNOME/evince/issues/918 + +diff --git a/shell/ev-application.c b/shell/ev-application.c +index 7d546933..f173d7a4 100644 +--- a/shell/ev-application.c ++++ b/shell/ev-application.c +@@ -65,6 +65,7 @@ struct _EvApplicationClass { + G_DEFINE_TYPE (EvApplication, ev_application, GTK_TYPE_APPLICATION) + + #ifdef ENABLE_DBUS ++#define APPLICATION_DBUS_NAME "org.gnome.evince.Application" + #define APPLICATION_DBUS_OBJECT_PATH "/org/gnome/evince/Evince" + #define APPLICATION_DBUS_INTERFACE "org.gnome.evince.Application" + +@@ -102,7 +103,7 @@ ev_application_new (void) + const GApplicationFlags flags = G_APPLICATION_NON_UNIQUE; + + return g_object_new (EV_TYPE_APPLICATION, +- "application-id", NULL, ++ "application-id", APPLICATION_DBUS_NAME, + "flags", flags, + NULL); + } diff --git a/SOURCES/evince-3.28.2-libarchive-3.1.2.patch b/SOURCES/evince-3.28.2-libarchive-3.1.2.patch new file mode 100644 index 0000000..a505daf --- /dev/null +++ b/SOURCES/evince-3.28.2-libarchive-3.1.2.patch @@ -0,0 +1,40 @@ +--- evince-3.28.2/backend/comics/ev-archive.c ++++ evince-3.28.2/backend/comics/ev-archive.c +@@ -55,7 +55,7 @@ ev_archive_finalize (GObject *object) + case EV_ARCHIVE_TYPE_ZIP: + case EV_ARCHIVE_TYPE_7Z: + case EV_ARCHIVE_TYPE_TAR: +- g_clear_pointer (&archive->libar, archive_free); ++ g_clear_pointer (&archive->libar, archive_read_free); + break; + default: + break; +@@ -278,7 +278,7 @@ ev_archive_get_entry_is_encrypted (EvArc + case EV_ARCHIVE_TYPE_7Z: + case EV_ARCHIVE_TYPE_TAR: + g_return_val_if_fail (archive->libar_entry != NULL, -1); +- return archive_entry_is_encrypted (archive->libar_entry); ++ return FALSE; + } + + return FALSE; +@@ -336,7 +343,7 @@ ev_archive_reset (EvArchive *archive) + case EV_ARCHIVE_TYPE_ZIP: + case EV_ARCHIVE_TYPE_7Z: + case EV_ARCHIVE_TYPE_TAR: +- g_clear_pointer (&archive->libar, archive_free); ++ g_clear_pointer (&archive->libar, archive_read_free); + libarchive_set_archive_type (archive, archive->type); + break; + default: +--- evince-3.28.2/configure.ac ++++ evince-3.28.2/configure.ac +@@ -698,7 +698,7 @@ AC_ARG_ENABLE(comics, + [enable_comics=yes]) + + if test "x$enable_comics" = "xyes"; then +- LIBARCHIVE_REQUIRED=3.2.0 ++ LIBARCHIVE_REQUIRED=3.1.2 + PKG_CHECK_MODULES(LIBARCHIVE, libarchive >= $LIBARCHIVE_REQUIRED,enable_comics=yes,enable_comics=no) + + if test "x$enable_comics" = "xyes"; then diff --git a/SOURCES/evince-3.28.2-media-player-keys.patch b/SOURCES/evince-3.28.2-media-player-keys.patch new file mode 100644 index 0000000..c54f8ec --- /dev/null +++ b/SOURCES/evince-3.28.2-media-player-keys.patch @@ -0,0 +1,58 @@ +--- a/shell/ev-media-player-keys.c ++++ b/shell/ev-media-player-keys.c +@@ -41,8 +41,9 @@ struct _EvMediaPlayerKeys + { + GObject parent; + +- GDBusProxy *proxy; +- gboolean has_name_owner; ++ GDBusProxy *proxy; ++ gboolean has_name_owner; ++ GCancellable *cancellable; + }; + + struct _EvMediaPlayerKeysClass +@@ -163,7 +164,7 @@ mediakeys_service_appeared_cb (GObject *source_object, + GAsyncResult *res, + gpointer user_data) + { +- EvMediaPlayerKeys *keys = EV_MEDIA_PLAYER_KEYS (user_data); ++ EvMediaPlayerKeys *keys; + GDBusProxy *proxy; + + proxy = g_dbus_proxy_new_for_bus_finish (res, NULL); +@@ -172,6 +173,7 @@ mediakeys_service_appeared_cb (GObject *source_object, + return; + } + ++ keys = EV_MEDIA_PLAYER_KEYS (user_data); + g_signal_connect (proxy, "g-signal", + G_CALLBACK (media_player_key_pressed_cb), + keys); +@@ -187,13 +189,15 @@ mediakeys_service_appeared_cb (GObject *source_object, + static void + ev_media_player_keys_init (EvMediaPlayerKeys *keys) + { ++ keys->cancellable = g_cancellable_new (); ++ + g_dbus_proxy_new_for_bus (G_BUS_TYPE_SESSION, + G_DBUS_PROXY_FLAGS_DO_NOT_LOAD_PROPERTIES, + NULL, + SD_NAME, + SD_OBJECT_PATH, + SD_INTERFACE, +- NULL, ++ keys->cancellable, + mediakeys_service_appeared_cb, + keys); + } +@@ -212,6 +216,9 @@ ev_media_player_keys_finalize (GObject *object) + { + EvMediaPlayerKeys *keys = EV_MEDIA_PLAYER_KEYS (object); + ++ g_cancellable_cancel (keys->cancellable); ++ g_object_unref (keys->cancellable); ++ + if (keys->proxy != NULL) { + ev_media_player_keys_release_keys (keys); + g_object_unref (keys->proxy); diff --git a/SOURCES/evince-3.28.2-signed-size.patch b/SOURCES/evince-3.28.2-signed-size.patch new file mode 100644 index 0000000..4629cb6 --- /dev/null +++ b/SOURCES/evince-3.28.2-signed-size.patch @@ -0,0 +1,40 @@ +--- evince-3.28.2/backend/comics/comics-document.c ++++ evince-3.28.2/backend/comics/comics-document.c +@@ -453,23 +453,27 @@ comics_document_render_pixbuf (EvDocumen + + name = ev_archive_get_entry_pathname (comics_document->archive); + if (g_strcmp0 (name, page_path) == 0) { +- size_t size = ev_archive_get_entry_size (comics_document->archive); ++ gint64 size = ev_archive_get_entry_size (comics_document->archive); + char *buf; + ssize_t read; + +- buf = g_malloc (size); +- read = ev_archive_read_data (comics_document->archive, buf, size, &error); +- if (read <= 0) { +- if (read < 0) { +- g_warning ("Fatal error reading '%s' in archive: %s", name, error->message); +- g_error_free (error); ++ if (size >= 0) { ++ buf = g_malloc (size); ++ read = ev_archive_read_data (comics_document->archive, buf, size, &error); ++ if (read <= 0) { ++ if (read < 0) { ++ g_warning ("Fatal error reading '%s' in archive: %s", name, error->message); ++ g_error_free (error); ++ } else { ++ g_warning ("Read an empty file from the archive"); ++ } + } else { +- g_warning ("Read an empty file from the archive"); ++ gdk_pixbuf_loader_write (loader, (guchar *) buf, size, NULL); + } ++ g_free (buf); + } else { +- gdk_pixbuf_loader_write (loader, (guchar *) buf, size, NULL); ++ g_warning ("Fatal error reading '%s' in archive", name); + } +- g_free (buf); + gdk_pixbuf_loader_close (loader, NULL); + break; + } diff --git a/SPECS/evince.spec b/SPECS/evince.spec index cc7a943..3609bd1 100644 --- a/SPECS/evince.spec +++ b/SPECS/evince.spec @@ -4,28 +4,26 @@ %global gxps_version 0.2.1 Name: evince -Version: 3.22.1 -Release: 7%{?dist} +Version: 3.28.2 +Release: 5%{?dist} Summary: Document viewer License: GPLv2+ and GPLv3+ and LGPLv2+ and MIT and Afmparse URL: https://wiki.gnome.org/Apps/Evince -Source0: https://download.gnome.org/sources/%{name}/3.22/%{name}-%{version}.tar.xz +Source0: https://download.gnome.org/sources/%{name}/3.28/%{name}-%{version}.tar.xz Patch0: evince-3.21.4-NPNVToolKit.patch -#https://bugzilla.gnome.org/show_bug.cgi?id=692552 -Patch1: 0001-gnome-692552-don-t-complain-about-inability-to-copy-.patch -#https://bugzilla.gnome.org/show_bug.cgi?id=777082 -Patch2: 0001-Resolves-rhbz-1404656-crash-on-opening-second-evince.patch -#https://bugzilla.gnome.org/show_bug.cgi?id=766749 +# https://bugzilla.gnome.org/show_bug.cgi?id=766749 Patch3: 0001-Resolves-deb-762530-rhbz-1061177-add-man-pages.patch Patch4: 0001-Resolves-rhbz-1358249-page-up-down.patch -Patch5: 0001-Revert-Bump-poppler-requirements-to-0.33.0.patch -# https://bugzilla.redhat.com/show_bug.cgi?id=1468488 -# https://bugzilla.redhat.com/show_bug.cgi?id=1469529 -Patch6: 0001-comics-Remove-support-for-tar-and-tar-like-commands.patch -# https://bugzilla.redhat.com/show_bug.cgi?id=1462778 -Patch7: 0001-sidebar-thumbnails-fix-clunky-scrolling.patch +Patch6: 0001-Revert-Bump-poppler-requirements-to-0.33.0.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1359507 +Patch7: evince-3.28.2-media-player-keys.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1567186 +Patch8: evince-3.28.2-libarchive-3.1.2.patch +Patch9: evince-3.28.2-signed-size.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1593244 +Patch10: evince-3.28.2-application-id.patch BuildRequires: pkgconfig(adwaita-icon-theme) BuildRequires: pkgconfig(gio-unix-2.0) >= %{glib2_version} @@ -36,6 +34,7 @@ BuildRequires: pkgconfig(libsecret-1) BuildRequires: pkgconfig(libspectre) BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(poppler-glib) >= %{poppler_version} +BuildRequires: pkgconfig(libarchive) BuildRequires: libtiff-devel BuildRequires: gettext BuildRequires: libtool @@ -111,6 +110,7 @@ This package contains a backend to let evince display djvu files. %package nautilus Summary: Evince extension for nautilus Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: evince-libs%{?_isa} = %{version}-%{release} Requires: nautilus%{?_isa} %description nautilus @@ -121,6 +121,7 @@ It adds an additional tab called "Document" to the file properties dialog. %package browser-plugin Summary: Evince web browser plugin Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: evince-libs%{?_isa} = %{version}-%{release} Requires: mozilla-filesystem %description browser-plugin @@ -128,15 +129,7 @@ This package contains the evince web browser plugin. %prep -%setup -q -%patch0 -p1 -b .NPNVToolKit -%patch1 -p1 -b .gnome-692552 -%patch2 -p1 -b .rhbz-1404656 -%patch3 -p1 -b .deb-762530-rhbz -%patch4 -p1 -b .rhbz-1358249-page-up-down -%patch5 -p1 -b .poppler-requirements -%patch6 -p1 -b .no-tar -%patch7 -p1 -b .fix-clunky-scrolling +%autosetup -p1 %build autoreconf -f -i @@ -162,7 +155,7 @@ make %{?_smp_mflags} V=1 LIBTOOL=/usr/bin/libtool # # See http://people.freedesktop.org/~hughsient/appdata/#screenshots for more details. # -appstream-util replace-screenshots $RPM_BUILD_ROOT%{_datadir}/appdata/evince.appdata.xml \ +appstream-util replace-screenshots $RPM_BUILD_ROOT%{_datadir}/metainfo/evince.appdata.xml \ https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/evince/a.png %find_lang evince --with-gnome @@ -204,7 +197,6 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %files -f evince.lang %{_bindir}/* %{_datadir}/%{name}/ -%{_datadir}/appdata/evince.appdata.xml %{_datadir}/applications/%{name}.desktop %{_datadir}/applications/evince-previewer.desktop %{_datadir}/icons/hicolor/*/apps/evince.* @@ -214,6 +206,7 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %{_datadir}/dbus-1/services/org.gnome.evince.Daemon.service %{_datadir}/glib-2.0/schemas/org.gnome.Evince.gschema.xml %{_datadir}/GConf/gsettings/evince.convert +%{_datadir}/metainfo/evince.appdata.xml %{_datadir}/thumbnailers/evince.thumbnailer %{_userunitdir}/evince.service @@ -227,23 +220,23 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %dir %{_libdir}/evince/4/backends %{_libdir}/evince/4/backends/libpdfdocument.so %{_libdir}/evince/4/backends/pdfdocument.evince-backend -%{_datadir}/appdata/evince-pdfdocument.metainfo.xml +%{_datadir}/metainfo/evince-pdfdocument.metainfo.xml %{_libdir}/evince/4/backends/libpsdocument.so %{_libdir}/evince/4/backends/psdocument.evince-backend -%{_datadir}/appdata/evince-psdocument.metainfo.xml +%{_datadir}/metainfo/evince-psdocument.metainfo.xml %{_libdir}/evince/4/backends/libtiffdocument.so %{_libdir}/evince/4/backends/tiffdocument.evince-backend -%{_datadir}/appdata/evince-tiffdocument.metainfo.xml +%{_datadir}/metainfo/evince-tiffdocument.metainfo.xml %{_libdir}/evince/4/backends/libcomicsdocument.so %{_libdir}/evince/4/backends/comicsdocument.evince-backend -%{_datadir}/appdata/evince-comicsdocument.metainfo.xml +%{_datadir}/metainfo/evince-comicsdocument.metainfo.xml %{_libdir}/evince/4/backends/libxpsdocument.so %{_libdir}/evince/4/backends/xpsdocument.evince-backend -%{_datadir}/appdata/evince-xpsdocument.metainfo.xml +%{_datadir}/metainfo/evince-xpsdocument.metainfo.xml %{_libdir}/girepository-1.0/EvinceDocument-3.0.typelib %{_libdir}/girepository-1.0/EvinceView-3.0.typelib @@ -264,13 +257,13 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %files dvi %{_libdir}/evince/4/backends/libdvidocument.so* %{_libdir}/evince/4/backends/dvidocument.evince-backend -%{_datadir}/appdata/evince-dvidocument.metainfo.xml +%{_datadir}/metainfo/evince-dvidocument.metainfo.xml %if 0%{?fedora} %files djvu %{_libdir}/evince/4/backends/libdjvudocument.so %{_libdir}/evince/4/backends/djvudocument.evince-backend -%{_datadir}/appdata/evince-djvudocument.metainfo.xml +%{_datadir}/metainfo/evince-djvudocument.metainfo.xml %endif %files nautilus @@ -280,6 +273,28 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas >&/dev/null ||: %{_libdir}/mozilla/plugins/libevbrowserplugin.so %changelog +* Tue Jul 24 2018 Marek Kasik - 3.28.2-5 +- Set application-id for evince +- Resolves: #1593244 + +* Fri Jun 15 2018 Marek Kasik - 3.28.2-4 +- Change requires as requested by RPMDiff +- Check returned size for negative value (CovScan) +- Resolves: #1567186 + +* Fri Jun 15 2018 Marek Kasik - 3.28.2-3 +- Fix patch fixing crash in EvMediaPlayerKeys +- Fix building of comics backend with libarchive 3.1.2 +- Resolves: #1567186 + +* Wed May 9 2018 Marek Kasik - 3.28.2-2 +- Fix crash in EvMediaPlayerKeys +- Resolves: #1359507 + +* Tue Apr 10 2018 Kalev Lember - 3.28.2-1 +- Update to 3.28.2 +- Resolves: #1567186 + * Mon Aug 14 2017 Caolán McNamara - 3.22.1-7 - Resolves: rhbz#1462778 Page thumbnails disappear after "Inverted Colors"