diff --git a/src/hardware/r_opengl/r_opengl.c b/src/hardware/r_opengl/r_opengl.c
index 1f8a64c9a35638c453dc6b7b5f59589ad9a2afe3..f8a92ed87a1121fd9598bb80f812eb3ddc3374d2 100644
--- a/src/hardware/r_opengl/r_opengl.c
+++ b/src/hardware/r_opengl/r_opengl.c
@@ -496,6 +496,9 @@ boolean SetupGLfunc(void)
 	return true;
 }
 
+static boolean gl_allowshaders = false;
+static boolean gl_shadersenabled = false;
+
 #ifdef GL_SHADERS
 typedef GLuint 	(APIENTRY *PFNglCreateShader)		(GLenum);
 typedef void 	(APIENTRY *PFNglShaderSource)		(GLuint, GLsizei, const GLchar**, GLint*);
@@ -545,9 +548,6 @@ static PFNglGetUniformLocation pglGetUniformLocation;
 // 18032019
 static char *gl_customvertexshaders[MAXSHADERS];
 static char *gl_customfragmentshaders[MAXSHADERS];
-
-static boolean gl_allowshaders = false;
-static boolean gl_shadersenabled = false;
 static GLuint gl_currentshaderprogram = 0;
 
 // 13062019