[krecipes] Fix FTBFS with g++ 4.7

Kevin Kofler kkofler at fedoraproject.org
Tue Jul 31 22:12:25 UTC 2012


commit 651e562f01bdcd3802fa8493e1cae16a41f9ff6a
Author: Kevin Kofler <Kevin at tigcc.ticalc.org>
Date:   Wed Aug 1 00:11:38 2012 +0200

    Fix FTBFS with g++ 4.7
    
    * Tue Jul 31 2012 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.0-0.6.beta2
    - Fix FTBFS with g++ 4.7

 krecipes-1.0-beta2-gcc47.patch |   19 +++++++++++++++++++
 krecipes.spec                  |    8 +++++++-
 2 files changed, 26 insertions(+), 1 deletions(-)
---
diff --git a/krecipes-1.0-beta2-gcc47.patch b/krecipes-1.0-beta2-gcc47.patch
new file mode 100644
index 0000000..064e6e9
--- /dev/null
+++ b/krecipes-1.0-beta2-gcc47.patch
@@ -0,0 +1,19 @@
+diff -ur krecipes-1.0-beta2/krecipes/src/dialogs/ingredientsdialog.cpp krecipes-1.0-beta2-gcc47/krecipes/src/dialogs/ingredientsdialog.cpp
+--- krecipes-1.0-beta2/krecipes/src/dialogs/ingredientsdialog.cpp	2009-04-22 23:49:34.000000000 +0200
++++ krecipes-1.0-beta2-gcc47/krecipes/src/dialogs/ingredientsdialog.cpp	2012-08-01 00:05:12.000000000 +0200
+@@ -551,12 +551,12 @@
+ 			QListViewItem * lastElement = weightsListView->listView() ->lastItem();
+ 
+ 			Weight w = *weight_it;
+-			WeightListItem *weight_it = new WeightListItem( weightsListView->listView(), lastElement, w );
+-			weight_it->setAmountUnit( w.perAmount,
++			WeightListItem *weight_item = new WeightListItem( weightsListView->listView(), lastElement, w );
++			weight_item->setAmountUnit( w.perAmount,
+ 			  database->unitName(w.perAmountUnitID),
+ 			  Element((w.prepMethodID==-1)?QString::null:database->prepMethodName(w.prepMethodID),w.prepMethodID)
+ 			);
+-			weight_it->setWeightUnit( w.weight, database->unitName(w.weightUnitID) );
++			weight_item->setWeightUnit( w.weight, database->unitName(w.weightUnitID) );
+ 		}
+ 	}
+ }
diff --git a/krecipes.spec b/krecipes.spec
index ee0dc0c..68c3770 100644
--- a/krecipes.spec
+++ b/krecipes.spec
@@ -1,12 +1,14 @@
 Name:           krecipes
 Version:        1.0
-Release:        0.5.beta2%{?dist}
+Release:        0.6.beta2%{?dist}
 Summary:        Application to manage recipes and shopping-lists
 
 Group:          Applications/Productivity
 License:        GPLv2+
 URL:            http://krecipes.sourceforge.net/
 Source0:        http://download.sourceforge.net/krecipes/krecipes-%{version}-beta2.tar.gz
+# fix FTBFS with g++ 4.7
+Patch0:         krecipes-1.0-beta2-gcc47.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  desktop-file-utils
@@ -24,6 +26,7 @@ your menu/diet in advance.
 
 %prep
 %setup -q -n %{name}-%{version}-beta2
+%patch0 -p1 -b .gcc47
 
 %build
 unset QTDIR || : ; . /etc/profile.d/qt.sh
@@ -86,6 +89,9 @@ touch --no-create %{_datadir}/icons/crystalsvg || :
 %{_datadir}/mimelnk/*/*.desktop
 
 %changelog
+* Tue Jul 31 2012 Kevin Kofler <Kevin at tigcc.ticalc.org> - 1.0-0.6.beta2
+- Fix FTBFS with g++ 4.7
+
 * Thu Jul 19 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0-0.5.beta2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
 


More information about the scm-commits mailing list