[abrt] fixed problems with wrong obsoletes/provides rhbz#723376
Jiří Moskovčák
jmoskovc at fedoraproject.org
Thu Jul 21 18:46:28 UTC 2011
commit a420795f354c8979ba79f47fd48e3b0a099387ec
Author: Jiri Moskovcak <jmoskovc at redhat.com>
Date: Thu Jul 21 20:44:27 2011 +0200
fixed problems with wrong obsoletes/provides rhbz#723376
...unch-reporter-children-with-LIBREPORT_GET.patch | 40 +++
...he-main-window-in-2-panes-reported-not-re.patch | 354 ++++++++++++++++++++
...ve-forgotten-abrt-action-kerneloops-files.patch | 268 +++++++++++++++
...-install-debuginfo-ask-before-downloading.patch | 71 ++++
abrt.spec | 138 ++------
blacklist.patch | 12 +-
low_bt_rating.patch | 20 --
prgname.patch | 51 ---
remove_libreport_python.patch | 6 -
retrace_addr.patch | 19 -
retrace_client_flush.patch | 18 -
11 files changed, 770 insertions(+), 227 deletions(-)
---
diff --git a/0001-abrt-gui-launch-reporter-children-with-LIBREPORT_GET.patch b/0001-abrt-gui-launch-reporter-children-with-LIBREPORT_GET.patch
new file mode 100644
index 0000000..6205f10
--- /dev/null
+++ b/0001-abrt-gui-launch-reporter-children-with-LIBREPORT_GET.patch
@@ -0,0 +1,40 @@
+From 1f52667a18026dba4050368e5d2501ec6145e071 Mon Sep 17 00:00:00 2001
+From: Denys Vlasenko <dvlasenk at redhat.com>
+Date: Thu, 21 Jul 2011 09:50:56 +0200
+Subject: [PATCH 1/4] abrt-gui: launch reporter children with LIBREPORT_GETPID
+
+By using LIBREPORT_NOWAIT | LIBREPORT_GETPID in abt-gui,
+we make it so that reporter's SIGCHLD reaches abrt-gui
+and lets it refresh the list.
+
+Signed-off-by: Denys Vlasenko <dvlasenk at redhat.com>
+---
+ src/gui-gtk/main.c | 5 ++---
+ 1 files changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/src/gui-gtk/main.c b/src/gui-gtk/main.c
+index b62e8c0..1409191 100644
+--- a/src/gui-gtk/main.c
++++ b/src/gui-gtk/main.c
+@@ -204,7 +204,7 @@ static void on_row_activated_cb(GtkTreeView *treeview, GtkTreePath *path, GtkTre
+ gtk_tree_model_get_value(store, &iter, COLUMN_DUMP_DIR, &d_dir);
+
+ const char *dirname = g_value_get_string(&d_dir);
+- report_problem_in_dir(dirname, LIBREPORT_ANALYZE | LIBREPORT_NOWAIT);
++ report_problem_in_dir(dirname, LIBREPORT_ANALYZE | LIBREPORT_NOWAIT | LIBREPORT_GETPID);
+ }
+ }
+ }
+@@ -293,8 +293,7 @@ static void on_button_send_cb(GtkWidget *button, gpointer data)
+ /* why it doesn't want to hide before report ends? */
+ gtk_widget_destroy(s_report_window);
+
+- int status = report_problem_in_memory(pd, LIBREPORT_NOWAIT);
+- VERB1 log("Reporting finished with status %i", status);
++ report_problem_in_memory(pd, LIBREPORT_NOWAIT | LIBREPORT_GETPID);
+ free_problem_data(pd);
+ }
+
+--
+1.7.6
+
diff --git a/0002-gui-split-the-main-window-in-2-panes-reported-not-re.patch b/0002-gui-split-the-main-window-in-2-panes-reported-not-re.patch
new file mode 100644
index 0000000..dd973e2
--- /dev/null
+++ b/0002-gui-split-the-main-window-in-2-panes-reported-not-re.patch
@@ -0,0 +1,354 @@
+From 3f3655980007d39e0377e76a49fd2937f43f0be7 Mon Sep 17 00:00:00 2001
+From: Jiri Moskovcak <jmoskovc at redhat.com>
+Date: Thu, 21 Jul 2011 11:02:11 +0200
+Subject: [PATCH 2/4] gui: split the main window in 2 panes -
+ reported/not-reported
+
+---
+ src/gui-gtk/main.c | 215 ++++++++++++++++++++++++++++++++++++++++++++--------
+ 1 files changed, 182 insertions(+), 33 deletions(-)
+
+diff --git a/src/gui-gtk/main.c b/src/gui-gtk/main.c
+index 1409191..776e85a 100644
+--- a/src/gui-gtk/main.c
++++ b/src/gui-gtk/main.c
+@@ -32,7 +32,9 @@ static const char help_uri[] = "http://docs.fedoraproject.org/en-US/"
+ "Fedora/14/html/Deployment_Guide/ch-abrt.html";
+
+ static GtkListStore *s_dumps_list_store;
++static GtkListStore *s_reported_dumps_list_store;
+ static GtkWidget *s_treeview;
++static GtkWidget *s_reported_treeview;
+ static GtkWidget *g_main_window;
+ static GtkWidget *s_report_window;
+
+@@ -40,13 +42,38 @@ enum
+ {
+ COLUMN_SOURCE,
+ COLUMN_REASON,
+- COLUMN_DIRNAME,
+ COLUMN_LATEST_CRASH_STR,
+ COLUMN_LATEST_CRASH,
+ COLUMN_DUMP_DIR,
++ COLUMN_REPORTED_TO,
+ NUM_COLUMNS
+ };
+
++//FIXME: maybe we can use strrchr and make this faster...
++static char *get_last_line(const char* msg)
++{
++ const char *curr_end = NULL;
++ const char *start = msg;
++ const char *end = msg;
++
++ while((curr_end = strchr(end, '\n')) != NULL)
++ {
++ end = curr_end;
++ curr_end = strchr(end+1, '\n');
++ if (curr_end == NULL || strchr(end+2, '\n') == NULL)
++ break;
++
++ start = end+1;
++ end = curr_end;
++ }
++
++ //fix the case where reported_to has only 1 line without \n
++ if (end == msg)
++ end = end + strlen(msg);
++
++ return xstrndup(start, end - start);
++}
++
+ static void add_directory_to_dirlist(const char *dirname)
+ {
+ /* Silently ignore *any* errors, not only EACCES.
+@@ -67,21 +94,11 @@ static void add_directory_to_dirlist(const char *dirname)
+ {
+ time_t t = strtol(time_str, NULL, 10); /* atoi won't work past 2038! */
+ struct tm *ptm = localtime(&t);
+- size_t time_len = strftime(time_buf, sizeof(time_buf)-1, "%Y-%m-%m %H:%M", ptm);
++ size_t time_len = strftime(time_buf, sizeof(time_buf)-1, "%Y-%m-%d %H:%M", ptm);
+ time_buf[time_len] = '\0';
+ }
+ free(time_str);
+
+- /*
+- char *msg = dd_load_text_ext(dd, FILENAME_REPORTED_TO, 0
+- | DD_LOAD_TEXT_RETURN_NULL_ON_FAILURE
+- | DD_FAIL_QUIETLY_ENOENT
+- | DD_FAIL_QUIETLY_EACCES
+- );
+- const char *reported = (msg ? GTK_STOCK_YES : GTK_STOCK_NO);
+- free(msg);
+- */
+-
+ char *reason = dd_load_text(dd, FILENAME_REASON);
+
+ /* the source of the problem:
+@@ -102,18 +119,38 @@ static void add_directory_to_dirlist(const char *dirname)
+ );
+ }
+
++ char *msg = dd_load_text_ext(dd, FILENAME_REPORTED_TO, 0
++ | DD_LOAD_TEXT_RETURN_NULL_ON_FAILURE
++ | DD_FAIL_QUIETLY_ENOENT
++ | DD_FAIL_QUIETLY_EACCES
++ );
++
++
++ GtkListStore *list_store;
++
++ char *subm_status = NULL;
++ if (msg)
++ {
++ list_store = s_reported_dumps_list_store;
++ subm_status = get_last_line(msg);
++ }
++ else
++ list_store = s_dumps_list_store;
+
+ GtkTreeIter iter;
+- gtk_list_store_append(s_dumps_list_store, &iter);
+- gtk_list_store_set(s_dumps_list_store, &iter,
++ gtk_list_store_append(list_store, &iter);
++ gtk_list_store_set(list_store, &iter,
+ COLUMN_SOURCE, source,
+ COLUMN_REASON, reason,
+- COLUMN_DIRNAME, dd->dd_dirname,
+ //OPTION: time format
+ COLUMN_LATEST_CRASH_STR, time_buf,
+ COLUMN_LATEST_CRASH, time,
+ COLUMN_DUMP_DIR, dirname,
++ COLUMN_REPORTED_TO, msg ? subm_status : NULL,
+ -1);
++ /* this is safe, subm_status is either null or malloced string from get_last_line */
++ free(subm_status);
++ free(msg);
+ free(reason);
+
+ dd_close(dd);
+@@ -123,6 +160,7 @@ static void add_directory_to_dirlist(const char *dirname)
+ static void rescan_dirs_and_add_to_dirlist(void)
+ {
+ gtk_list_store_clear(s_dumps_list_store);
++ gtk_list_store_clear(s_reported_dumps_list_store);
+ scan_dirs_and_add_to_dirlist();
+ }
+
+@@ -232,7 +270,7 @@ static void delete_report(GtkTreeView *treeview)
+ VERB1 log("Deleting '%s'", dump_dir_name);
+ if (delete_dump_dir_possibly_using_abrtd(dump_dir_name) == 0)
+ {
+- gtk_list_store_remove(s_dumps_list_store, &iter);
++ gtk_list_store_remove(GTK_LIST_STORE(store), &iter);
+ }
+ else
+ {
+@@ -262,7 +300,9 @@ static gint on_key_press_event_cb(GtkTreeView *treeview, GdkEventKey *key, gpoin
+
+ static void on_btn_delete_cb(GtkButton *button, gpointer unused)
+ {
++ /* delete from both treeviews */
+ delete_report(GTK_TREE_VIEW(s_treeview));
++ delete_report(GTK_TREE_VIEW(s_reported_treeview));
+ }
+
+ static void on_menu_help_cb(GtkMenuItem *menuitem, gpointer unused)
+@@ -421,6 +461,50 @@ static void add_columns(GtkTreeView *treeview)
+ gtk_tree_view_append_column(treeview, column);
+ }
+
++static void add_columns_reported(GtkTreeView *treeview)
++{
++ GtkCellRenderer *renderer;
++ GtkTreeViewColumn *column;
++
++ renderer = gtk_cell_renderer_text_new();
++ column = gtk_tree_view_column_new_with_attributes(_("Source"),
++ renderer,
++ "text",
++ COLUMN_SOURCE,
++ NULL);
++ gtk_tree_view_column_set_resizable(column, TRUE);
++ gtk_tree_view_column_set_sort_column_id(column, COLUMN_SOURCE);
++ gtk_tree_view_append_column(treeview, column);
++
++ renderer = gtk_cell_renderer_text_new();
++ column = gtk_tree_view_column_new_with_attributes(_("Problem"),
++ renderer,
++ "text",
++ COLUMN_REASON,
++ NULL);
++ gtk_tree_view_column_set_resizable(column, TRUE);
++ gtk_tree_view_column_set_sort_column_id(column, COLUMN_REASON);
++ gtk_tree_view_append_column(treeview, column);
++
++ renderer = gtk_cell_renderer_text_new();
++ column = gtk_tree_view_column_new_with_attributes(_("Date Submitted"),
++ renderer,
++ "text",
++ COLUMN_LATEST_CRASH_STR,
++ NULL);
++ gtk_tree_view_column_set_sort_column_id(column, COLUMN_LATEST_CRASH);
++ gtk_tree_view_append_column(treeview, column);
++
++ renderer = gtk_cell_renderer_text_new();
++ column = gtk_tree_view_column_new_with_attributes(_("Submision Result"),
++ renderer,
++ "text",
++ COLUMN_REPORTED_TO,
++ NULL);
++ //gtk_tree_view_column_set_sort_column_id(column, COLUMN_LATEST_CRASH);
++ gtk_tree_view_append_column(treeview, column);
++}
++
+ static GtkWidget *create_menu(void)
+ {
+ /* main bar */
+@@ -476,40 +560,102 @@ static GtkWidget *create_main_window(void)
+ gtk_window_set_default_icon_name("abrt");
+
+ GtkWidget *main_vbox = gtk_vbox_new(false, 0);
++ /* add menu */
++ gtk_box_pack_start(GTK_BOX(main_vbox), create_menu(), false, false, 0);
+
+- /* Scrolled region inside main window */
+- GtkWidget *scroll_win = gtk_scrolled_window_new(NULL, NULL);
+- gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(scroll_win),
++ GtkWidget *not_subm_vbox = gtk_vbox_new(false, 0);
++ gtk_container_set_border_width(GTK_CONTAINER(not_subm_vbox), 10);
++ GtkWidget *subm_vbox = gtk_vbox_new(false, 0);
++ gtk_container_set_border_width(GTK_CONTAINER(subm_vbox), 10);
++
++ /* Scrolled region for not reported problems inside main window*/
++ GtkWidget *new_problems_scroll_win = gtk_scrolled_window_new(NULL, NULL);
++ gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(new_problems_scroll_win),
+ GTK_SHADOW_ETCHED_IN);
+- gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(scroll_win),
++ gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(new_problems_scroll_win),
+ GTK_POLICY_AUTOMATIC,
+ GTK_POLICY_AUTOMATIC);
+
+- gtk_box_pack_start(GTK_BOX(main_vbox), create_menu(), false, false, 0);
+- gtk_box_pack_start(GTK_BOX(main_vbox), scroll_win, true, true, 0);
+- gtk_container_add(GTK_CONTAINER(g_main_window), main_vbox);
++ GtkWidget *not_subm_lbl = gtk_label_new(_("Not submitted reports"));
++ gtk_misc_set_alignment(GTK_MISC(not_subm_lbl), 0, 0);
++ gtk_label_set_markup(GTK_LABEL(not_subm_lbl), _("<b>Not submitted reports</b>"));
++
++ /* add label for not submitted tree view */
++ gtk_box_pack_start(GTK_BOX(not_subm_vbox), not_subm_lbl, false, false, 0);
++ gtk_box_pack_start(GTK_BOX(not_subm_vbox), new_problems_scroll_win, true, true, 0);
++ gtk_box_pack_start(GTK_BOX(main_vbox), not_subm_vbox, true, true, 0);
+
+ /* Tree view inside scrolled region */
+ s_treeview = gtk_tree_view_new();
+ g_object_set(s_treeview, "rules-hint", 1, NULL); /* use alternating colors */
+ add_columns(GTK_TREE_VIEW(s_treeview));
+- gtk_container_add(GTK_CONTAINER(scroll_win), s_treeview);
++ gtk_container_add(GTK_CONTAINER(new_problems_scroll_win), s_treeview);
+
+ /* Create data store for the list and attach it */
+- s_dumps_list_store = gtk_list_store_new(NUM_COLUMNS, G_TYPE_STRING, /* source */
++ s_dumps_list_store = gtk_list_store_new(NUM_COLUMNS,
++ G_TYPE_STRING, /* source */
++ G_TYPE_STRING, /* executable */
++ G_TYPE_STRING, /* time */
++ G_TYPE_INT, /* unix time - used for sort */
++ G_TYPE_STRING, /* dump dir path */
++ G_TYPE_STRING); /* reported_to */
++
++
++ //FIXME: configurable!!
++ gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(s_dumps_list_store),
++ COLUMN_LATEST_CRASH,
++ GTK_SORT_DESCENDING);
++
++ gtk_tree_view_set_model(GTK_TREE_VIEW(s_treeview), GTK_TREE_MODEL(s_dumps_list_store));
++
++ /* Double click/Enter handler */
++ g_signal_connect(s_treeview, "row-activated", G_CALLBACK(on_row_activated_cb), NULL);
++ /* Delete handler */
++ g_signal_connect(s_treeview, "key-press-event", G_CALLBACK(on_key_press_event_cb), NULL);
++
++ /* scrolled region for reported problems */
++ GtkWidget *reported_problems_scroll_win = gtk_scrolled_window_new(NULL, NULL);
++ gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(reported_problems_scroll_win),
++ GTK_SHADOW_ETCHED_IN);
++ gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(reported_problems_scroll_win),
++ GTK_POLICY_AUTOMATIC,
++ GTK_POLICY_AUTOMATIC);
++
++ GtkWidget *subm_lbl = gtk_label_new(_("Submitted reports"));
++ /* align to left */
++ gtk_misc_set_alignment(GTK_MISC(subm_lbl), 0, 0);
++ gtk_label_set_markup(GTK_LABEL(subm_lbl), _("<b>Submitted reports</b>"));
++
++
++ /* add label for submitted tree view */
++ gtk_box_pack_start(GTK_BOX(subm_vbox), subm_lbl, false, false, 0);
++ gtk_box_pack_start(GTK_BOX(subm_vbox), reported_problems_scroll_win, true, true, 0);
++ gtk_box_pack_start(GTK_BOX(main_vbox), subm_vbox, true, true, 0);
++
++ /* Tree view inside scrolled region */
++ s_reported_treeview = gtk_tree_view_new();
++ g_object_set(s_reported_treeview, "rules-hint", 1, NULL); /* use alternating colors */
++ add_columns_reported(GTK_TREE_VIEW(s_reported_treeview));
++ gtk_container_add(GTK_CONTAINER(reported_problems_scroll_win), s_reported_treeview);
++
++ /* Create data store for the list and attach it */
++ s_reported_dumps_list_store = gtk_list_store_new(NUM_COLUMNS,
++ G_TYPE_STRING, /* source */
+ G_TYPE_STRING, /* executable */
+- G_TYPE_STRING, /* hostname */
+ G_TYPE_STRING, /* time */
+ G_TYPE_INT, /* unix time - used for sort */
+ G_TYPE_STRING, /* dump dir path */
+- G_TYPE_STRING);/* row background */
++ G_TYPE_STRING); /* reported_to */
++
+
+ //FIXME: configurable!!
+- gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(s_dumps_list_store),
++ gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(s_reported_dumps_list_store),
+ COLUMN_LATEST_CRASH,
+ GTK_SORT_DESCENDING);
+
+- gtk_tree_view_set_model(GTK_TREE_VIEW(s_treeview), GTK_TREE_MODEL(s_dumps_list_store));
++
++ gtk_tree_view_set_model(GTK_TREE_VIEW(s_reported_treeview), GTK_TREE_MODEL(s_reported_dumps_list_store));
++
+
+ /* buttons are homogenous so set size only for one button and it will
+ * work for the rest buttons in same gtk_hbox_new() */
+@@ -518,20 +664,23 @@ static GtkWidget *create_main_window(void)
+
+ GtkWidget *btn_delete = gtk_button_new_from_stock(GTK_STOCK_DELETE);
+
+- GtkWidget *hbox_report_delete = gtk_hbox_new(true, 4);
++ GtkWidget *hbox_report_delete = gtk_hbox_new(true, 0);
+ gtk_box_pack_start(GTK_BOX(hbox_report_delete), btn_delete, true, true, 0);
+- gtk_box_pack_start(GTK_BOX(hbox_report_delete), btn_report, true, true, 0);
++ gtk_box_pack_start(GTK_BOX(hbox_report_delete), btn_report, true, true, 10);
+
+ GtkWidget *halign = gtk_alignment_new(1, 0, 0, 0);
+ gtk_container_add(GTK_CONTAINER(halign), hbox_report_delete);
+
+ gtk_box_pack_start(GTK_BOX(main_vbox), halign, false, false, 10);
+
++ /* put the main_vbox to main window */
++ gtk_container_add(GTK_CONTAINER(g_main_window), main_vbox);
++
+ /* Double click/Enter handler */
+- g_signal_connect(s_treeview, "row-activated", G_CALLBACK(on_row_activated_cb), NULL);
++ g_signal_connect(s_reported_treeview, "row-activated", G_CALLBACK(on_row_activated_cb), NULL);
+ g_signal_connect(btn_report, "clicked", G_CALLBACK(on_btn_report_cb), NULL);
+ /* Delete handler */
+- g_signal_connect(s_treeview, "key-press-event", G_CALLBACK(on_key_press_event_cb), NULL);
++ g_signal_connect(s_reported_treeview, "key-press-event", G_CALLBACK(on_key_press_event_cb), NULL);
+ g_signal_connect(btn_delete, "clicked", G_CALLBACK(on_btn_delete_cb), NULL);
+ /* Quit when user closes the main window */
+ g_signal_connect(g_main_window, "destroy", gtk_main_quit, NULL);
+--
+1.7.6
+
diff --git a/0003-remove-forgotten-abrt-action-kerneloops-files.patch b/0003-remove-forgotten-abrt-action-kerneloops-files.patch
new file mode 100644
index 0000000..84575e1
--- /dev/null
+++ b/0003-remove-forgotten-abrt-action-kerneloops-files.patch
@@ -0,0 +1,268 @@
+From 89de28a3510c6e7a30ca053caea35ccabfbde75a Mon Sep 17 00:00:00 2001
+From: Miroslav Lichvar <mlichvar at redhat.com>
+Date: Thu, 21 Jul 2011 15:34:50 +0200
+Subject: [PATCH 3/4] remove forgotten abrt-action-kerneloops files
+
+---
+ src/plugins/abrt-action-kerneloops.c | 173 --------------------------------
+ src/plugins/abrt-action-kerneloops.txt | 68 -------------
+ 2 files changed, 0 insertions(+), 241 deletions(-)
+ delete mode 100644 src/plugins/abrt-action-kerneloops.c
+ delete mode 100644 src/plugins/abrt-action-kerneloops.txt
+
+diff --git a/src/plugins/abrt-action-kerneloops.c b/src/plugins/abrt-action-kerneloops.c
+deleted file mode 100644
+index a117266..0000000
+--- a/src/plugins/abrt-action-kerneloops.c
++++ /dev/null
+@@ -1,173 +0,0 @@
+-/*
+- Copyright (C) 2010 ABRT team
+- Copyright (C) 2010 RedHat Inc
+-
+- This program is free software; you can redistribute it and/or modify
+- it under the terms of the GNU General Public License as published by
+- the Free Software Foundation; either version 2 of the License, or
+- (at your option) any later version.
+-
+- This program is distributed in the hope that it will be useful,
+- but WITHOUT ANY WARRANTY; without even the implied warranty of
+- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+- GNU General Public License for more details.
+-
+- Authors:
+- Anton Arapov <anton at redhat.com>
+- Arjan van de Ven <arjan at linux.intel.com>
+- */
+-#include <curl/curl.h>
+-#include "abrtlib.h"
+-
+-/* helpers */
+-static size_t writefunction(void *ptr, size_t size, size_t nmemb, void *stream)
+-{
+- size *= nmemb;
+-/*
+- char *c, *c1, *c2;
+-
+- log("received: '%*.*s'", (int)size, (int)size, (char*)ptr);
+- c = (char*)xzalloc(size + 1);
+- memcpy(c, ptr, size);
+- c1 = strstr(c, "201 ");
+- if (c1)
+- {
+- c1 += 4;
+- c2 = strchr(c1, '\n');
+- if (c2)
+- *c2 = 0;
+- }
+- free(c);
+-*/
+-
+- return size;
+-}
+-
+-/* Send oops data to kerneloops.org-style site, using HTTP POST */
+-/* Returns 0 on success */
+-static CURLcode http_post_to_kerneloops_site(const char *url, const char *oopsdata)
+-{
+- CURLcode ret;
+- CURL *handle;
+- struct curl_httppost *post = NULL;
+- struct curl_httppost *last = NULL;
+-
+- handle = curl_easy_init();
+- if (!handle)
+- error_msg_and_die("Can't create curl handle");
+-
+- curl_easy_setopt(handle, CURLOPT_URL, url);
+-
+- curl_formadd(&post, &last,
+- CURLFORM_COPYNAME, "oopsdata",
+- CURLFORM_COPYCONTENTS, oopsdata,
+- CURLFORM_END);
+- curl_formadd(&post, &last,
+- CURLFORM_COPYNAME, "pass_on_allowed",
+- CURLFORM_COPYCONTENTS, "yes",
+- CURLFORM_END);
+-
+- curl_easy_setopt(handle, CURLOPT_HTTPPOST, post);
+- curl_easy_setopt(handle, CURLOPT_WRITEFUNCTION, writefunction);
+-
+- ret = curl_easy_perform(handle);
+-
+- curl_formfree(post);
+- curl_easy_cleanup(handle);
+-
+- return ret;
+-}
+-
+-static void report_to_kerneloops(
+- const char *dump_dir_name,
+- map_string_h *settings)
+-{
+- problem_data_t *problem_data = create_problem_data_for_reporting(dump_dir_name);
+- if (!problem_data)
+- xfunc_die(); /* create_problem_data_for_reporting already emitted error msg */
+-
+- const char *backtrace = get_problem_item_content_or_NULL(problem_data, FILENAME_BACKTRACE);
+- if (!backtrace)
+- error_msg_and_die("Error sending kernel oops due to missing backtrace");
+-
+- const char *env = getenv("KerneloopsReporter_SubmitURL");
+- const char *submitURL = (env ? env : get_map_string_item_or_empty(settings, "SubmitURL"));
+- if (!submitURL[0])
+- submitURL = "http://submit.kerneloops.org/submitoops.php";
+-
+- log(_("Submitting oops report to %s"), submitURL);
+-
+- CURLcode ret = http_post_to_kerneloops_site(submitURL, backtrace);
+- if (ret != CURLE_OK)
+- error_msg_and_die("Kernel oops has not been sent due to %s", curl_easy_strerror(ret));
+-
+- free_problem_data(problem_data);
+-
+- /* Server replies with:
+- * 200 thank you for submitting the kernel oops information
+- * RemoteIP: 34192fd15e34bf60fac6a5f01bba04ddbd3f0558
+- * - no URL or bug ID apparently...
+- */
+- struct dump_dir *dd = dd_opendir(dump_dir_name, /*flags:*/ 0);
+- if (dd)
+- {
+- char *msg = xasprintf("kerneloops: URL=%s", submitURL);
+- add_reported_to(dd, msg);
+- free(msg);
+- dd_close(dd);
+- }
+-
+- log("Kernel oops report was uploaded");
+-}
+-
+-int main(int argc, char **argv)
+-{
+- abrt_init(argv);
+-
+- map_string_h *settings = new_map_string();
+- const char *dump_dir_name = ".";
+- GList *conf_file = NULL;
+-
+- /* Can't keep these strings/structs static: _() doesn't support that */
+- const char *program_usage_string = _(
+- "\b [-v] [-c CONFFILE]... -d DIR\n"
+- "\n"
+- "Reports kernel oops to kerneloops.org (or similar) site.\n"
+- "\n"
+- "Files with names listed in $EXCLUDE_FROM_REPORT are not included\n"
+- "into the tarball.\n"
+- "\n"
+- "CONFFILE lines should have 'PARAM = VALUE' format.\n"
+- "Recognized string parameter: SubmitURL.\n"
+- "Parameter can be overridden via $KerneloopsReporter_SubmitURL."
+- );
+- enum {
+- OPT_v = 1 << 0,
+- OPT_d = 1 << 1,
+- OPT_c = 1 << 2,
+- };
+- /* Keep enum above and order of options below in sync! */
+- struct options program_options[] = {
+- OPT__VERBOSE(&g_verbose),
+- OPT_STRING('d', NULL, &dump_dir_name, "DIR" , _("Dump directory")),
+- OPT_LIST( 'c', NULL, &conf_file , "FILE", _("Configuration file")),
+- OPT_END()
+- };
+- /*unsigned opts =*/ parse_opts(argc, argv, program_options, program_usage_string);
+-
+- export_abrt_envvars(0);
+-
+- while (conf_file)
+- {
+- char *fn = (char *)conf_file->data;
+- VERB1 log("Loading settings from '%s'", fn);
+- load_conf_file(fn, settings, /*skip key w/o values:*/ true);
+- VERB3 log("Loaded '%s'", fn);
+- conf_file = g_list_remove(conf_file, fn);
+- }
+-
+- report_to_kerneloops(dump_dir_name, settings);
+-
+- free_map_string(settings);
+- return 0;
+-}
+diff --git a/src/plugins/abrt-action-kerneloops.txt b/src/plugins/abrt-action-kerneloops.txt
+deleted file mode 100644
+index 468287f..0000000
+--- a/src/plugins/abrt-action-kerneloops.txt
++++ /dev/null
+@@ -1,68 +0,0 @@
+-abrt-action-kerneloops(1)
+-=========================
+-
+-NAME
+-----
+-abrt-action-kerneloops - Reports kernel oops to kerneloops.org (or similar)
+-site.
+-
+-SYNOPSIS
+---------
+-'abrt-action-kerneloops' [-v] [-c CONFFILE]... [ -d DIR ]
+-
+-DESCRIPTION
+------------
+-The tool is used to report the crash to the Kerneloops tracker.
+-
+-Configuration file
+-~~~~~~~~~~~~~~~~~~
+-Configuration file contains entries in a format "Option = Value".
+-
+-The options are:
+-
+-'SubmitURL'::
+- The URL of the kerneloops tracker, the default is
+- "http://submit.kerneloops.org/submitoops.php".
+-
+-Integration with ABRT events
+-~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+-'abrt-action-kerneloops' can be used as a reporter, to allow users to report
+-problems to the Kerneloops tracker. This usage is pre-configured in
+-/etc/libreport/events.d/koops_event.conf:
+-
+-------------
+-EVENT=report_Kerneloops analyzer=Kerneloops abrt-action-kerneloops
+-------------
+-
+-It can be also used automatically and immediately without user interaction.
+-When this is desired, modify the event configuration file to run the tool on
+-the 'post-create' event:
+-
+-------------
+-EVENT=post-create analyzer=Kerneloops abrt-action-kerneloops
+-------------
+-
+-OPTIONS
+--------
+--v::
+- Be more verbose. Can be given multiple times.
+-
+--d DIR::
+- Path to dump directory.
+-
+--c CONFFILE::
+- Path to configration file. When used in ABRT event system, the file
+- contains site-wide configuration. Users can change the values via
+- environment variables.
+-
+-ENVIRONMENT VARIABLES
+----------------------
+-Environment variables take precedence over values provided in
+-the configuration file.
+-
+-'KerneloopsReporter_SubmitURL'::
+- The URL of the kerneloops tracker.
+-
+-AUTHORS
+--------
+-* ABRT team
+--
+1.7.6
+
diff --git a/0004-install-debuginfo-ask-before-downloading.patch b/0004-install-debuginfo-ask-before-downloading.patch
new file mode 100644
index 0000000..90f2f74
--- /dev/null
+++ b/0004-install-debuginfo-ask-before-downloading.patch
@@ -0,0 +1,71 @@
+From 90893a0c84a594337ca22fa83f364f5b4a7fb1b2 Mon Sep 17 00:00:00 2001
+From: Michal Toman <mtoman at redhat.com>
+Date: Thu, 21 Jul 2011 16:48:08 +0200
+Subject: [PATCH 4/4] install-debuginfo: ask before downloading
+
+---
+ src/plugins/abrt-action-install-debuginfo | 34 ++++++----------------------
+ 1 files changed, 8 insertions(+), 26 deletions(-)
+
+diff --git a/src/plugins/abrt-action-install-debuginfo b/src/plugins/abrt-action-install-debuginfo
+index 2ad0790..31aab2c 100644
+--- a/src/plugins/abrt-action-install-debuginfo
++++ b/src/plugins/abrt-action-install-debuginfo
+@@ -11,6 +11,7 @@ import errno
+ import time
+ import getopt
+ import shutil
++import reportclient
+ from subprocess import Popen, PIPE
+ from yum import _, YumBase
+ from yum.callbacks import DownloadBaseCallback
+@@ -74,22 +75,6 @@ def unmute_stdout():
+ else:
+ print "ERR: unmute called without mute?"
+
+-def ask_yes_no(prompt, retries=4):
+- while True:
+- try:
+- response = raw_input(prompt)
+- except EOFError:
+- log1("got eof, probably executed from helper, assuming - yes")
+- return True
+- if response in (_("y")): # for translators -> y/Y as yes
+- return True
+- if response in ("", _("n")): # for translators -> N/n as no
+- return False
+- retries = retries - 1
+- if retries < 0:
+- break
+- return False
+-
+ # TODO: unpack just required debuginfo and not entire rpm?
+ # ..that can lead to: foo.c No such file and directory
+ # files is not used...
+@@ -286,16 +271,13 @@ class DebugInfoDownload(YumBase):
+ print _("Can't find packages for %u debuginfo files") % len(not_found)
+ if verbose != 0 or total_pkgs != 0:
+ print _("Packages to download: %u") % total_pkgs
+- print _("Downloading %.2fMb, installed size: %.2fMb") % (
+- todownload_size / (1024**2),
+- installed_size / (1024**2)
+- )
+-
+- # ask only if we have terminal, because for now we don't have a way
+- # how to pass the question to gui and the response back
+- if noninteractive == False and sys.stdout.isatty():
+- if not ask_yes_no(_("Is this ok? [y/N] ")):
+- return RETURN_OK
++ question = _("Downloading %.2fMb, installed size: %.2fMb. Continue?") % (
++ todownload_size / (1024**2),
++ installed_size / (1024**2)
++ )
++ if not reportclient.ask_yes_no(question):
++ print _("Download cancelled by user")
++ return RETURN_OK
+
+ for pkg, files in package_files_dict.iteritems():
+ dnlcb.downloaded_pkgs = downloaded_pkgs
+--
+1.7.6
+
diff --git a/abrt.spec b/abrt.spec
index 5648541..239c5cb 100644
--- a/abrt.spec
+++ b/abrt.spec
@@ -1,7 +1,7 @@
%{!?python_site: %global python_site %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(0)")}
# platform-dependent
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
-%if 0%{?fedora} >= 16
+%if 0%{?fedora} >= 14
%bcond_without systemd
%else
%bcond_with systemd
@@ -9,7 +9,7 @@
Summary: Automatic bug detection and reporting tool
Name: abrt
-Version: 2.0.3
+Version: 2.0.4
Release: 1%{?dist}
License: GPLv2+
Group: Applications/System
@@ -18,25 +18,25 @@ Source: https://fedorahosted.org/released/%{name}/%{name}-%{version}.tar.gz
Source1: abrt.init
Source2: abrt-ccpp.init
Source3: abrt-oops.init
-Patch0: blacklist.patch
-Patch1: allow_bz_for_koops.patch
+Patch0: 0001-abrt-gui-launch-reporter-children-with-LIBREPORT_GET.patch
+Patch1: 0002-gui-split-the-main-window-in-2-panes-reported-not-re.patch
+Patch2: 0004-install-debuginfo-ask-before-downloading.patch
+Patch3: blacklist.patch
BuildRequires: dbus-devel
BuildRequires: gtk2-devel
-BuildRequires: curl-devel
BuildRequires: rpm-devel >= 4.6
BuildRequires: desktop-file-utils
BuildRequires: libnotify-devel
-BuildRequires: xmlrpc-c-devel
+#why? BuildRequires: file-devel
BuildRequires: python-devel
BuildRequires: gettext
BuildRequires: libxml2-devel
-BuildRequires: libtar-devel
BuildRequires: intltool
BuildRequires: libtool
BuildRequires: nss-devel
BuildRequires: asciidoc
BuildRequires: xmlto
-BuildRequires: libreport-devel
+BuildRequires: libreport-devel >= 2.0.5-2
BuildRequires: btparser-devel
# for rhel6
@@ -106,60 +106,13 @@ Summary: %{name}'s kerneloops addon
Group: System Environment/Libraries
Requires: curl
Requires: %{name} = %{version}-%{release}
+Requires: libreport-plugin-kerneloops
Obsoletes: kerneloops > 0.0.1
Obsoletes: abrt-plugin-kerneloops > 0.0.1
Obsoletes: abrt-plugin-kerneloopsreporter > 0.0.1
%description addon-kerneloops
-This package contains plugin for collecting kernel crash information
-and reporter plugin which sends this information to specified server,
-usually to kerneloops.org.
-
-%package plugin-logger
-Summary: %{name}'s logger reporter plugin
-Group: System Environment/Libraries
-Requires: %{name} = %{version}-%{release}
-
-%description plugin-logger
-The simple reporter plugin which writes a report to a specified file.
-
-%package plugin-mailx
-Summary: %{name}'s mailx reporter plugin
-Group: System Environment/Libraries
-Requires: %{name} = %{version}-%{release}
-Requires: mailx
-
-%description plugin-mailx
-The simple reporter plugin which sends a report via mailx to a specified
-email address.
-
-%package plugin-bugzilla
-Summary: %{name}'s bugzilla plugin
-Group: System Environment/Libraries
-Requires: %{name} = %{version}-%{release}
-
-%description plugin-bugzilla
-Plugin to report bugs into the bugzilla.
-
-%package plugin-rhtsupport
-Summary: %{name}'s RHTSupport plugin
-Group: System Environment/Libraries
-Requires: %{name} = %{version}-%{release}
-Obsoletes: abrt-plugin-catcut > 0.0.1
-Obsoletes: abrt-plugin-rhfastcheck > 0.0.1
-Obsoletes: abrt-plugin-rhticket > 0.0.1
-
-%description plugin-rhtsupport
-Plugin to report bugs into RH support system.
-
-%package plugin-reportuploader
-Summary: %{name}'s reportuploader plugin
-Group: System Environment/Libraries
-Requires: %{name} = %{version}-%{release}
-Obsoletes: abrt-plugin-ticketuploader > 0.0.1
-
-%description plugin-reportuploader
-Plugin to report bugs into anonymous FTP site associated with ticketing system.
+This package contains plugin for collecting kernel crash information.
%package addon-python
Summary: %{name}'s addon for catching and analyzing Python exceptions
@@ -180,7 +133,7 @@ Requires: %{name} = %{version}-%{release}
Requires: libreport-cli
Requires: abrt-addon-kerneloops
Requires: abrt-addon-ccpp, abrt-addon-python
-Requires: abrt-plugin-bugzilla, abrt-plugin-logger
+Requires: libreport-plugin-bugzilla, libreport-plugin-logger
%description cli
This package contains simple command line client for controlling abrt daemon over
@@ -200,7 +153,7 @@ Requires: abrt-addon-ccpp, abrt-addon-python
# Default config of addon-ccpp requires gdb
Requires: gdb >= 7.0-3
Requires: abrt-gui
-Requires: abrt-plugin-logger, abrt-plugin-bugzilla
+Requires: libreport-plugin-logger, libreport-plugin-bugzilla
#Requires: abrt-plugin-firefox
Obsoletes: bug-buddy > 0.0.1
Provides: bug-buddy
@@ -210,8 +163,10 @@ Virtual package to make easy default installation on desktop environments.
%prep
%setup -q
-%patch0 -p1 -b .blacklist
-%patch1 -p1 -b bz_for_oops
+%patch0 -p1
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
%build
autoconf
@@ -383,10 +338,12 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%{_bindir}/abrt-action-save-package-data
%{_bindir}/abrt-retrace-client
%config(noreplace) %{_sysconfdir}/%{name}/abrt.conf
+%config(noreplace) %{_sysconfdir}/%{name}/abrt-action-save-package-data.conf
%config(noreplace) %{_sysconfdir}/%{name}/gpg_keys
%config(noreplace) %{_sysconfdir}/libreport/events.d/abrt_event.conf
%config(noreplace) %{_sysconfdir}/dbus-1/system.d/dbus-abrt.conf
%config(noreplace) %{_sysconfdir}/libreport/events.d/smart_event.conf
+%config(noreplace) %{_sysconfdir}/libreport/events.d/smolt_event.conf
%dir %attr(0755, abrt, abrt) %{_localstatedir}/spool/%{name}
%dir %attr(0700, abrt, abrt) %{_localstatedir}/spool/%{name}-upload
%dir %attr(0775, abrt, abrt) %{_localstatedir}/run/%{name}
@@ -441,16 +398,17 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%{_bindir}/abrt-action-analyze-c
%{_bindir}/abrt-action-trim-files
%attr(4755, abrt, abrt) %{_bindir}/abrt-action-install-debuginfo-to-abrt-cache
-%{_bindir}/abrt-action-analyze-core.py*
+%{_bindir}/abrt-action-analyze-core
%{_bindir}/abrt-action-install-debuginfo
%{_bindir}/abrt-action-generate-backtrace
%{_bindir}/abrt-action-analyze-backtrace
-%{_bindir}/abrt-action-list-dsos.py*
+%{_bindir}/abrt-action-list-dsos
%{_sbindir}/abrt-install-ccpp-hook
-%{_sysconfdir}/libreport/events.d/ccpp_events.conf
+%{_sysconfdir}/libreport/events.d/ccpp_event.conf
%{_sysconfdir}/libreport/events/analyze_LocalGDB.xml
%{_sysconfdir}/libreport/events/analyze_RetraceServer.xml
%{_sysconfdir}/libreport/events/analyze_xsession_errors.xml
+%{_sysconfdir}/libreport/events/analyze_Smolt.xml
%{_mandir}/man*/abrt-action-trim-files.*
%{_mandir}/man*/abrt-action-generate-backtrace.*
%{_mandir}/man*/abrt-action-analyze-backtrace.*
@@ -458,57 +416,20 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%files addon-kerneloops
%defattr(-,root,root,-)
-%config(noreplace) %{_sysconfdir}/libreport/plugins/Kerneloops.conf
-%{_sysconfdir}/libreport/events/report_Kerneloops.xml
-%config(noreplace) %{_sysconfdir}/libreport/events.d/koops_events.conf
+%config(noreplace) %{_sysconfdir}/libreport/events.d/koops_event.conf
%if %{with systemd}
/lib/systemd/system/abrt-oops.service
%else
%{_initrddir}/abrt-oops
%endif
-%{_mandir}/man*/abrt-action-kerneloops.*
%{_bindir}/abrt-dump-oops
%{_bindir}/abrt-action-analyze-oops
-%{_bindir}/abrt-action-kerneloops
-
-%files plugin-logger
-%defattr(-,root,root,-)
-%{_sysconfdir}/libreport/events/report_Logger.conf
-%{_bindir}/abrt-action-print
-%{_mandir}/man*/abrt-action-print.*
-
-%files plugin-mailx
-%defattr(-,root,root,-)
-%{_sysconfdir}/libreport/events/report_Mailx.xml
-%config(noreplace) %{_sysconfdir}/libreport/events.d/mailx_events.conf
-%{_mandir}/man*/abrt-action-mailx.*
-%{_bindir}/abrt-action-mailx
-
-%files plugin-bugzilla
-%defattr(-,root,root,-)
-%config(noreplace) %{_sysconfdir}/libreport/plugins/Bugzilla.conf
-%{_sysconfdir}/libreport/events/report_Bugzilla.xml
-%config(noreplace) %{_sysconfdir}/libreport/events/report_Bugzilla.conf
-# FIXME: remove with the old gui
-%{_mandir}/man1/abrt-action-bugzilla.1.gz
-%{_bindir}/abrt-action-bugzilla
-
-%files plugin-rhtsupport
-%defattr(-,root,root,-)
-%{_sysconfdir}/libreport/events/report_RHTSupport.xml
-%config(noreplace) %{_sysconfdir}/libreport/events.d/rhtsupport_events.conf
-# {_mandir}/man7/abrt-RHTSupport.7.gz
-%{_bindir}/abrt-action-rhtsupport
-
-%files plugin-reportuploader
-%defattr(-,root,root,-)
-%config(noreplace) %{_sysconfdir}/libreport/plugins/Upload.conf
-%{_mandir}/man*/abrt-action-upload.*
-%{_bindir}/abrt-action-upload
+%{_mandir}/man1/abrt-action-analyze-oops.1*
%files addon-python
%defattr(-,root,root,-)
-%config(noreplace) %{_sysconfdir}/%{name}/plugins/Python.conf
+#%config(noreplace) %{_sysconfdir}/%{name}/plugins/Python.conf
+%{_sysconfdir}/libreport/events.d/python_event.conf
%{_bindir}/abrt-action-analyze-python
%{python_site}/abrt*.py*
%{python_site}/abrt.pth
@@ -521,6 +442,13 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%defattr(-,root,root,-)
%changelog
+* Thu Jul 21 2011 Jiri Moskovcak <jmoskovc at redhat.com> - 2.0.4-1
+- new upstream version
+- resolves wrong provs/obsolete rhbz#723376
+- split main UI into two panes
+- debuginfo-install script asks before downloading
+- Resolves: #723376
+
* Mon Jun 20 2011 Jiri Moskovcak <jmoskovc at redhat.com> - 2.0.3-1
- new upstream release
diff --git a/blacklist.patch b/blacklist.patch
index cc5c51c..47d8daf 100644
--- a/blacklist.patch
+++ b/blacklist.patch
@@ -1,7 +1,6 @@
-diff -urp abrt-2.0.0/src/daemon/abrt.conf abrt-2.0.0_/src/daemon/abrt.conf
---- abrt-2.0.0/src/daemon/abrt.conf 2011-03-23 18:11:00.000000000 +0100
-+++ abrt-2.0.0_/src/daemon/abrt.conf 2011-03-30 15:40:51.160618948 +0200
-@@ -8,7 +8,7 @@ OpenGPGCheck = yes
+--- abrt-2.0.4/src/daemon/abrt-action-save-package-data.conf 2011-07-15 13:10:46.000000000 +0200
++++ abrt-2.0.4_/src/daemon/abrt-action-save-package-data.conf 2011-07-19 15:12:43.661630657 +0200
+@@ -7,7 +7,7 @@
# Blacklisted packages
#
@@ -10,12 +9,9 @@ diff -urp abrt-2.0.0/src/daemon/abrt.conf abrt-2.0.0_/src/daemon/abrt.conf
# Process crashes in executables which do not belong to any package?
#
-@@ -16,7 +16,7 @@ ProcessUnpackaged = no
+@@ -15,4 +15,4 @@
# Blacklisted executable paths (shell patterns)
#
-BlackListedPaths = /usr/share/doc/*,*/example*
+BlackListedPaths = /usr/share/doc/*, */example*, /usr/bin/nspluginviewer, /usr/lib/xulrunner-*/plugin-container
-
- # Enable this if you want abrtd to auto-unpack crashdump tarballs which appear
- # in this directory (for example, uploaded via ftp, scp etc).
More information about the scm-commits
mailing list