21/07/12 12:55
web_pirate
Sto cercando di compilare questo codice usando le librerie SDL.
E questo è la risposta di gcc:
Non ho installato bene le librerie?
#include <stdio.h> #include <SDL/SDL.h> #include <stdlib.h> #define H 800 #define V 600 int main(){ if(SDL_Init(SDL_INIT_VIDEO)<0){ printf("\nErrore durante il carimento SDL.\n"); return 0; }else{ atexit(SDL_Quit); } SDL_Surface *screen; screen = SDL_Set_Video_Mode(H, V, 0, SDL_HWSURFACE|SDL_DOUBLEBUF); if(screen==NULL){ printf("\nProblemi durante il settaggio dello schermo.\n"); return 0; } return 0; }
E questo è la risposta di gcc:
win.c: In function `SDL_main': win.c:8: error: number of arguments doesn't match prototype C:/MinGW/bin/../lib/gcc/mingw32/3.4.5/../../../../include/SDL/SDL_main.h:57: err or: prototype declaration win.c:19: warning: assignment makes pointer from integer without a cast win.c:27:2: warning: no newline at end of file
Non ho installato bene le librerie?
aaa