New version 2.10.6

Signed-off-by: Matej Habrnal <mhabrnal@redhat.com>
This commit is contained in:
Matej Habrnal 2018-02-21 16:34:57 +01:00
parent 6b7ef25742
commit e06dcb57e7
5 changed files with 145 additions and 124 deletions

1
.gitignore vendored
View File

@ -57,3 +57,4 @@ abrt-1.1.13.tar.gz
/abrt-2.10.3.tar.gz
/abrt-2.10.4.tar.gz
/abrt-2.10.5.tar.gz
/abrt-2.10.6.tar.gz

View File

@ -0,0 +1,76 @@
From 578317a67c0f30469c28752ea2f40ae87a1a356c Mon Sep 17 00:00:00 2001
From: Matej Habrnal <mhabrnal@redhat.com>
Date: Wed, 21 Feb 2018 16:14:36 +0100
Subject: [PATCH] a-container-logger: workaround permission issue in minishift
This workarounds the following issue:
https://github.com/minishift/minishift/issues/2058
Signed-off-by: Matej Habrnal <mhabrnal@redhat.com>
---
src/plugins/abrt-container-logger.c | 27 +++++++++++++++++++++++----
1 file changed, 23 insertions(+), 4 deletions(-)
diff --git a/src/plugins/abrt-container-logger.c b/src/plugins/abrt-container-logger.c
index 2f9488a3..df40f562 100644
--- a/src/plugins/abrt-container-logger.c
+++ b/src/plugins/abrt-container-logger.c
@@ -15,6 +15,7 @@
#include <stdio.h>
#include <unistd.h>
+#include <sys/types.h>
#define INIT_PROC_STDERR_FD_PATH "/proc/1/fd/2"
@@ -25,7 +26,6 @@ int main(int argc, char *argv[])
"\n"
"\nThe tool reads from standard input and writes to '"INIT_PROC_STDERR_FD_PATH"'";
- /* the tool expects one parameter STR */
if (argc > 1)
{
fprintf(stderr, "%s\n", program_usage_string);
@@ -35,9 +35,27 @@ int main(int argc, char *argv[])
FILE *f = fopen(INIT_PROC_STDERR_FD_PATH, "w");
if (f == NULL)
{
- perror("Failed to open '"INIT_PROC_STDERR_FD_PATH"'");
- return 2;
+ perror("Failed to open '"INIT_PROC_STDERR_FD_PATH"' as root");
+
+ /* Try to open the 'INIT_PROC_STDERR_FD_PATH' as normal user because of
+ https://github.com/minishift/minishift/issues/2058
+ */
+ if (seteuid(getuid()) == 0)
+ {
+ f = fopen(INIT_PROC_STDERR_FD_PATH, "w");
+ if (f == NULL)
+ {
+ perror("Failed to open '"INIT_PROC_STDERR_FD_PATH"' as user");
+ return 2;
+ }
+ }
+ else
+ {
+ perror("Failed to setuid");
+ return 3;
+ }
}
+
setvbuf (f, NULL, _IONBF, 0);
char buffer[BUFSIZ];
@@ -52,7 +70,8 @@ int main(int argc, char *argv[])
if (fwrite(buffer, bytes_read, 1, f) != 1)
{
perror("Failed to write to '"INIT_PROC_STDERR_FD_PATH"'");
- return 3;
+ fclose(f);
+ return 4;
}
}
fclose(f);
--
2.14.3

View File

@ -1,39 +0,0 @@
From 395bbb2cbd9a12ff11068ea29922e1575d4d93b3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bj=C3=B6rn=20Esser?= <besser82@fedoraproject.org>
Date: Sun, 10 Dec 2017 22:59:33 +0100
Subject: [PATCH] Fix build against libjson-c.so.3
---
src/daemon/abrt-action-save-container-data.c | 2 +-
src/plugins/bodhi.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/daemon/abrt-action-save-container-data.c b/src/daemon/abrt-action-save-container-data.c
index 5d8cdb7..9a5bfa4 100644
--- a/src/daemon/abrt-action-save-container-data.c
+++ b/src/daemon/abrt-action-save-container-data.c
@@ -141,7 +141,7 @@ void dump_docker_info(struct dump_dir *dd, const char *root_dir)
json = json_tokener_parse(output);
free(output);
- if (is_error(json))
+ if (json == NULL)
{
error_msg("Unable parse response from docker");
goto dump_docker_info_cleanup;
diff --git a/src/plugins/bodhi.c b/src/plugins/bodhi.c
index 84ed4d8..14d65ad 100644
--- a/src/plugins/bodhi.c
+++ b/src/plugins/bodhi.c
@@ -419,7 +419,7 @@ static GHashTable *bodhi_query_list(const char *query, const char *release)
// log_warning("%s", post_state->body);
json_object *json = json_tokener_parse(post_state->body);
- if (is_error(json))
+ if (json == NULL)
error_msg_and_die("fatal: unable parse response from bodhi server");
/* we must check the http_resp_code because only error responses contain
--
2.15.1

151
abrt.spec
View File

@ -2,21 +2,6 @@
# http://fedoraproject.org/wiki/Hardened_Packages
%global _hardened_build 1
%if 0%{?fedora} >= 14
%bcond_without systemd
%else
%bcond_with systemd
%endif
# systemd wasn't set by the code above - so we're on old Fedora or we're not on Fedora at all
%if %{without systemd}
%if 0%{?rhel} >= 7
%bcond_without systemd
%else
%bcond_with systemd
%endif
%endif
# build abrt-atomic subpackage
%bcond_without atomic
@ -28,19 +13,7 @@
# rpmbuild --define 'desktopvendor mystring'
%if "x%{desktopvendor}" == "x"
%if %{with systemd}
%global desktopvendor %(source /etc/os-release; echo ${ID})
%else
%if 0%{?rhel} >= 6
%global desktopvendor redhat
%else
%if 0%{?suse_version}
%global desktopvendor suse
%else
%global desktopvendor fedora
%endif
%endif
%endif
%define desktopvendor %(source /etc/os-release; echo ${ID})
%endif
# do not append package version to doc directory of subpackages in F20 and later; rhbz#993656
@ -55,19 +28,16 @@
Summary: Automatic bug detection and reporting tool
Name: abrt
Version: 2.10.5
Release: 6%{?dist}
Version: 2.10.6
Release: 2%{?dist}
License: GPLv2+
Group: Applications/System
URL: https://abrt.readthedocs.org/
Source: https://github.com/abrt/%{name}/archive/%{version}/%{name}-%{version}.tar.gz
# Needed for libjson-c.so.3*.
# See: https://github.com/json-c/json-c/issues/304
Patch0: abrt-2.10.5_json-c_013.patch
# git format-patch %%{Version} --topo-order -N -M;
# i=1; for p in `ls 0*.patch`; do printf "Patch%04d: %s\n" $i $p; ((i++)); done
Patch0001: 0001-a-container-logger-workaround-permission-issue-in-mi.patch
# '%%autosetup -S git' -> git
BuildRequires: git
@ -105,9 +75,7 @@ BuildRequires: python3-humanize
Requires: libreport >= %{libreport_ver}
Requires: satyr >= %{satyr_ver}
%if %{with systemd}
Requires: systemd-units
%endif
Requires: %{name}-libs = %{version}-%{release}
Requires: python3-%{name} = %{version}-%{release}
Requires(pre): shadow-utils
@ -117,6 +85,35 @@ Requires: python3-dmidecode
Requires: libreport-plugin-ureport >= %{libreport_ver}
Requires: libreport-plugin-systemd-journal
#gui
BuildRequires: libreport-gtk-devel >= %{libreport_ver}
BuildRequires: gsettings-desktop-schemas-devel >= 3.15
#addon-ccpp
BuildRequires: gdb-headless
BuildRequires: libcap-devel
#addon-kerneloops
BuildRequires: systemd-devel
# plugin-bodhi
BuildRequires: json-c-devel
BuildRequires: libreport-web-devel >= %{libreport_ver}
#desktop
#Default config of addon-ccpp requires gdb
BuildRequires: gdb-headless
#dbus
BuildRequires: polkit-devel
#python2-abrt
BuildRequires: python-nose
BuildRequires: python-sphinx
BuildRequires: libreport-python
#python2-abrt-doc
BuildRequires: python2-devel
#python3-abrt
BuildRequires: python3-nose
BuildRequires: python3-sphinx
BuildRequires: libreport-python3
#python3-abrt-doc
BuildRequires: python3-devel
%description
%{name} is a tool to help users to detect defects in applications and
to create a bug report with all information needed by maintainer to fix it.
@ -159,8 +156,6 @@ Requires: %{name} = %{version}-%{release}
Requires: %{name}-dbus = %{version}-%{release}
Requires: gnome-abrt
Requires: gsettings-desktop-schemas >= 3.15
BuildRequires: libreport-gtk-devel >= %{libreport_ver}
BuildRequires: gsettings-desktop-schemas-devel >= 3.15
# we used to have abrt-applet, now abrt-gui includes it:
Provides: abrt-applet = %{version}-%{release}
Obsoletes: abrt-applet < 0.0.5
@ -183,8 +178,6 @@ This package contains hook for C/C++ crashed programs.
Summary: %{name}'s C/C++ addon
Group: System Environment/Libraries
Requires: cpio
BuildRequires: gdb-headless
BuildRequires: libcap-devel
Requires: gdb-headless
Requires: elfutils
%if 0%{!?rhel:1}
@ -222,7 +215,6 @@ which is able to analyze C/C++ crashes remotely.
%package addon-kerneloops
Summary: %{name}'s kerneloops addon
Group: System Environment/Libraries
BuildRequires: systemd-devel
Requires: curl
Requires: %{name} = %{version}-%{release}
%if 0%{!?rhel:1}
@ -273,10 +265,8 @@ This package contains plugin for collecting kernel oopses from pstore storage.
%package plugin-bodhi
Summary: %{name}'s bodhi plugin
BuildRequires: json-c-devel
Group: System Environment/Libraries
Requires: %{name} = %{version}-%{release}
BuildRequires: libreport-web-devel >= %{libreport_ver}
Obsoletes: libreport-plugin-bodhi > 0.0.1
Provides: libreport-plugin-bodhi = %{version}-%{release}
@ -313,6 +303,14 @@ Obsoletes: abrt-addon-python3 < %{version}-%{release}
This package contains python 3 hook and python analyzer plugin for handling
uncaught exception in python 3 programs.
%package -n python3-abrt-container-addon
Summary: %{name}'s container addon for catching Python 3 exceptions
Conflicts: python3-abrt-addon
%description -n python3-abrt-container-addon
This package contains python 3 hook and handling uncaught exception in python 3
programs in container.
%package plugin-sosreport
Summary: %{name}'s plugin for building automatic sosreports
Requires: sos
@ -407,7 +405,6 @@ Requires: abrt-addon-ccpp
Requires: python3-abrt-addon
Requires: abrt-addon-xorg
# Default config of addon-ccpp requires gdb
BuildRequires: gdb-headless
Requires: gdb-headless
Requires: elfutils
Requires: abrt-gui
@ -446,7 +443,6 @@ hosts.
Summary: ABRT DBus service
Group: Applications/System
Requires: %{name} = %{version}-%{release}
BuildRequires: polkit-devel
Requires: abrt-libs = %{version}-%{release}
%description dbus
@ -468,9 +464,6 @@ Requires: python2-gobject-base
Provides: %{name}-python = %{version}-%{release}
Provides: %{name}-python%{?_isa} = %{version}-%{release}
Obsoletes: %{name}-python < %{version}-%{release}
BuildRequires: python2-nose
BuildRequires: python2-sphinx
BuildRequires: python2-libreport
%description -n python2-abrt
High-level API for querying, creating and manipulating
@ -480,7 +473,6 @@ problems handled by ABRT in Python.
Summary: ABRT Python API Documentation
Group: Documentation
BuildArch: noarch
BuildRequires: python2-devel
Requires: %{name} = %{version}-%{release}
Requires: python2-abrt = %{version}-%{release}
# Remove before F30
@ -504,9 +496,6 @@ Provides: %{name}-python3 = %{version}-%{release}
Provides: %{name}-python3%{?_isa} = %{version}-%{release}
Obsoletes: %{name}-python3 < %{version}-%{release}
Requires: python3-gobject-base
BuildRequires: python3-nose
BuildRequires: python3-sphinx
BuildRequires: libreport-python3
%description -n python3-abrt
High-level API for querying, creating and manipulating
@ -516,7 +505,6 @@ problems handled by ABRT in Python 3.
Summary: ABRT Python API Documentation
Group: Documentation
BuildArch: noarch
BuildRequires: python3-devel
Requires: %{name} = %{version}-%{release}
Requires: python3-%{name} = %{version}-%{release}
# Remove before F30
@ -579,7 +567,6 @@ find $RPM_BUILD_ROOT -name "*.py[co]" -delete
# remove all .la and .a files
find $RPM_BUILD_ROOT -name '*.la' -or -name '*.a' | xargs rm -f
mkdir -p ${RPM_BUILD_ROOT}/%{_initrddir}
mkdir -p $RPM_BUILD_ROOT/var/cache/abrt-di
mkdir -p $RPM_BUILD_ROOT/var/run/abrt
mkdir -p $RPM_BUILD_ROOT/var/spool/abrt
@ -730,6 +717,10 @@ fi
%systemd_postun_with_restart abrt-coredump-helper.service
%endif
%if 0%{?fedora} > 27
# ldconfig and gtk-update-icon-cache is not needed
%else
%post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
@ -737,6 +728,7 @@ fi
%post gui-libs -p /sbin/ldconfig
%postun gui-libs -p /sbin/ldconfig
%endif
%posttrans
service abrtd condrestart >/dev/null 2>&1 || :
@ -793,12 +785,8 @@ killall abrt-dbus >/dev/null 2>&1 || :
%files -f %{name}.lang
%doc README.md COPYING
%if %{with systemd}
%{_unitdir}/abrtd.service
%{_tmpfilesdir}/abrt.conf
%else
%{_initrddir}/abrtd
%endif
%{_sbindir}/abrtd
%{_sbindir}/abrt-server
%{_sbindir}/abrt-auto-reporting
@ -905,12 +893,8 @@ killall abrt-dbus >/dev/null 2>&1 || :
%{_journalcatalogdir}/abrt_ccpp.catalog
%config(noreplace) %{_sysconfdir}/libreport/plugins/catalog_ccpp_format.conf
%config(noreplace) %{_sysconfdir}/libreport/plugins/catalog_journal_ccpp_format.conf
%if %{with systemd}
%{_unitdir}/abrt-ccpp.service
%{_unitdir}/abrt-journal-core.service
%else
%{_initrddir}/abrt-ccpp
%endif
%dir %{_localstatedir}/lib/abrt
@ -957,11 +941,7 @@ killall abrt-dbus >/dev/null 2>&1 || :
%files addon-upload-watch
%{_sbindir}/abrt-upload-watch
%if %{with systemd}
%{_unitdir}/abrt-upload-watch.service
%else
%{_initrddir}/abrt-upload-watch
%endif
%{_mandir}/man*/abrt-upload-watch.*
@ -979,11 +959,7 @@ killall abrt-dbus >/dev/null 2>&1 || :
%{_mandir}/man5/koops_event.conf.5*
%config(noreplace) %{_sysconfdir}/%{name}/plugins/oops.conf
%{_datadir}/%{name}/conf.d/plugins/oops.conf
%if %{with systemd}
%{_unitdir}/abrt-oops.service
%else
%{_initrddir}/abrt-oops
%endif
%dir %{_localstatedir}/lib/abrt
@ -1000,11 +976,7 @@ killall abrt-dbus >/dev/null 2>&1 || :
%{_journalcatalogdir}/abrt_xorg.catalog
%config(noreplace) %{_sysconfdir}/libreport/plugins/catalog_xorg_format.conf
%{_mandir}/man5/xorg_event.conf.5*
%if %{with systemd}
%{_unitdir}/abrt-xorg.service
%else
%{_initrddir}/abrt-xorg
%endif
%{_bindir}/abrt-dump-xorg
%{_bindir}/abrt-dump-journal-xorg
%{_mandir}/man1/abrt-dump-xorg.1*
@ -1017,11 +989,7 @@ killall abrt-dbus >/dev/null 2>&1 || :
%config(noreplace) %{_sysconfdir}/%{name}/plugins/vmcore.conf
%{_datadir}/%{name}/conf.d/plugins/vmcore.conf
%{_datadir}/libreport/events/analyze_VMcore.xml
%if %{with systemd}
%{_unitdir}/abrt-vmcore.service
%else
%{_initrddir}/abrt-vmcore
%endif
%{_sbindir}/abrt-harvest-vmcore
%{_bindir}/abrt-action-analyze-vmcore
%{_bindir}/abrt-action-check-oops-for-hw-error
@ -1035,11 +1003,7 @@ killall abrt-dbus >/dev/null 2>&1 || :
%endif
%files addon-pstoreoops
%if %{with systemd}
%{_unitdir}/abrt-pstoreoops.service
%else
%{_initrddir}/abrt-pstoreoops
%endif
%{_sbindir}/abrt-harvest-pstoreoops
%{_bindir}/abrt-merge-pstoreoops
%{_mandir}/man1/abrt-harvest-pstoreoops.1*
@ -1065,8 +1029,15 @@ killall abrt-dbus >/dev/null 2>&1 || :
%{_journalcatalogdir}/abrt_python3.catalog
%config(noreplace) %{_sysconfdir}/libreport/plugins/catalog_python3_format.conf
%{_mandir}/man5/python3_event.conf.5*
%{python3_sitearch}/abrt*
%{python3_sitearch}/__pycache__/abrt*
%{python3_sitearch}/abrt3.pth
%{python3_sitearch}/abrt_exception_handler3.py
%{python3_sitearch}/__pycache__/abrt_exception_handler3.*
%files -n python3-abrt-container-addon
%{python3_sitearch}/abrt3_container.pth
%{python3_sitearch}/abrt_exception_handler3_container.py
%{python3_sitearch}/__pycache__/abrt_exception_handler3_container.*
%attr(6755, root, root) %{_libexecdir}/abrt-container-logger
%files plugin-sosreport
%defattr(-,root,root,-)
@ -1156,6 +1127,18 @@ killall abrt-dbus >/dev/null 2>&1 || :
%config(noreplace) %{_sysconfdir}/profile.d/abrt-console-notification.sh
%changelog
* Mon Feb 19 2018 Matej Habrnal <mhabrnal@redhat.com> 2.10.6-2
- Translation updates
- hooks: introduce docker hook for Python3
- Remove deprecated is_error macro
- ldconfig is not needed in rawhide
- remove python_sitearch macro
- remove python_site macro
- move BuildRequires to top
- remove systemd-units and replace it with systemd macro
- remove init.d services
- a-h-event: Do not deduplicate different containers
* Fri Feb 09 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 2.10.5-6
- Escape macros in %%changelog

View File

@ -1 +1 @@
SHA512 (abrt-2.10.5.tar.gz) = 6e334b045efa18f8200447eb142f54d4f68b39d5a470c30b7272778a3ab22c1b55c222fae8657d86e6c78dfd3070f3ddb68f25ee6ca5ca0be4c5463239cbf0ef
SHA512 (abrt-2.10.6.tar.gz) = 4c47aec3ace8033be954cc75f500d7394a77a3dd2511cabbe1706615907d4d6a4f89da1aec6d4ebc9519e47058ae139fbac40eab47048572a34ea52da528f700