From 5fe5fa1f4d7cfb2a8c3a3baff6467b0bc6c25c88 Mon Sep 17 00:00:00 2001 From: mem Date: Tue, 29 Jul 2003 08:41:51 +0000 Subject: [PATCH] Use a NULL for the path passed to dlopen, that means 'give me a handle to the loaded image' which at the point where this function is called already included all libGL's symbols. Makes the whole thing easier to maintain. git-svn-id: https://glew.svn.sourceforge.net/svnroot/glew/trunk/glew@109 783a27ee-832a-0410-bc00-9f386506c6dd --- Makefile | 2 +- auto/src/glew_pre.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 28c2d03..581fb2b 100644 --- a/Makefile +++ b/Makefile @@ -78,7 +78,7 @@ ifeq ($(patsubst IRIX%,IRIX,$(SYSTEM)), IRIX) CC = cc EXTRA_CCFLAGS = EXTRA_LDFALGS = -EXTRA_CPPFLAGS = -DGLEW_NEEDS_CUSTOM_GET_PROCADDRESS=1 -DGLEW_OPENGL_LIB_PATH=\"libGL.so\" +EXTRA_CPPFLAGS = -DGLEW_NEEDS_CUSTOM_GET_PROCADDRESS=1 NAME = GLEW P.BIN = WARN = -fullwarn diff --git a/auto/src/glew_pre.c b/auto/src/glew_pre.c index ddfa077..76d21d0 100644 --- a/auto/src/glew_pre.c +++ b/auto/src/glew_pre.c @@ -55,11 +55,11 @@ static void * __dlopenGetProcAddress(const GLubyte *procName) if (!h) { - if (!(h = dlopen(GLEW_OPENGL_LIB_PATH, RTLD_LAZY | RTLD_LOCAL))) + if (!(h = dlopen(NULL, RTLD_LAZY | RTLD_LOCAL))) { fprintf(stderr, - "E: GLEW failed to dlopen %s: %s.\nAbort.\n", - GLEW_OPENGL_LIB_PATH, dlerror()); + "E: GLEW failed to dlopen myself: %s.\nAbort.\n", + dlerror()); exit(100); }