Fix build

This commit is contained in:
Jakub Filak 2014-01-08 19:27:37 +01:00
parent 16d11240a4
commit 0ecc49267d
3 changed files with 66 additions and 1 deletions

View File

@ -0,0 +1,26 @@
diff -ruN libreport-2.1.11/configure libreport-2.1.11.fix/configure
--- libreport-2.1.11/configure 2014-01-08 18:46:48.057001105 +0100
+++ libreport-2.1.11.fix/configure 2014-01-08 18:46:33.880000782 +0100
@@ -17814,7 +17814,8 @@
AUTOM4TE=${AUTOM4TE-"${am_missing_run}autom4te"}
# Needed by tests/atlocal.in.
-O0CFLAGS=`echo $CFLAGS | sed 's/-O[0-9] *//' | sed 's/-Werror//'`
+# CFLAGS may contain '-Werror=format-security'
+O0CFLAGS=`echo $CFLAGS | sed 's/-O[[0-9]] *//' | sed 's/-Werror\(=[^ ]*\)\?//g'`
ac_config_headers="$ac_config_headers config.h"
diff -ruN libreport-2.1.11/configure.ac libreport-2.1.11.fix/configure.ac
--- libreport-2.1.11/configure.ac 2013-12-10 10:16:15.000000000 +0100
+++ libreport-2.1.11.fix/configure.ac 2014-01-08 18:46:33.857000781 +0100
@@ -307,7 +307,8 @@
AC_CONFIG_FILES([tests/Makefile tests/atlocal])
AM_MISSING_PROG([AUTOM4TE], [autom4te])
# Needed by tests/atlocal.in.
-AC_SUBST([O0CFLAGS], [`echo $CFLAGS | sed 's/-O[[0-9]] *//' | sed 's/-Werror//'`])
+# CFLAGS may contain '-Werror=format-security'
+AC_SUBST([O0CFLAGS], [`echo $CFLAGS | sed 's/-O[[0-9]] *//' | sed 's/-Werror\(=[[^ ]]*\)\?//g'`])
AC_CONFIG_HEADERS([config.h])

View File

@ -0,0 +1,29 @@
From c193f2d12a6abed6b7e30ba2431e52913dddc26d Mon Sep 17 00:00:00 2001
From: Jakub Filak <jfilak@redhat.com>
Date: Wed, 8 Jan 2014 09:38:30 +0100
Subject: [LIBREPORT PATCH] wizard: do not use deprecated gtk3 API
Signed-off-by: Jakub Filak <jfilak@redhat.com>
---
src/gui-wizard-gtk/wizard.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/gui-wizard-gtk/wizard.c b/src/gui-wizard-gtk/wizard.c
index c37f69f..3faa8e8 100644
--- a/src/gui-wizard-gtk/wizard.c
+++ b/src/gui-wizard-gtk/wizard.c
@@ -2597,7 +2597,11 @@ static void add_workflow_buttons(GtkBox *box, GHashTable *workflows, GCallback f
gtk_label_set_use_markup(GTK_LABEL(label), true);
gtk_widget_set_halign(label, GTK_ALIGN_START);
gtk_widget_set_margin_top(label, 10);
+#if ((GTK_MAJOR_VERSION == 3 && GTK_MINOR_VERSION < 11) || (GTK_MAJOR_VERSION == 3 && GTK_MINOR_VERSION == 11 && GTK_MICRO_VERSION < 2))
gtk_widget_set_margin_left(label, 40);
+#else
+ gtk_widget_set_margin_start(label, 40);
+#endif
gtk_widget_set_margin_bottom(label, 10);
free(btn_label);
g_signal_connect(button, "clicked", func, w);
--
1.8.3.1

View File

@ -7,13 +7,17 @@
Summary: Generic library for reporting various problems Summary: Generic library for reporting various problems
Name: libreport Name: libreport
Version: 2.1.11 Version: 2.1.11
Release: 2%{?dist} Release: 3%{?dist}
License: GPLv2+ License: GPLv2+
Group: System Environment/Libraries Group: System Environment/Libraries
URL: https://fedorahosted.org/abrt/ URL: https://fedorahosted.org/abrt/
Source: https://fedorahosted.org/released/abrt/%{name}-%{version}.tar.gz Source: https://fedorahosted.org/released/abrt/%{name}-%{version}.tar.gz
Source1: autogen.sh Source1: autogen.sh
# Remove with libreport > 2.1.11
Patch1: libreport-2.1.11-get_rid_of_gtk3_deprecated_functions.patch
Patch2: libreport-2.1.11-fix_0CFLAGS_in_configure.patch
BuildRequires: dbus-devel BuildRequires: dbus-devel
BuildRequires: gtk3-devel BuildRequires: gtk3-devel
BuildRequires: curl-devel BuildRequires: curl-devel
@ -289,6 +293,8 @@ data over ftp/scp...
%prep %prep
%setup -q %setup -q
%patch1 -p1
%patch2 -p1
# koji in f19 has new autotools, so we need to regenerate everything # koji in f19 has new autotools, so we need to regenerate everything
cp %SOURCE1 %_builddir/%{name}-%{version} cp %SOURCE1 %_builddir/%{name}-%{version}
@ -603,6 +609,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%changelog %changelog
* Wed Jan 8 2014 Peter Robinson <pbrobinson@fedoraproject.org> 2.1.11-3
- Don't use deprecated GTK3 API
- Fix unit tests
* Wed Jan 8 2014 Peter Robinson <pbrobinson@fedoraproject.org> 2.1.11-2 * Wed Jan 8 2014 Peter Robinson <pbrobinson@fedoraproject.org> 2.1.11-2
- Build latest version on F-21/rawhide - Build latest version on F-21/rawhide
- Fix descriptions - Fix descriptions