## 06_gcc-4.4.dpatch by Wolfram Quester ## ## DP: Patch by Martin Michlmayr to make inkscape compile with ## DP: gcc 4.4. His bug report and description: ## DP: Your package fails to build with the upcoming GCC 4.4. Version 4.4 ## DP: has not been released yet but I'm building with a snapshot in order ## DP: to find errors and give people an advance warning. ## DP: ## DP: GCC 4.4 cleaned up some more C++ headers. You always have to #include ## DP: headers directly and cannot rely for things to be included indirectly. ## DP: ## DP: You can reproduce this problem with gcc-snapshot from unstable. ## DP: ## DP: > Automatic build of inkscape_0.46-3 on em64t by sbuild/amd64 0.53 ## DP: ... ## DP: > x86_64-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I.. -I/usr/include/freetype2 -pthread -DORBIT2=1 -I/usr/include/gnome-vfs-2.0 -I/usr/lib/gnome-vfs-2.0/include -I/usr/include/gconf/2 -I/usr/include/orbit-2.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DRELAYTOOL_CRYPTO='static const int libcrypto_is_present = 1; static int __attribute__((unused)) libcrypto_symbol_is_present(char *m) { return 1; }' -DRELAYTOOL_SSL='static const int libssl_is_present = 1; static int __attribute__((unused)) libssl_symbol_is_present(char *m) { return 1; }' -DHAVE_SSL -I/usr/include/libwpg-0.1 -I/usr/include/libwpd-0.8 -I/usr/include/freetype2 -I/usr/include/poppler -D_REENTRANT -I/usr/include/poppler/glib -I/usr/include/poppler -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/directfb -I/usr/include/libpng12 -I/usr/include/pixman-1 -DPOTRACE=\"potrace\" -D_REENTRANT -pthread -I/usr/include/gdkmm-2.4 -I/usr/lib/gdkmm-2.4/include -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include -I/usr/include/pangomm-1.4 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/cairomm-1.0 -I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pango-1.0 -I/usr/include/cairo -I/usr/include/freetype2 -I/usr/include/directfb -I/usr/include/libpng12 -I/usr/include/pixman-1 -I/usr/include/gtkmm-2.4 -I/usr/lib/gtkmm-2.4/include -I/usr/include/atkmm-1.6 -I/usr/include/atk-1.0 -I/usr/include/libxml2 -I/usr/include/gtkspell-2.0 -I../cxxtest -Wall -g -O2 -MT conn-avoid-ref.o -MD -MP -MF $depbase.Tpo -c -o conn-avoid-ref.o conn-avoid-ref.cpp &&\ ## DP: > mv -f $depbase.Tpo $depbase.Po ## DP: > In file included from ./libavoid/graph.h:30, ## DP: > from libavoid/router.h:30, ## DP: > from conn-avoid-ref.cpp:20: ## DP: > ./libavoid/vertices.h:60: error: 'stdout' was not declared in this scope ## DP: > ./libavoid/vertices.h: In member function 'void Avoid::VertInfList::stats()': ## DP: > ./libavoid/vertices.h:103: error: 'printf' was not declared in this scope ## DP: > make[3]: *** [conn-avoid-ref.o] Error 1 ## DP: > make[3]: Leaving directory `/build/tbm/inkscape-0.46/src' --- src/xml/event.cpp~ 2008-11-14 08:27:20.000000000 +0000 +++ inkscape-0.46/src/xml/event.cpp 2008-11-14 08:27:26.000000000 +0000 @@ -14,6 +14,7 @@ */ #include // g_assert() +#include #include "event.h" #include "event-fns.h" --- src/io/inkscapestream.h~ 2008-11-14 08:02:53.000000000 +0000 +++ inkscape-0.46/src/io/inkscapestream.h 2008-11-14 08:03:00.000000000 +0000 @@ -12,6 +12,7 @@ */ +#include #include namespace Inkscape --- src/io/sys.cpp~ 2008-11-14 08:04:54.000000000 +0000 +++ inkscape-0.46/src/io/sys.cpp 2008-11-14 08:05:11.000000000 +0000 @@ -22,6 +22,8 @@ #include #include +#include + #include "prefs-utils.h" #include "sys.h" --- src/dom/io/domstream.h~ 2008-11-14 07:51:18.000000000 +0000 +++ inkscape-0.46/src/dom/io/domstream.h 2008-11-14 07:51:28.000000000 +0000 @@ -33,6 +33,8 @@ #include +#include + namespace org { namespace w3c --- src/dom/svg/svgtypes.h~ 2008-11-14 07:53:23.000000000 +0000 +++ inkscape-0.46/src/dom/svg/svgtypes.h 2008-11-14 07:53:32.000000000 +0000 @@ -47,6 +47,7 @@ #include "dom/smil.h" +#include #include --- src/dom/domimpl.cpp~ 2008-11-14 07:49:10.000000000 +0000 +++ inkscape-0.46/src/dom/domimpl.cpp 2008-11-14 07:49:18.000000000 +0000 @@ -30,6 +30,8 @@ #include "domimpl.h" +#include + namespace org { namespace w3c --- src/dom/xpathtoken.h~ 2008-11-14 07:52:27.000000000 +0000 +++ inkscape-0.46/src/dom/xpathtoken.h 2008-11-14 07:52:36.000000000 +0000 @@ -35,6 +35,7 @@ #include +#include #include namespace org --- src/libavoid/vertices.h~ 2008-11-14 07:14:36.000000000 +0000 +++ inkscape-0.46/src/libavoid/vertices.h 2008-11-14 07:14:41.000000000 +0000 @@ -23,6 +23,7 @@ #ifndef AVOID_VERTICES_H #define AVOID_VERTICES_H +#include #include #include #include --- src/libnr/nr-matrix-fns.cpp~ 2008-11-14 08:16:43.000000000 +0000 +++ inkscape-0.46/src/libnr/nr-matrix-fns.cpp 2008-11-14 08:16:48.000000000 +0000 @@ -1,5 +1,7 @@ #include +#include + namespace NR { Matrix elliptic_quadratic_form(Matrix const &m) { --- src/libnr/nr-matrix.cpp~ 2008-11-14 08:19:20.000000000 +0000 +++ inkscape-0.46/src/libnr/nr-matrix.cpp 2008-11-14 08:19:26.000000000 +0000 @@ -11,6 +11,7 @@ * This code is in public domain */ +#include #include #include "nr-matrix.h" --- src/2geom/svg-path-parser.h~ 2008-11-14 08:06:45.000000000 +0000 +++ inkscape-0.46/src/2geom/svg-path-parser.h 2008-11-14 08:06:51.000000000 +0000 @@ -32,6 +32,7 @@ #ifndef SEEN_SVG_PATH_PARSER_H #define SEEN_SVG_PATH_PARSER_H +#include #include #include #include --- src/2geom/sbasis-math.cpp~ 2008-11-14 08:29:42.000000000 +0000 +++ inkscape-0.46/src/2geom/sbasis-math.cpp 2008-11-14 08:31:32.000000000 +0000 @@ -38,11 +38,11 @@ //#define ZERO 1e-3 -namespace Geom { +#include +#include +namespace Geom { -#include -#include //-|x|----------------------------------------------------------------------- Piecewise abs(SBasis const &f){ --- src/streams-handles.cpp~ 2008-11-14 07:41:07.000000000 +0000 +++ inkscape-0.46/src/streams-handles.cpp 2008-11-14 07:41:14.000000000 +0000 @@ -12,6 +12,7 @@ #include "streams-handles.h" #include "uri.h" +#include #include namespace Inkscape { --- src/streams-zlib.cpp~ 2008-11-14 07:41:24.000000000 +0000 +++ inkscape-0.46/src/streams-zlib.cpp 2008-11-14 07:41:30.000000000 +0000 @@ -9,6 +9,7 @@ * Released under GNU LGPL, read the file 'COPYING.LIB' for more information */ +#include #include #include #include --- src/dom/io/socket.cpp~ 2008-03-11 05:19:32.000000000 +0100 +++ inkscape-0.46/src/dom/io/socket.cpp 2009-05-26 12:09:45.000000000 +0200 @@ -57,6 +57,7 @@ RELAYTOOL_SSL #endif +#include namespace org {