Compilation error under Ubuntu 11.10
Posted: Tue Dec 06, 2011 11:10 pm
While attempting to build Exult on Ubuntu 11.10, 32-bit, I ran across this fun compilation error:
In file included from databuf.h:27:0,
from U7file.h:26,
from Flat.h:25,
from Flat.cc:26:
U7obj.h:144:2: error: ‘ptrdiff_t’ does not name a type
In file included from U7file.h:26:0,
from Flat.h:25,
from Flat.cc:26:
databuf.h: In member function ‘virtual bool BufferDataSource::eof()’:
databuf.h:306:59: error: expected type-specifier before ‘ptrdiff_t’
databuf.h:306:59: error: expected ‘>’ before ‘ptrdiff_t’
databuf.h:306:59: error: expected ‘(’ before ‘ptrdiff_t’
databuf.h:306:59: error: ‘ptrdiff_t’ was not declared in this scope
databuf.h:306:59: note: suggested alternatives:
/usr/include/c++/4.6/i686-linux-gnu/./bits/c++config.h:156:28: note: ‘std::ptrdiff_t’
/usr/include/c++/4.6/i686-linux-gnu/./bits/c++config.h:156:28: note: ‘std::ptrdiff_t’
databuf.h:306:75: error: expected ‘)’ before ‘;’ token
// Version information for everything, I used apt-get build-dep exult to pull in header dependencies, hopefully I have everything.
Exult v1.4.9rc1
SDL ....................... : 1.2.14
GLIB ...................... : 2.30.0
GTK+ ...................... : 2.24.6
libGlade .................. : 2.6.4
Build tools................ : yes
Build usecode compiler..... : yes
Build Exult mods........... : yes
Build ExultStudio.......... : no
In file included from databuf.h:27:0,
from U7file.h:26,
from Flat.h:25,
from Flat.cc:26:
U7obj.h:144:2: error: ‘ptrdiff_t’ does not name a type
In file included from U7file.h:26:0,
from Flat.h:25,
from Flat.cc:26:
databuf.h: In member function ‘virtual bool BufferDataSource::eof()’:
databuf.h:306:59: error: expected type-specifier before ‘ptrdiff_t’
databuf.h:306:59: error: expected ‘>’ before ‘ptrdiff_t’
databuf.h:306:59: error: expected ‘(’ before ‘ptrdiff_t’
databuf.h:306:59: error: ‘ptrdiff_t’ was not declared in this scope
databuf.h:306:59: note: suggested alternatives:
/usr/include/c++/4.6/i686-linux-gnu/./bits/c++config.h:156:28: note: ‘std::ptrdiff_t’
/usr/include/c++/4.6/i686-linux-gnu/./bits/c++config.h:156:28: note: ‘std::ptrdiff_t’
databuf.h:306:75: error: expected ‘)’ before ‘;’ token
// Version information for everything, I used apt-get build-dep exult to pull in header dependencies, hopefully I have everything.
Exult v1.4.9rc1
SDL ....................... : 1.2.14
GLIB ...................... : 2.30.0
GTK+ ...................... : 2.24.6
libGlade .................. : 2.6.4
Build tools................ : yes
Build usecode compiler..... : yes
Build Exult mods........... : yes
Build ExultStudio.......... : no