[SDL] Can't run SDL apps in OSX 10.6

Lagrange Marc markocpc at gmail.com
Wed Dec 8 03:09:25 PST 2010


Hi,

I'm trying to run a simple SDL test under OSX 10.6 but it fails, saying:

  *** Terminating app due to uncaught exception
'NSInternalInconsistencyException', reason: 'Error (1002) creating
CGSWindow'
  *** call stack here
  terminate called after throwing an instance of 'NSException'

The test code is the following:

... snip ...
/*
 * Built with
 * cc -g -ggdb3 -fno-inline -o test_sdl test_sdl.c
-I/opt/local/include -L/opt/local/lib -lsdl -lsdlmain
 */
void run();

int main(int argc, char *argv[]) {
    run();
}

#include <SDL/SDL.h>

void run()
{
    SDL_Init(SDL_INIT_VIDEO);
    SDL_SetVideoMode(640,480,0,SDL_OPENGL);
}
... snip ...

Versions:
 - OSX 10.6.5
 - SDL 1.2.14 from MacPorts


Have I missed something ?

Thanks.



More information about the SDL mailing list