From a0af72840dc65df31abd346f5d96f1c8b5d35947 Mon Sep 17 00:00:00 2001 From: Bernhard M. Wiedemann Date: Mar 10 2020 14:55:27 +0000 Subject: Update alacarte to rev 65 via SR 783422 https://build.opensuse.org/request/show/783422 by user iznogood + dimstar_suse - Update to version 3.36.0: + Require Python 3.2+. - Update to version 3.35.91: + Fix bad command validation. + Require Python 3.0+. + Support Python 3.8+. - Drop fix-bad-command-validation.patch and alacarte-python3.patch: fixed upstream. - Drop autoconf and automake BuildRequires, and no longer call autoreconf: no patch touches the build system. - Rebase alacarte-trans.patch. - Drop deprecated use of %desktop_database_post/postun and -%icon_theme_cache_post/postun macros. --- diff --git a/.files b/.files index f5df9f9..12acfab 100644 Binary files a/.files and b/.files differ diff --git a/.rev b/.rev index 3c406fb..ace8c31 100644 --- a/.rev +++ b/.rev @@ -479,4 +479,25 @@ Eliminate the -lang recommends (forwarded request 767095 from dimstar) 767336 + + ac1c30de3dedcc40d8f5c850b481aa93 + 3.36.0 + + dimstar_suse + - Update to version 3.36.0: + + Require Python 3.2+. +- Update to version 3.35.91: + + Fix bad command validation. + + Require Python 3.0+. + + Support Python 3.8+. +- Drop fix-bad-command-validation.patch and alacarte-python3.patch: + fixed upstream. +- Drop autoconf and automake BuildRequires, and no longer call + autoreconf: no patch touches the build system. +- Rebase alacarte-trans.patch. +- Drop deprecated use of %desktop_database_post/postun and + -%icon_theme_cache_post/postun macros. + + 783422 + diff --git a/alacarte-3.11.91.tar.xz b/alacarte-3.11.91.tar.xz deleted file mode 120000 index c525a2c..0000000 --- a/alacarte-3.11.91.tar.xz +++ /dev/null @@ -1 +0,0 @@ -/ipfs/bafkreigxokkpewwj4tzjguyaqbly3a64ryau2w34nqa5n6nh6fyvogndqq \ No newline at end of file diff --git a/alacarte-3.36.0.tar.xz b/alacarte-3.36.0.tar.xz new file mode 120000 index 0000000..ffb16ec --- /dev/null +++ b/alacarte-3.36.0.tar.xz @@ -0,0 +1 @@ +/ipfs/bafkreic4dye2retky55ajgyztsl2yrm7tctfqfqed7vtsledtki63shhlu \ No newline at end of file diff --git a/alacarte-python3.patch b/alacarte-python3.patch deleted file mode 100644 index 094ac3c..0000000 --- a/alacarte-python3.patch +++ /dev/null @@ -1,75 +0,0 @@ -From b2af67fd6bc6667343f3850ce981f51af0f5c155 Mon Sep 17 00:00:00 2001 -From: e < �h�U> -Date: Sat, 9 Sep 2017 19:59:06 -0500 -Subject: [PATCH] util.py and acinclude.m4: Support Python 3 - ---- - .gitignore | 2 ++ - Alacarte/util.py | 7 +++++++ - acinclude.m4 | 4 ++-- - 3 files changed, 11 insertions(+), 2 deletions(-) - -diff --git a/Alacarte/util.py b/Alacarte/util.py -index 0d98d56..3bbb943 100644 ---- a/Alacarte/util.py -+++ b/Alacarte/util.py -@@ -24,6 +24,13 @@ import gi - gi.require_version('Gtk', '3.0') - from gi.repository import Gtk, GdkPixbuf, GMenu, GLib - -+# Python 2/3 compatibility -+try: -+ basestring -+except NameError: -+ # Must be python3 -+ basestring = (str, bytes) -+ - DESKTOP_GROUP = GLib.KEY_FILE_DESKTOP_GROUP - KEY_FILE_FLAGS = GLib.KeyFileFlags.KEEP_COMMENTS | GLib.KeyFileFlags.KEEP_TRANSLATIONS - -diff --git a/acinclude.m4 b/acinclude.m4 -index 372e0b2..b6eaa4f 100644 ---- a/acinclude.m4 -+++ b/acinclude.m4 -@@ -69,7 +69,7 @@ AC_DEFUN([AM_PATH_PYTHON_VERSION], - dnl library. - - AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version], -- [am_cv_python_version=`$PYTHON -c "import sys; print sys.version[[:3]]"`]) -+ [am_cv_python_version=`$PYTHON -c "import sys; print(sys.version[[:3]])"`]) - AC_SUBST([PYTHON_VERSION], [$am_cv_python_version]) - - dnl Use the values of $prefix and $exec_prefix for the corresponding -@@ -84,7 +84,7 @@ AC_DEFUN([AM_PATH_PYTHON_VERSION], - dnl to know which OS platform Python thinks this is. - - AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform], -- [am_cv_python_platform=`$PYTHON -c "import sys; print sys.platform"`]) -+ [am_cv_python_platform=`$PYTHON -c "import sys; print(sys.platform)"`]) - AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform]) - - -diff -urp alacarte-3.11.91.orig/configure.ac alacarte-3.11.91/configure.ac ---- alacarte-3.11.91.orig/configure.ac 2014-03-03 07:01:44.000000000 -0600 -+++ alacarte-3.11.91/configure.ac 2018-01-14 21:03:34.122761459 -0600 -@@ -18,7 +18,7 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GE - AM_GLIB_GNU_GETTEXT - IT_PROG_INTLTOOL([0.40.0]) - --AM_PATH_PYTHON_VERSION(2.7, 2.7.0, 2.6, 2.6.0, 2.5, 2.5.0, 2.4, 2.4.0) -+AM_PATH_PYTHON_VERSION(3.7, 3.7.0, 3.6, 3.6.0, 2.7, 2.7.0, 2.6, 2.6.0, 2.5, 2.5.0, 2.4, 2.4.0) - - PKG_CHECK_MODULES(ALACARTE, libgnome-menu-3.0 >= 3.5.3 pygobject-3.0) - -diff -urp alacarte-3.11.91.orig/Alacarte/MainWindow.py alacarte-3.11.91/Alacarte/MainWindow.py ---- alacarte-3.11.91.orig/Alacarte/MainWindow.py 2014-02-27 18:30:39.000000000 -0600 -+++ alacarte-3.11.91/Alacarte/MainWindow.py 2018-01-15 13:01:45.176198435 -0600 -@@ -239,7 +239,7 @@ class MainWindow(object): - menu_tree.get_selection().select_path((0,)) - else: - parent = menus[iter][2] -- file_name = util.getUniqueFileId('alacarte-made', '.directory') -+ file_name = util.getUniqueFileId('alacarte-made', '.directory') - file_path = os.path.join(util.getUserDirectoryPath(), file_name) - - editor = DirectoryEditor(self.main_window, file_path) diff --git a/alacarte-trans.patch b/alacarte-trans.patch index 8a76e02..ff073e0 100644 --- a/alacarte-trans.patch +++ b/alacarte-trans.patch @@ -1,7 +1,7 @@ -Index: alacarte-3.11.91/Alacarte/ItemEditor.py +Index: alacarte-3.35.91/Alacarte/ItemEditor.py =================================================================== ---- alacarte-3.11.91.orig/Alacarte/ItemEditor.py -+++ alacarte-3.11.91/Alacarte/ItemEditor.py +--- alacarte-3.35.91.orig/Alacarte/ItemEditor.py ++++ alacarte-3.35.91/Alacarte/ItemEditor.py @@ -22,6 +22,8 @@ import gi gi.require_version('Gtk', '3.0') from gi.repository import GLib, GObject, Gtk @@ -19,16 +19,3 @@ Index: alacarte-3.11.91/Alacarte/ItemEditor.py self.builder.add_from_file(os.path.join(config.pkgdatadir, self.ui_file)) self.dialog = self.builder.get_object('editor') -Index: alacarte-3.11.91/data/alacarte.ui -=================================================================== ---- alacarte-3.11.91.orig/data/alacarte.ui -+++ alacarte-3.11.91/data/alacarte.ui -@@ -70,7 +70,7 @@ - - - -- Restore System Configuration -+ Restore System Configuration - True - True - True diff --git a/alacarte.changes b/alacarte.changes index 0474bc8..b4efa01 100644 --- a/alacarte.changes +++ b/alacarte.changes @@ -1,4 +1,25 @@ ------------------------------------------------------------------- +Thu Mar 5 18:44:30 UTC 2020 - bjorn.lie@gmail.com + +- Update to version 3.36.0: + + Require Python 3.2+. + +------------------------------------------------------------------- +Fri Feb 14 10:46:57 UTC 2020 - Dominique Leuenberger + +- Update to version 3.35.91: + + Fix bad command validation. + + Require Python 3.0+. + + Support Python 3.8+. +- Drop fix-bad-command-validation.patch and alacarte-python3.patch: + fixed upstream. +- Drop autoconf and automake BuildRequires, and no longer call + autoreconf: no patch touches the build system. +- Rebase alacarte-trans.patch. +- Drop deprecated use of %desktop_database_post/postun and + -%icon_theme_cache_post/postun macros. + +------------------------------------------------------------------- Sat Jan 25 14:05:11 UTC 2020 - Dominique Leuenberger - No longer recommend -lang: supplements are in use diff --git a/alacarte.spec b/alacarte.spec index b82da23..6f91af9 100644 --- a/alacarte.spec +++ b/alacarte.spec @@ -1,7 +1,7 @@ # # spec file for package alacarte # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,22 +17,15 @@ Name: alacarte -Version: 3.11.91 +Version: 3.36.0 Release: 0 Summary: Menu editor for GNOME License: LGPL-2.1-or-later Group: System/GUI/GNOME URL: http://www.realistanew.com/projects/alacarte -Source: http://download.gnome.org/sources/alacarte/3.11/%{name}-%{version}.tar.xz +Source: https://download.gnome.org/sources/alacarte/3.36/%{name}-%{version}.tar.xz # PATCH-FIX-OPENSUSE alacarte-trans.patch bnc#947793 qzhao@suse.org -- Fix untranslated messages Patch0: alacarte-trans.patch -# PATCH-FIX-UPSTREAM fix-bad-command-validation.patch bsc#1057908 bgo#728372 qzheng@suse.com -- Fix bad command validation -Patch1: fix-bad-command-validation.patch -# PATCH-FIX-UPSTREAM alacarte-python3.patch bsc#1075771 bgo#787490 mgorse@suse.com -- Support python 3. -Patch2: alacarte-python3.patch -# Needed for Patch2 -BuildRequires: autoconf -BuildRequires: automake BuildRequires: fdupes BuildRequires: glib2-devel # Needed for the typelib() dependency parser @@ -41,7 +34,7 @@ BuildRequires: gobject-introspection BuildRequires: hicolor-icon-theme BuildRequires: intltool BuildRequires: pkgconfig -BuildRequires: python3 +BuildRequires: python3 >= 3.2 BuildRequires: suse-xsl-stylesheets BuildRequires: translation-update-upstream BuildRequires: update-desktop-files @@ -60,12 +53,8 @@ type to edit, add, and delete any menu entry. %setup -q translation-update-upstream %patch0 -p1 -%patch1 -p1 -%patch2 -p1 %build -# needed for Patch2 -autoreconf -fi %configure make %{?_smp_mflags} @@ -75,14 +64,6 @@ make %{?_smp_mflags} %find_lang %{name} %{?no_lang_C} %fdupes %{buildroot} -%post -%desktop_database_post -%icon_theme_cache_post - -%postun -%desktop_database_postun -%icon_theme_cache_postun - %files %license COPYING %doc AUTHORS ChangeLog NEWS README diff --git a/fix-bad-command-validation.patch b/fix-bad-command-validation.patch deleted file mode 100644 index 97d8d4e..0000000 --- a/fix-bad-command-validation.patch +++ /dev/null @@ -1,29 +0,0 @@ -diff --git a/Alacarte/ItemEditor.py b/Alacarte/ItemEditor.py -index 9fd9faa..c5de30c 100644 ---- a/Alacarte/ItemEditor.py -+++ b/Alacarte/ItemEditor.py -@@ -178,14 +178,22 @@ class LauncherEditor(ItemEditor): - self.builder.get_object('icon-image')) - - self.builder.get_object('exec-browse').connect('clicked', self.pick_exec) -- - self.builder.get_object('name-entry').connect('changed', self.resync_validity) - self.builder.get_object('exec-entry').connect('changed', self.resync_validity) - -+ def exec_line_is_valid(self, exec_text): -+ try: -+ success, parsed = GLib.shell_parse_argv(exec_text) -+ # Make sure program (first part of the command) is in the path -+ command = parsed[0] -+ return (GLib.find_program_in_path(command) is not None) -+ except GLib.GError: -+ return False -+ - def resync_validity(self, *args): - name_text = self.builder.get_object('name-entry').get_text() - exec_text = self.builder.get_object('exec-entry').get_text() -- valid = (name_text != "" and GLib.find_program_in_path(exec_text) is not None) -+ valid = (name_text != "" and self.exec_line_is_valid(exec_text)) - self.builder.get_object('ok').set_sensitive(valid) - - def load(self):