[Pkg-kde-extras] Bug#417714: FTBFS with GCC 4.3: missing #includes

Martin Michlmayr tbm at cyrius.com
Wed Apr 4 11:53:09 UTC 2007


Package: strigi
Version: 0.3.9-1
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 (20070326-1 or higher)
from unstable. (Currently not available for i386, but for amd64, powerpc
and ia64.  I hope to have i386 binaries in the archive in ~3 weeks.)

> Automatic build of strigi_0.3.9-1 on em64t by sbuild/amd64 0.53
...
> /usr/lib/gcc-snapshot/bin/c++   -Wall -g3 -O0 -ansi -O2 -g -I/usr/include/log4cxx -I/build/tbm/strigi-0.3.9/./src/filters/../streams -I/build/tbm/strigi-0.3.9/./src/filters/../streamindexer   -fPIC -DHAVE_LOG4CXX -o src/filters/CMakeFiles/filters.dir/filters.o -c /build/tbm/strigi-0.3.9/./src/filters/filters.cpp
> /usr/bin/cmake -E cmake_progress_report /build/tbm/strigi-0.3.9/./obj-x86_64-linux-gnu/CMakeFiles 1
> [  1%] Building CXX object src/filters/CMakeFiles/filters.dir/filtermanager.o
> /usr/lib/gcc-snapshot/bin/c++   -Wall -g3 -O0 -ansi -O2 -g -I/usr/include/log4cxx -I/build/tbm/strigi-0.3.9/./src/filters/../streams -I/build/tbm/strigi-0.3.9/./src/filters/../streamindexer   -fPIC -DHAVE_LOG4CXX -o src/filters/CMakeFiles/filters.dir/filtermanager.o -c /build/tbm/strigi-0.3.9/./src/filters/filtermanager.cpp
> In file included from /build/tbm/strigi-0.3.9/./src/filters/filtermanager.cpp:22:
> /build/tbm/strigi-0.3.9/./src/filters/filtermanager.h:55: error: 'uint' has not been declared
> /build/tbm/strigi-0.3.9/./src/filters/filtermanager.cpp:59: error: prototype for 'bool FilterManager::findMatch(const char*, uint)' does not match any in class 'FilterManager'
> /build/tbm/strigi-0.3.9/./src/filters/filtermanager.h:55: error: candidates are: bool FilterManager::findMatch(const char*, int)
> /build/tbm/strigi-0.3.9/./src/filters/filtermanager.h:48: error:                 bool FilterManager::findMatch(std::string&)

--- src/sqliteindexer/sqliteindexwriter.cpp~	2007-04-04 11:37:21.000000000 +0000
+++ src/sqliteindexer/sqliteindexwriter.cpp	2007-04-04 11:37:29.000000000 +0000
@@ -19,6 +19,7 @@
  */
 #include "sqliteindexwriter.h"
 #include "sqliteindexmanager.h"
+#include <cstdlib>
 #include <vector>
 #include <sstream>
 #include <cassert>
--- src/sqliteindexer/sqliteindexmanager.cpp~	2007-04-04 11:37:37.000000000 +0000
+++ src/sqliteindexer/sqliteindexmanager.cpp	2007-04-04 11:37:46.000000000 +0000
@@ -21,6 +21,7 @@
 #include "sqliteindexreader.h"
 #include "sqliteindexwriter.h"
 #include "strigi_thread.h"
+#include <cstdlib>
 using namespace std;
 using namespace jstreams;
 
--- src/sqliteindexer/sqliteindexreader.cpp~	2007-04-04 11:38:06.000000000 +0000
+++ src/sqliteindexer/sqliteindexreader.cpp	2007-04-04 11:38:12.000000000 +0000
@@ -19,6 +19,7 @@
  */
 #include "sqliteindexreader.h"
 #include "sqliteindexmanager.h"
+#include <cstdlib>
 #include <set>
 #include <sstream>
 using namespace std;
--- src/luceneindexer/tests/CLuceneTest.cpp~	2007-04-04 11:46:57.000000000 +0000
+++ src/luceneindexer/tests/CLuceneTest.cpp	2007-04-04 11:47:02.000000000 +0000
@@ -5,6 +5,7 @@
 #include "indexreadertests.h"
 #include <sys/stat.h>
 #include <sys/types.h>
+#include <cstdlib>
 
 int
 CLuceneTest(int argc, char**argv) {
--- src/daemon/eventlistener/pollinglistener.h~	2007-04-04 11:39:58.000000000 +0000
+++ src/daemon/eventlistener/pollinglistener.h	2007-04-04 11:40:06.000000000 +0000
@@ -22,6 +22,7 @@
 
 #include "eventlistener.h"
 
+#include <cstdlib>
 #include <map>
 #include <pthread.h>
 
--- src/daemon/dbus/dbusserver.cpp~	2007-04-04 11:40:26.000000000 +0000
+++ src/daemon/dbus/dbusserver.cpp	2007-04-04 11:40:34.000000000 +0000
@@ -23,6 +23,7 @@
 #include "dbusclientinterface.h"
 #include "testinterface.h"
 #include "dbustestinterface.h"
+#include <cstdlib>
 using namespace std;
 
 void*
--- src/daemon/socketclient.cpp~	2007-04-04 11:38:29.000000000 +0000
+++ src/daemon/socketclient.cpp	2007-04-04 11:38:43.000000000 +0000
@@ -24,6 +24,7 @@
 #include <sys/un.h>
 #include <errno.h>
 #include <assert.h>
+#include <cstdlib>
 #include <sstream>
 using namespace std;
 
--- src/daemon/asyncsocket.h~	2007-04-04 11:39:21.000000000 +0000
+++ src/daemon/asyncsocket.h	2007-04-04 11:39:30.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef ASYNCSOCKET_H
 #define ASYNCSOCKET_H
 
+#include <cstdlib>
 #include <string>
 
 class AsyncSocket {
--- src/daemon/indexscheduler.h~	2007-04-04 11:41:09.000000000 +0000
+++ src/daemon/indexscheduler.h	2007-04-04 11:41:20.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef INDEXSCHEDULER_H
 #define INDEXSCHEDULER_H
 
+#include <cstdlib>
 #include <map>
 #include <string>
 #include <set>
--- src/daemon/socketserver.cpp~	2007-04-04 11:41:45.000000000 +0000
+++ src/daemon/socketserver.cpp	2007-04-04 11:41:51.000000000 +0000
@@ -27,6 +27,7 @@
 #include <sys/un.h>
 #include <errno.h>
 #include <assert.h>
+#include <cstdlib>
 using namespace std;
 
 #if defined(__APPLE__)
--- src/filters/filtermanager.h~	2007-04-04 11:27:40.000000000 +0000
+++ src/filters/filtermanager.h	2007-04-04 11:27:46.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef FILTERMANAGER_H
 #define FILTERMANAGER_H
 
+#include <cstdlib>
 #include <map>
 #include <string>
 #include "strigi_thread.h"
--- src/htmlgui/strigihtmlgui.cpp~	2007-04-04 11:42:30.000000000 +0000
+++ src/htmlgui/strigihtmlgui.cpp	2007-04-04 11:42:37.000000000 +0000
@@ -27,6 +27,7 @@
 #include <sstream>
 #include <fstream>
 #include <sys/stat.h>
+#include <cstdlib>
 using namespace std;
 using namespace jstreams;
 
--- src/streamindexer/throughplugins/xattrthroughanalyzer.cpp~	2007-04-04 11:45:42.000000000 +0000
+++ src/streamindexer/throughplugins/xattrthroughanalyzer.cpp	2007-04-04 11:45:49.000000000 +0000
@@ -24,6 +24,7 @@
 #include <sys/types.h>
 #include <attr/xattr.h>
 #include <errno.h>
+#include <cstdlib>
 
 class XattrAnalyzer : public jstreams::StreamThroughAnalyzer {
 private:
--- src/streamindexer/streamindexer.h~	2007-04-04 11:30:12.000000000 +0000
+++ src/streamindexer/streamindexer.h	2007-04-04 11:30:18.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef STREAMINDEXER_H
 #define STREAMINDEXER_H
 
+#include <cstdlib>
 #include <vector>
 #include "moduleloader.h"
 
--- src/streamindexer/query.cpp~	2007-04-04 11:30:48.000000000 +0000
+++ src/streamindexer/query.cpp	2007-04-04 11:31:12.000000000 +0000
@@ -20,6 +20,8 @@
 #include "query.h"
 #include "jstreamsconfig.h"
 #include "indexreader.h"
+#include <cctype>
+#include <cstdlib>
 using namespace std;
 using namespace jstreams;
 
--- src/streamindexer/indexwriter.cpp~	2007-04-04 11:33:26.000000000 +0000
+++ src/streamindexer/indexwriter.cpp	2007-04-04 11:33:32.000000000 +0000
@@ -20,6 +20,7 @@
 #include "jstreamsconfig.h"
 #include "indexwriter.h"
 #include "textutils.h"
+#include <cstdlib>
 using namespace jstreams;
 using namespace std;
 string
--- src/streamindexer/expatsaxendanalyzer.cpp~	2007-04-04 11:33:54.000000000 +0000
+++ src/streamindexer/expatsaxendanalyzer.cpp	2007-04-04 11:34:03.000000000 +0000
@@ -23,6 +23,7 @@
 #include "inputstreamreader.h"
 #include "indexwriter.h"
 #include <expat.h>
+#include <cctype>
 using namespace jstreams;
 using namespace std;
 
--- src/streams/pdf/pdfparser.cpp~	2007-04-04 11:44:46.000000000 +0000
+++ src/streams/pdf/pdfparser.cpp	2007-04-04 11:45:10.000000000 +0000
@@ -3,6 +3,7 @@
 #include "stringterminatedsubstream.h"
 #include "gzipinputstream.h"
 #include "subinputstream.h"
+#include <cctype>
 using namespace jstreams;
 using namespace std;
 
--- src/streams/pdf/pdftest.cpp~	2007-04-04 11:45:26.000000000 +0000
+++ src/streams/pdf/pdftest.cpp	2007-04-04 11:45:31.000000000 +0000
@@ -3,6 +3,7 @@
 #include "stringreader.h"
 #include "gzipinputstream.h"
 #include "kmpsearcher.h"
+#include <cctype>
 using namespace jstreams;
 extern "C" {
     #include <magic.h>
--- src/streams/kmpsearcher.h~	2007-04-04 11:28:19.000000000 +0000
+++ src/streams/kmpsearcher.h	2007-04-04 11:28:27.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef KMPSEARCHER_H
 #define KMPSEARCHER_H
 
+#include <cstdlib>
 #include <string>
 
 namespace jstreams {
--- src/streams/substreamprovider.h~	2007-04-04 11:28:55.000000000 +0000
+++ src/streams/substreamprovider.h	2007-04-04 11:29:03.000000000 +0000
@@ -20,6 +20,7 @@
 #ifndef SUBSTREAMPROVIDER
 #define SUBSTREAMPROVIDER
 
+#include <cstdlib>
 #include <string>
 #include "streambase.h"
 

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




More information about the pkg-kde-extras mailing list