[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#417305: FTBFS with GCC 4.3: missing #includes



Package: ksimus
Version: 0.3.6-2-12
Usertags: ftbfs-gcc-4.3
Tags: patch

Your package fails to build with GCC 4.3.  Version 4.3 has not been
released yet but I'm building with a snapshot in order to find errors
and give people an advance warning.  In GCC 4.3, the C++ header
dependencies have been cleaned up.  The advantage of this is that
programs will compile faster.  The downside is that you actually
need to directly #include everything you use (but you really should
do this anyway, otherwise your program won't work with any compiler
other than GCC).  Some background of this can be found at
http://gcc.gnu.org/PR28080

You can reproduce this problem with gcc-snapshot from unstable.

> Automatic build of ksimus_0.3.6-2-12 on coconut0 by sbuild/ia64 0.49
...
> componentmap.cpp: In member function 'void ComponentMap::addRouteList(CPointListList*, mapItem)':
> componentmap.cpp:140: warning: conversion to 'unsigned int' from 'int' may alter its value
> componentmap.cpp:140: warning: conversion to 'unsigned int' from 'int' may alter its value
> componentmap.cpp: In member function 'void ComponentMap::draw(QPainter*)':
> componentmap.cpp:153: warning: conversion to 'unsigned int' from 'int' may alter its value
> componentmap.cpp: In member function 'bool ComponentMap::findRoute(ConnectorList*, CPointListList*)':
> componentmap.cpp:211: error: 'abs' was not declared in this scope
> componentmap.cpp:240: error: 'abs' was not declared in this scope


--- ksimus/componentmap.cpp~	2007-04-02 09:52:52.000000000 +0000
+++ ksimus/componentmap.cpp	2007-04-02 09:53:01.000000000 +0000
@@ -18,6 +18,7 @@
 #include <limits.h>
 #include <qpainter.h>
 #include <queue>
+#include <cstdlib>
 
 
 #include "resource.h"

-- 
Martin Michlmayr
http://www.cyrius.com/



Reply to: