Re: [Tuxpaint-devel] Well organized and commented code of my animation application
An award-winning drawing program for children of all ages
Brought to you by:
wkendrick
|
From: Pere P. i C. <pe...@fo...> - 2008-04-18 11:15:24
|
Hi Ajay! El dc 16 de 04 de 2008 a les 20:52 +0530, en/na Ajay Kumar va escriure: > The commented code is uploaded here. > http://www.uploadcomet.com/download.php?file=6b7e2d553a76f09fca38eafba762e0c6. The necessary images, configuration files, fonts and character file are also included. I have compiled this edited code on my system. It is getting compiled without any errors. Please take a took at my commented code, i hope it makes sense as it is commented. Some problems I've find compling under linux: pere@hola:/tmp/commented code$ LC_ALL=C gcc -I /usr/include/SDL -lSDL -lSDL_ttf AniMe.c -o Anime AniMe.c:6:21: error: SDL_TTF.h: No such file or directory In file included from AniMe.c:9: main.h:9: warning: parameter names (without types) in function declaration In file included from AniMe.c:15: rendering.h: In function 'drawText': rendering.h:5: error: 'TTF_Font' undeclared (first use in this function) rendering.h:5: error: (Each undeclared identifier is reported only once rendering.h:5: error: for each function it appears in.) rendering.h:5: error: 'font' undeclared (first use in this function) rendering.h:9: warning: initialization makes pointer from integer without a cast AniMe.c: In function 'main': AniMe.c:3348: error: 'TTF_Quit' undeclared (first use in this function) It seems a case sensitive problem, in linux I have a SDL_ttf.h under /usr/include/SDL, so just correcting the spelling in AniMe.c solves this. Next problem, itoa function seems not be available in linux. pere@hola:/tmp/commented code$ LC_ALL=C gcc -I /usr/include/SDL -l SDL -l SDL_ttf AniMe.c -o Anime In file included from AniMe.c:9: main.h:9: warning: parameter names (without types) in function declaration /tmp/ccTA5ioG.o: In function `cursor_pos': AniMe.c:(.text+0x12755): undefined reference to `itoa' AniMe.c:(.text+0x12772): undefined reference to `itoa' collect2: ld returned 1 exit status Googling for this, seems that it should be replaced by sprintf or snprintf. I am unable to compile further. Hope this helps Pere Note, since you are developing under windows, you migth want to check those pages about compiling tuxpaint under windows: http://johnnypops.demon.co.uk/mingw/index.html http://johnnypops.demon.co.uk/mingw-old/index.html |