Can't compile Anura


#1

Hi, i played Frogatto a year and a half ago, and even contributed with some translations on that year.

I was curious about the new version so i decided to try and compile it.

I am using Kubuntu 13.10 and downloaded and installed all the dependencies.

Compilation ends at the very begining with this output:

Building: src/IMG_savepng.cpp In file included from src/IMG_savepng.cpp:45:0: /usr/include/libpng12/png.h:2659:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ /usr/include/libpng12/png.h:2667:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ /usr/include/libpng12/png.h:2675:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ In file included from src/IMG_savepng.cpp:52:0: src/graphics.hpp:38:21: fatal error: SDL_ttf.h: No such file or directory #include "SDL_ttf.h" ^ cc1plus: all warnings being treated as errors compilation terminated. make: *** [src/IMG_savepng.o] Error 1

I made double sure i installed the library (sudo apt-get install libsdl-ttf2.0-dev) but still i can’t procede.

Any clues?


#2

I’d suggest building SDL2/SDL2_image/SDL2_mixer/SDL2_ttf directly from mercurial. I did this on kubuntu 13.04 over the weekend and generated a working build.

Rough list of dependencies for SDL2: sudo apt-get install libpng12-dev libjpeg8-dev libwebp-dev libtiff-dev libfluidsynth-dev libfreetype6-dev
(I also build smpeg from svn co svn://svn.icculus.org/smpeg/trunk smpeg first)
Then mostly the following dance: ./autogen.sh && mkdir build && cd build && …/configure && make && sudo make install


#3

Thank you for your response.

I did what you told me but still no luck.

This is the output now:

Building: src/IMG_savepng.cpp In file included from src/IMG_savepng.cpp:45:0: /usr/include/libpng12/png.h:2659:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ /usr/include/libpng12/png.h:2667:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ /usr/include/libpng12/png.h:2675:31: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Werror=literal-suffix] fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ ^ cc1plus: all warnings being treated as errors make: *** [src/IMG_savepng.o] Error 1

Apparently now it founds SDL_ttf but still can’t compile it :frowning:


#4

Looks like a debian bug.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=676157


#5

I’ve updated the master branch in github with a workaround for that libpng12 build error. I’ve also added a bunch of build instructions for ubuntu 13.10 to the INSTALL file.