[inkscape/f17] Fix build with GCC-4.7

Daniel Drake dsd at fedoraproject.org
Thu Mar 8 17:57:25 UTC 2012


commit 4a1d08a269b50c33193d4a36a1dac8b584a89c5c
Author: Daniel Drake <dsd at laptop.org>
Date:   Thu Mar 8 11:48:09 2012 -0600

    Fix build with GCC-4.7

 inkscape-0.48.2-gcc47.patch |   22 ++++++++++++++++++++++
 inkscape.spec               |    7 ++++++-
 2 files changed, 28 insertions(+), 1 deletions(-)
---
diff --git a/inkscape-0.48.2-gcc47.patch b/inkscape-0.48.2-gcc47.patch
new file mode 100644
index 0000000..cca69c6
--- /dev/null
+++ b/inkscape-0.48.2-gcc47.patch
@@ -0,0 +1,22 @@
+http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/10398
+
+=== modified file 'src/graphlayout.cpp'
+--- src/graphlayout.cpp	2010-12-12 08:40:34 +0000
++++ src/graphlayout.cpp	2011-07-02 12:08:37 +0000
+@@ -156,11 +156,12 @@
+          ++i)
+     {
+         SPItem *iu=*i;
+-        map<string,unsigned>::iterator i=nodelookup.find(iu->getId());
+-        if(i==nodelookup.end()) {
++        map<string,unsigned>::iterator i_iter=nodelookup.find(iu->getId());
++        map<string,unsigned>::iterator i_iter_end=nodelookup.end();
++        if(i_iter==i_iter_end) {
+             continue;
+         }
+-        unsigned u=i->second;
++        unsigned u=i_iter->second;
+         GSList *nlist=iu->avoidRef->getAttachedConnectors(Avoid::runningFrom);
+         list<SPItem *> connectors;
+ 
+
diff --git a/inkscape.spec b/inkscape.spec
index ffdc10d..7dbd5ac 100644
--- a/inkscape.spec
+++ b/inkscape.spec
@@ -1,6 +1,6 @@
 Name:           inkscape
 Version:        0.48.2
-Release:        3%{?dist}
+Release:        4%{?dist}
 Summary:        Vector-based drawing program using SVG
 
 Group:          Applications/Productivity
@@ -11,6 +11,7 @@ Patch0:         inkscape-0.48.2-types.patch
 Patch4:         inkscape-0.48.2-glib.patch
 Patch5:         inkscape-0.48.2-png.patch
 Patch6:         inkscape-0.48.2-png-write.patch
+Patch7:         inkscape-0.48.2-gcc47.patch
 
 BuildRequires:  atk-devel
 BuildRequires:  desktop-file-utils
@@ -124,6 +125,7 @@ graphics in W3C standard Scalable Vector Graphics (SVG) file format.
 %patch4 -p1 -b .glib
 %patch5 -p0 -b .png
 %patch6 -p0 -b .png-write
+%patch7 -p0 -b .gcc47
 
 # https://bugs.launchpad.net/inkscape/+bug/314381
 # A couple of files have executable bits set,
@@ -235,6 +237,9 @@ fi
 
 
 %changelog
+* Thu Mar  8 2012 Daniel Drake <dsd at laptop.org> - 0.48.2-4
+- Fix build with GCC 4.7
+
 * Tue Feb 28 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.48.2-3
 - Rebuilt for c++ ABI breakage
 


More information about the scm-commits mailing list