]> Dogcows Code - chaz/openbox/blob - m4/gl.m4
always gl. fontconfig instead of xft.
[chaz/openbox] / m4 / gl.m4
1 # GL_DEVEL()
2 #
3 # Check for the presence of OpenGL development headers and libraries.
4 # Sets the GL_CFLAGS and GL_LIBS variables as appropriate.
5 AC_DEFUN([GL_DEVEL],
6 [
7 AC_REQUIRE([X11_DEVEL])
8
9 # Store these
10 OLDLIBS=$LIBS
11 OLDCPPFLAGS=$CPPFLAGS
12
13 AC_CHECK_LIB([GL], [glXGetConfig],
14 ,
15 [
16 AC_MSG_ERROR([A valid libGL could not be found.])
17 ])
18
19 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
20 LIBS="$LIBS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS"
21
22 AC_MSG_CHECKING([if we can compile with GL])
23 AC_TRY_LINK(
24 [
25 #include <GL/gl.h>
26 ],
27 [
28 GLfloat f = 0.0;
29 glVertex3f(f, f, f);
30 ],
31 [
32 AC_MSG_RESULT([yes])
33 ],
34 [
35 AC_MSG_RESULT([no])
36 AC_MSG_ERROR([Could not compile against GL])
37 ])
38
39 GL_CFLAGS=""
40 GL_LIBS="-lGL"
41 AC_SUBST(GL_CFLAGS)
42 AC_SUBST(GL_LIBS)
43
44 CPPFLAGS=$OLDCPPFLAGS
45 LIBS=$OLDLIBS
46 ])
This page took 0.035196 seconds and 4 git commands to generate.