# HG changeset patch # User Sam Lantinga # Date 989526711 0 # Node ID c447d5b9275df67ecc249ec20fbdfe705ffee550 # Parent 3fbf86244fd2f6e624c383c7d7d7d8711c1ddec2 Date: Wed, 9 May 2001 18:03:20 -0600 From: Peter Valchev Subject: openbsd patches - The dlsym() one is supposed to fix dynamic loading on our a.out architectures, where prefixing of an underscore symbol is required. Actually I don't know what kind of dynamic loading does SDL deal with, but anyway. You may want to make that change global, but only gcc's preprocessor passes __ELF__, I think, so you can just add Linux or something if you decide so. diff -r 3fbf86244fd2 -r c447d5b9275d src/video/x11/SDL_x11gl.c --- a/src/video/x11/SDL_x11gl.c Thu May 10 20:29:31 2001 +0000 +++ b/src/video/x11/SDL_x11gl.c Thu May 10 20:31:51 2001 +0000 @@ -343,6 +343,9 @@ #endif handle = dlopen(path, dlopen_flags); /* Catch the case where the application isn't linked with GL */ +#if defined __OpenBSD__ && !defined __ELF__ +#define dlsym(x,y) dlsym(x, "_" y) +#endif if ( (dlsym(handle, "glXChooseVisual") == NULL) && (path == NULL) ) { dlclose(handle); path = getenv("SDL_VIDEO_GL_DRIVER");