From a2c5fdd9e893b0705a291d3281c1448ec3a2aa5b Mon Sep 17 00:00:00 2001 From: Martin Kutlak Date: Jul 12 2019 15:36:43 +0000 Subject: Add patch to fix failing a-a-list-dsos on rawhide Signed-off-by: Martin Kutlak --- diff --git a/0001-a-a-list-dsos-Add-check-for-decode-attribute.patch b/0001-a-a-list-dsos-Add-check-for-decode-attribute.patch new file mode 100644 index 0000000..4fac1dd --- /dev/null +++ b/0001-a-a-list-dsos-Add-check-for-decode-attribute.patch @@ -0,0 +1,54 @@ +From b7ce0f017fd5d98b7c641a2784e9b1c4c9dec834 Mon Sep 17 00:00:00 2001 +From: Martin Kutlak +Date: Fri, 12 Jul 2019 16:44:19 +0200 +Subject: [PATCH] a-a-list-dsos: Add check for decode attribute + +rpm used to return bytes but that was changed to return strings in recent release. + +The check for decode attribute keeps compatibility with older fedora releases. + +This can be removed in the future with rpm 4.15(?) + +Related: rhbz#1693751 +Resolves: rhbz#1694970 + +Signed-off-by: Martin Kutlak +--- + src/plugins/abrt-action-list-dsos | 18 ++++++++++++------ + 1 file changed, 12 insertions(+), 6 deletions(-) + +diff --git a/src/plugins/abrt-action-list-dsos b/src/plugins/abrt-action-list-dsos +index adb228a41..5d1240cb4 100644 +--- a/src/plugins/abrt-action-list-dsos ++++ b/src/plugins/abrt-action-list-dsos +@@ -84,15 +84,21 @@ if __name__ == "__main__": + outname = None + + vendor = h[rpm.RPMTAG_VENDOR] +- if vendor != None: ++ if vendor is not None and hasattr(vendor, 'decode'): + vendor = vendor.decode('utf-8') + ++ rpmtag_nevra = h[rpm.RPMTAG_NEVRA] ++ # FIXME change from bugzilla #1693751 ++ # can be removed with rpm 4.15 ++ if hasattr(rpmtag_nevra, 'decode'): ++ rpmtag_nevra = rpmtag_nevra.decode('utf-8') ++ + outfile.write("%s %s (%s) %s\n" % +- (path, +- h[rpm.RPMTAG_NEVRA].decode('utf-8'), +- vendor, +- h[rpm.RPMTAG_INSTALLTIME]) +- ) ++ (path, ++ rpmtag_nevra, ++ vendor, ++ h[rpm.RPMTAG_INSTALLTIME]) ++ ) + + except Exception as ex: + error_msg_and_die("Can't get the DSO list: %s" % ex) +-- +2.21.0 + diff --git a/abrt.spec b/abrt.spec index 6b46536..ce34b09 100644 --- a/abrt.spec +++ b/abrt.spec @@ -46,10 +46,13 @@ Summary: Automatic bug detection and reporting tool Name: abrt Version: 2.12.1 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2+ URL: https://abrt.readthedocs.org/ Source: https://github.com/abrt/%{name}/archive/%{version}/%{name}-%{version}.tar.gz + +Patch0001: 0001-a-a-list-dsos-Add-check-for-decode-attribute.patch + BuildRequires: git-core BuildRequires: %{dbus_devel} BuildRequires: hostname @@ -1066,6 +1069,9 @@ killall abrt-dbus >/dev/null 2>&1 || : %config(noreplace) %{_sysconfdir}/profile.d/abrt-console-notification.sh %changelog +* Fri Jul 12 2019 Martin Kutlak 2.12.1-2 +- Add patch to fix failing action abrt-action-list-dsos on rawhide + * Wed Jul 03 2019 Martin Kutlak 2.12.1-1 - Translation updates - Rename all abrt-python to python3-abrt