Re: [Freeciv-Dev] (PR#39926) build error on ZETA/BeOS with gcc 2.95.3
http://bugs.freeciv.org/Ticket/Display.html?id=39926 > For portability, we should re-write this section. http://www.gnu.org/software/gcc/bugs.html Cannot use preprocessor directive in macro arguments. Versions of GCC prior to 3.3 did not allow you to put #ifdef (or any other preprocessor directive) inside the arguments However, this kind of code is not portable. It is "undefined behavior" according to the C standard; ... ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev
Re: [Freeciv-Dev] (PR#39926) build error on ZETA/BeOS with gcc 2.95.3
http://bugs.freeciv.org/Ticket/Display.html?id=39926 > William Allen Simpson wrote: > What compiler? Apparently, as the error is clearly stated, it doesn't like > the #if in the middle of the GEN_INT macro. > I'm blind, you wrote gcc 2.95.3 in the subject. Can you upgrade? Also, I'd not recommend S2_2 branch unless you have masochistic tendencies, or are an artist willing to help update the graphics! ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev
Re: [Freeciv-Dev] (PR#39926) build error on ZETA/BeOS with gcc 2.95.3
http://bugs.freeciv.org/Ticket/Display.html?id=39926 > Begasus wrote: > /R5/S2_2/server/settings.c:992: warning: preprocessing directive not > recognized within macro arg > /R5/S2_2/server/settings.c:993: `#elif' not within a conditional > /R5/S2_2/server/settings.c:995: `#else' not within a conditional > /R5/S2_2/server/settings.c:997: unbalanced `#endif' > make[1]: *** [settings.o] Error 1 > GEN_INT("compresstype", game.info.save_compress_type, SSET_META, SSET_INTERNAL, SSET_RARE, SSET_SERVER_ONLY, N_("Savegame compression algorithm"), N_("Compression library to use for savegames.\n" " 0 - none\n" " 1 - zlib (gzip format)\n" " 2 - bzip2\n" "Not all servers support all compression methods."), NULL, #if !defined(HAVE_LIBBZ2) && !defined(HAVE_LIBZ) FZ_PLAIN, FZ_PLAIN, FZ_PLAIN) #elif !defined(HAVE_LIBBZ2) && defined(HAVE_LIBZ) FZ_PLAIN, FZ_ZLIB, FZ_ZLIB) #else FZ_PLAIN, FZ_BZIP2, FZ_BZIP2) #endif What compiler? Apparently, as the error is clearly stated, it doesn't like the #if in the middle of the GEN_INT macro. ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev