]> Dogcows Code - chaz/openbox/commitdiff
always gl. fontconfig instead of xft.
authorDana Jansens <danakj@orodu.net>
Sun, 25 May 2003 20:26:48 +0000 (20:26 +0000)
committerDana Jansens <danakj@orodu.net>
Sun, 25 May 2003 20:26:48 +0000 (20:26 +0000)
configure.ac
m4/gl.m4

index 033431104fd307f8895317d619a99ef54b35a575..c7545137b275d0ebabeedc0f420a8f9360002713 100644 (file)
@@ -49,9 +49,9 @@ PKG_CHECK_MODULES([GMODULE], [gmodule-2.0])
 AC_SUBST(GMODULE_CFLAGS)
 AC_SUBST(GMODULE_LIBS)
 
-PKG_CHECK_MODULES(XFT, [xft])
-AC_SUBST(XFT_CFLAGS)
-AC_SUBST(XFT_LIBS)
+PKG_CHECK_MODULES(FC, [fontconfig])
+AC_SUBST(FC_CFLAGS)
+AC_SUBST(FC_LIBS)
 
 PKG_CHECK_MODULES(XML, [libxml-2.0])
 AC_SUBST(XML_CFLAGS)
@@ -100,7 +100,7 @@ X11_EXT_VIDMODE
 X11_EXT_SHAPE
 X11_EXT_XINERAMA
 
-GL_OPTION
+GL_DEVEL
 
 AC_CONFIG_FILES([Makefile
                  po/Makefile.in
index e359271293353e55df8763129a4bc0c98ce48e9b..8ae3ba30bae14a32a8f8ebcc09a8c8ee7818c810 100644 (file)
--- a/m4/gl.m4
+++ b/m4/gl.m4
@@ -1,65 +1,46 @@
-# X11_DEVEL()
+# GL_DEVEL()
 #
-# Check for the presence of the X Window System headers and libraries.
-# Sets the CPPFLAGS and LIBS variables as appropriate.
-AC_DEFUN([GL_OPTION],
+# Check for the presence of OpenGL development headers and libraries.
+# Sets the GL_CFLAGS and GL_LIBS variables as appropriate.
+AC_DEFUN([GL_DEVEL],
 [
   AC_REQUIRE([X11_DEVEL])
 
-  AC_ARG_ENABLE(gl, [  --enable-gl             enable support for OpenGL rendering default=no],
-                ,[enable_gl="no"])
-
   # Store these
   OLDLIBS=$LIBS
   OLDCPPFLAGS=$CPPFLAGS
 
-  if test "$enable_gl" = "yes"; then
-    AC_CHECK_LIB([GL], [glXGetConfig],
-                 ,
-                 [
-                   enable_gl="no"
-                   AC_MSG_WARN([Disabling GL rendering support])
-                 ])
-  fi
-
-  if test "$enable_gl" = "yes"; then
-    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
-    LIBS="$LIBS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS"
-
-    AC_MSG_CHECKING([if we can compile with GL])
-    AC_TRY_LINK(
-    [
-      #include <GL/gl.h>
-    ],
-    [
-      GLfloat f = 0.0;
-      glVertex3f(f, f, f);
-    ],
-    [
-      AC_MSG_RESULT([yes])
-    ],
-    [
-      AC_MSG_RESULT([no])
-      AC_MSG_WARN([Disabling GL rendering support])
-      enable_gl="no"
-    ])
+  AC_CHECK_LIB([GL], [glXGetConfig],
+               ,
+               [
+                 AC_MSG_ERROR([A valid libGL could not be found.])
+               ])
+
+  CPPFLAGS="$CPPFLAGS $X_CFLAGS"
+  LIBS="$LIBS $X_PRE_LIBS $X_LIBS $X_EXTRA_LIBS"
+
+  AC_MSG_CHECKING([if we can compile with GL])
+  AC_TRY_LINK(
+  [
+    #include <GL/gl.h>
+  ],
+  [
+    GLfloat f = 0.0;
+    glVertex3f(f, f, f);
+  ],
+  [
+    AC_MSG_RESULT([yes])
+  ],
+  [
+    AC_MSG_RESULT([no])
+    AC_MSG_ERROR([Could not compile against GL])
+  ])
 
-    GL_CFLAGS=""
-    GL_LIBS="-lGL"
-    AC_SUBST(GL_CFLAGS)
-    AC_SUBST(GL_LIBS)
-  fi
+  GL_CFLAGS=""
+  GL_LIBS="-lGL"
+  AC_SUBST(GL_CFLAGS)
+  AC_SUBST(GL_LIBS)
 
   CPPFLAGS=$OLDCPPFLAGS
   LIBS=$OLDLIBS
-
-  AC_MSG_CHECKING([if GL support is enabled])
-  if test "$enable_gl" = "yes"; then
-    AC_MSG_RESULT([yes])
-
-    AC_DEFINE(USE_GL)
-  else
-    AC_MSG_RESULT([no])
-  fi
-  AM_CONDITIONAL([USE_GL], [test "$enable_gl" = "yes"])
 ])
This page took 0.031244 seconds and 4 git commands to generate.