Hello David, Below is a bugreport I got about the Debian package of kobodeluxe. As far as I can tell (with my limitted C++ knowledge), the pipe2 symbol declaration in enemies.h collides with the one in unistd.h.
This was built OK before, but since then Debian has new GCC and libc so I suspect they may have become more strict (or buggy?). The patch attached seems to work around the problem by renaming pipe2 to pipe2_kbdl, but I guess usage of namespaces or something like that should be the proper fix. Or, I may be completely off-track. The bug log is available at http://bugs.debian.org/527705 It would e nice if you keep 527...@bugs.debian.org in Cc. Thanks for looking into this. Damyan -=| Lucas Nussbaum, Fri, May 08, 2009 at 07:25:16PM +0200 |=- > Package: kobodeluxe > Version: 0.5.1-3 > Severity: serious > User: debian...@lists.debian.org > Usertags: qa-ftbfs-20090508 qa-ftbfs > Justification: FTBFS on amd64 > > Hi, > > During a rebuild of all packages in sid, your package failed to build on > amd64. > > Relevant part: > > if g++ -DHAVE_CONFIG_H -I. -I. -I. > > -DKOBO_DATA_DIR=\""/usr/share/kobo-deluxe"\" > > -DKOBO_SCORE_DIR=\""/var/games/kobo-deluxe/scores"\" > > -DKOBO_CONFIG_DIR=\""HOME>>"\" -DKOBO_CONFIG_FILE=\"".kobodlrc"\" > > -DSYSCONF_DIR=\""/etc"\" -Isound -Igraphics -Ieel -Idata/sfx -g -O2 > > -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT -DHAVE_OPENGL -MT manage.o > > -MD -MP -MF ".deps/manage.Tpo" \ > > -c -o manage.o `test -f 'manage.cpp' || echo './'`manage.cpp; \ > > then mv -f ".deps/manage.Tpo" ".deps/manage.Po"; \ > > else rm -f ".deps/manage.Tpo"; exit 1; \ > > fi > > In file included from scenes.h:28, > > from manage.cpp:44: > > enemies.h:75: error: 'const enemy_kind pipe2' redeclared as different kind > > of symbol > > /usr/include/unistd.h:389: error: previous declaration of 'int pipe2(int*, > > int)' > > enemies.h: In member function 'int _enemy::is_pipe()': > > enemies.h:433: error: comparison between distinct pointer types 'const > > enemy_kind*' and 'int (*)(int*, int)throw ()' lacks a cast > > make[3]: *** [manage.o] Error 1 > > The full build log is available from: > > http://people.debian.org/~lucas/logs/2009/05/08/kobodeluxe_0.5.1-3_lsid64.buildlog -- dam
--- a/enemies.h +++ b/enemies.h @@ -72,7 +72,7 @@ extern const enemy_kind bombdeto; extern const enemy_kind cannon; extern const enemy_kind pipe1; extern const enemy_kind core; -extern const enemy_kind pipe2; +extern const enemy_kind pipe2_kbdl; extern const enemy_kind rock; extern const enemy_kind ring; extern const enemy_kind enemy_m1; @@ -430,7 +430,7 @@ inline int _enemy::realize() inline int _enemy::is_pipe() { - return ((_state != notuse) && ((ek == &pipe1) || (ek == &pipe2))); + return ((_state != notuse) && ((ek == &pipe1) || (ek == &pipe2_kbdl))); } --- a/enemy.cpp +++ b/enemy.cpp @@ -755,10 +755,10 @@ void _enemy::move_core() void _enemy::kill_core() { - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 3); - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 7); - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 1); - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 5); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 3); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 7); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 1); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 5); enemies.make(&explosion4, CS2PIXEL(x), CS2PIXEL(y)); sound.g_base_core_explo(x, y); release(); @@ -978,19 +978,19 @@ void _enemy::move_pipe2() } p ^= a; if(p & U_MASK) - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 1); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 1); if(p & R_MASK) - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 3); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 3); if(p & D_MASK) - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 5); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 5); if(p & L_MASK) - enemies.make(&pipe2, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 7); + enemies.make(&pipe2_kbdl, CS2PIXEL(x), CS2PIXEL(y), 0, 0, 7); manage.add_score(10); release(); } -const enemy_kind pipe2 = { +const enemy_kind pipe2_kbdl = { 0, &_enemy::make_pipe2, &_enemy::move_pipe2,
signature.asc
Description: Digital signature