From 2976ca471e3e828a779b24c3ddbacef26cc2ac8a Mon Sep 17 00:00:00 2001 From: Spoike Date: Wed, 22 Dec 2004 13:47:57 +0000 Subject: [PATCH] raz0 pointed out that gl was crashing on his computer. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@681 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/gl/gl_vidlinuxglx.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/engine/gl/gl_vidlinuxglx.c b/engine/gl/gl_vidlinuxglx.c index 7c2c3eecf..e347a6e1c 100644 --- a/engine/gl/gl_vidlinuxglx.c +++ b/engine/gl/gl_vidlinuxglx.c @@ -137,6 +137,8 @@ qboolean GLX_InitLibrary(char *driver) gllibrary = NULL; if (!gllibrary) gllibrary = dlopen("libGL.so", RTLD_LOCAL | RTLD_LAZY); + if (!gllibrary) //I hate this. + gllibrary = dlopen("libGL.so.1", RTLD_LOCAL | RTLD_LAZY); if (!gllibrary) return false; @@ -622,7 +624,11 @@ qboolean GLVID_Init (rendererstate_t *info, unsigned char *palette) S_Startup(); - GLX_InitLibrary(info->glrenderer); + if (!GLX_InitLibrary(info->glrenderer)) + { + Con_Printf("Couldn't intialise GLX\nEither your drivers are not installed or you need to specify the library name with the gl_driver cvar\n"); + return false; + } vid.maxwarpwidth = WARP_WIDTH; vid.maxwarpheight = WARP_HEIGHT;