diff -Naur old/src/gui/ngOpenGlSystem.cpp new/src/gui/ngOpenGlSystem.cpp
--- old/src/gui/ngOpenGlSystem.cpp	2007-04-04 20:04:14.000000000 +0200
+++ new/src/gui/ngOpenGlSystem.cpp	2007-04-04 19:56:46.000000000 +0200
@@ -83,11 +83,11 @@
 ////////////////
 
 // shaders
-typedef void APIENTRY (*GLGENPROGRAMSARB)(GLsizei, GLuint*);
-typedef void APIENTRY (*GLDELETEPROGRAMSARB)(GLsizei, const GLuint *);
-typedef void APIENTRY (*GLBINDPROGRAMARB)(GLenum, GLuint);
-typedef void APIENTRY (*GLPROGRAMSTRINGARB)(GLenum, GLenum, GLsizei, const GLvoid *);
-typedef void APIENTRY (*GLPROGRAMLOCALPARAMETER4FARB)(GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
+//typedef void APIENTRY (*GLGENPROGRAMSARB)(GLsizei, GLuint*);
+//typedef void APIENTRY (*GLDELETEPROGRAMSARB)(GLsizei, const GLuint *);
+//typedef void APIENTRY (*GLBINDPROGRAMARB)(GLenum, GLuint);
+//typedef void APIENTRY (*GLPROGRAMSTRINGARB)(GLenum, GLenum, GLsizei, const GLvoid *);
+//typedef void APIENTRY (*GLPROGRAMLOCALPARAMETER4FARB)(GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
 
 #define OGLVP_EYEPOS		0
 #define OGLVP_AMBIENT		1
@@ -118,14 +118,14 @@
 	pColorLight = decColor(0.9, 0.9, 0.9);
 	pLightDir = decVector(-5, 5, -20);
 	for(int i=0; i<PROGRAM_COUNT; i++) pPrograms[i] = 0;
-	glGenProgramsARB = NULL;
-	glDeleteProgramsARB = NULL;
-	glBindProgramARB = NULL;
-	glProgramStringARB = NULL;
-	glProgramLocalParameter4fARB = NULL;
-	glMultiTexCoord2fARB = NULL;
-	glMultiTexCoord3fARB = NULL;
-	glActiveTextureARB = NULL;
+	//glGenProgramsARB = NULL;
+	//glDeleteProgramsARB = NULL;
+	//glBindProgramARB = NULL;
+	//glProgramStringARB = NULL;
+	//glProgramLocalParameter4fARB = NULL;
+	//glMultiTexCoord2fARB = NULL;
+	//glMultiTexCoord3fARB = NULL;
+	//glActiveTextureARB = NULL;
 	pLoadExtensions();
 	// check command line
 	for( i=0; i<args->GetCount(); i++ ){
@@ -714,32 +714,32 @@
 	if(!extstr) extstr = "";
 	// check for multi texturing support
 	pHasExtMultiTexturing = ( strstr(extstr, "GL_ARB_multitexture") != 0 );
-	if(pHasExtMultiTexturing){
-		glMultiTexCoord2fARB = (GLMULTITEXCOORD2FARB)glXGetProcAddress( (OGLGPA_CAST)"glMultiTexCoord2fARB" );
-		if(!glMultiTexCoord2fARB) THROW(dueInvalidAction);
-		glMultiTexCoord3fARB = (GLMULTITEXCOORD3FARB)glXGetProcAddress( (OGLGPA_CAST)"glMultiTexCoord3fARB" );
-		if(!glMultiTexCoord3fARB) THROW(dueInvalidAction);
-		glActiveTextureARB = (GLACTIVETEXTUREARB)glXGetProcAddress( (OGLGPA_CAST)"glActiveTextureARB" );
-		if(!glActiveTextureARB) THROW(dueInvalidAction);
-	}
+	//if(pHasExtMultiTexturing){
+	//	glMultiTexCoord2fARB = (GLMULTITEXCOORD2FARB)glXGetProcAddress( (OGLGPA_CAST)"glMultiTexCoord2fARB" );
+	//	if(!glMultiTexCoord2fARB) THROW(dueInvalidAction);
+	//	glMultiTexCoord3fARB = (GLMULTITEXCOORD3FARB)glXGetProcAddress( (OGLGPA_CAST)"glMultiTexCoord3fARB" );
+	//	if(!glMultiTexCoord3fARB) THROW(dueInvalidAction);
+	//	glActiveTextureARB = (GLACTIVETEXTUREARB)glXGetProcAddress( (OGLGPA_CAST)"glActiveTextureARB" );
+	//	if(!glActiveTextureARB) THROW(dueInvalidAction);
+	//}
 	// check for automatic mipmap generation support
 	pHasExtGenMipMap = ( strstr(extstr, "SGIS_generate_mipmap") != 0 );
 	// check for vertex and fragement program support
 	hasVertProg = ( strstr(extstr, "GL_ARB_vertex_program") != 0 );
 	hasFragProg = ( strstr(extstr, "GL_ARB_fragment_program") != 0 );
 	pHasVFProg = hasVertProg && hasFragProg;
-	if( pHasVFProg ){
-		glGenProgramsARB = (GLGENPROGRAMSARB)glXGetProcAddress( (OGLGPA_CAST)"glGenProgramsARB" );
-		if(!glGenProgramsARB) THROW(dueInvalidAction);
-		glDeleteProgramsARB = (GLDELETEPROGRAMSARB)glXGetProcAddress( (OGLGPA_CAST)"glDeleteProgramsARB" );
-		if(!glDeleteProgramsARB) THROW(dueInvalidAction);
-		glBindProgramARB = (GLBINDPROGRAMARB)glXGetProcAddress( (OGLGPA_CAST)"glBindProgramARB" );
-		if(!glBindProgramARB) THROW(dueInvalidAction);
-		glProgramStringARB = (GLPROGRAMSTRINGARB)glXGetProcAddress( (OGLGPA_CAST)"glProgramStringARB" );
-		if(!glProgramStringARB) THROW(dueInvalidAction);
-		glProgramLocalParameter4fARB = (GLPROGRAMLOCALPARAMETER4FARB)glXGetProcAddress( (OGLGPA_CAST)"glProgramLocalParameter4fARB" );
-		if(!glProgramLocalParameter4fARB) THROW(dueInvalidAction);
-	}
+	//if( pHasVFProg ){
+	//	glGenProgramsARB = (GLGENPROGRAMSARB)glXGetProcAddress( (OGLGPA_CAST)"glGenProgramsARB" );
+	//	if(!glGenProgramsARB) THROW(dueInvalidAction);
+	//	glDeleteProgramsARB = (GLDELETEPROGRAMSARB)glXGetProcAddress( (OGLGPA_CAST)"glDeleteProgramsARB" );
+	//	if(!glDeleteProgramsARB) THROW(dueInvalidAction);
+	//	glBindProgramARB = (GLBINDPROGRAMARB)glXGetProcAddress( (OGLGPA_CAST)"glBindProgramARB" );
+	//	if(!glBindProgramARB) THROW(dueInvalidAction);
+	//	glProgramStringARB = (GLPROGRAMSTRINGARB)glXGetProcAddress( (OGLGPA_CAST)"glProgramStringARB" );
+	//	if(!glProgramStringARB) THROW(dueInvalidAction);
+	//	glProgramLocalParameter4fARB = (GLPROGRAMLOCALPARAMETER4FARB)glXGetProcAddress( (OGLGPA_CAST)"glProgramLocalParameter4fARB" );
+	//	if(!glProgramLocalParameter4fARB) THROW(dueInvalidAction);
+	//}
 	// print out what we have found
 #ifdef DEBUG_MODE
 	printf("[OGL] OpenGL Vendor: %s\n", glGetString( GL_VENDOR ) );
diff -Naur old/src/gui/ngOpenGlSystem.h new/src/gui/ngOpenGlSystem.h
--- old/src/gui/ngOpenGlSystem.h	2007-04-04 20:04:14.000000000 +0200
+++ new/src/gui/ngOpenGlSystem.h	2007-04-04 19:57:05.000000000 +0200
@@ -31,14 +31,20 @@
 #include "../common/math/decMath.h"
 
 // shaders
-typedef void (APIENTRY *GLGENPROGRAMSARB)(GLsizei, GLuint*);
-typedef void (APIENTRY *GLDELETEPROGRAMSARB)(GLsizei, const GLuint *);
-typedef void (APIENTRY *GLBINDPROGRAMARB)(GLenum, GLuint);
-typedef void (APIENTRY *GLPROGRAMSTRINGARB)(GLenum, GLenum, GLsizei, const GLvoid *);
-typedef void (APIENTRY *GLPROGRAMLOCALPARAMETER4FARB)(GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-typedef void (APIENTRY *GLMULTITEXCOORD2FARB)(GLenum, GLfloat, GLfloat);
-typedef void (APIENTRY *GLMULTITEXCOORD3FARB)(GLenum, GLfloat, GLfloat, GLfloat);
-typedef void (APIENTRY *GLACTIVETEXTUREARB)(GLenum);
+// make sure APIENTRY is defined
+
+#ifndef APIENTRY
+#define APIENTRY
+#endif
+
+  typedef void APIENTRY (*GLGENPROGRAMSARB)(GLsizei, GLuint*); 
+  typedef void APIENTRY (*GLDELETEPROGRAMSARB)(GLsizei, const GLuint *); 
+  typedef void APIENTRY (*GLBINDPROGRAMARB)(GLenum, GLuint); 
+  typedef void APIENTRY (*GLPROGRAMSTRINGARB)(GLenum, GLenum, GLsizei, const GLvoid *); 
+  typedef void APIENTRY (*GLPROGRAMLOCALPARAMETER4FARB)(GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); 
+  typedef void APIENTRY (*GLMULTITEXCOORD2FARB)(GLenum, GLfloat, GLfloat); 
+  typedef void APIENTRY (*GLMULTITEXCOORD3FARB)(GLenum, GLfloat, GLfloat, GLfloat); 
+  typedef void APIENTRY (*GLACTIVETEXTUREARB)(GLenum);
 
 // predefinitions
 class ngLowResMesh;
@@ -103,14 +109,14 @@
 	GLuint pPrograms[PROGRAM_COUNT];
 private:
 	// shader extension functions
-	GLGENPROGRAMSARB glGenProgramsARB;
-	GLDELETEPROGRAMSARB glDeleteProgramsARB;
-	GLBINDPROGRAMARB glBindProgramARB;
-	GLPROGRAMSTRINGARB glProgramStringARB;
-	GLPROGRAMLOCALPARAMETER4FARB glProgramLocalParameter4fARB;
-	GLMULTITEXCOORD2FARB glMultiTexCoord2fARB;
-	GLMULTITEXCOORD3FARB glMultiTexCoord3fARB;
-	GLACTIVETEXTUREARB glActiveTextureARB;
+	//GLGENPROGRAMSARB glGenProgramsARB;
+	//GLDELETEPROGRAMSARB glDeleteProgramsARB;
+	//GLBINDPROGRAMARB glBindProgramARB;
+	//GLPROGRAMSTRINGARB glProgramStringARB;
+	//GLPROGRAMLOCALPARAMETER4FARB glProgramLocalParameter4fARB;
+	//GLMULTITEXCOORD2FARB glMultiTexCoord2fARB;
+	//GLMULTITEXCOORD3FARB glMultiTexCoord3fARB;
+	//GLACTIVETEXTUREARB glActiveTextureARB;
 public:
 	// constructor, destructor
 	ngOpenGlSystem( deCmdLineArgs *args );
