summaryrefslogtreecommitdiff
path: root/m4/ax_check_gl.m4
diff options
context:
space:
mode:
authorBastien ROUCARIÈS <roucaries.bastien@gmail.com>2013-04-06 16:16:54 +0200
committerPeter Simons <simons@cryp.to>2013-04-07 22:43:52 +0200
commit727e2fd918c115cecf5e8ef25d164958f644598a (patch)
tree8ff7fe6e637fa4d0bc9cdaeae9590d8900dfe377 /m4/ax_check_gl.m4
parent3e58e4f5229cfb6679d80ae72321585557f042bc (diff)
downloadautoconf-archive-727e2fd918c115cecf5e8ef25d164958f644598a.tar.gz
Fix detection of gl by pkg-config
* fix detection by pkg-config and run when available * fixe a typo s/GL_FLAG/GL_CFLAGS/g
Diffstat (limited to 'm4/ax_check_gl.m4')
-rw-r--r--m4/ax_check_gl.m413
1 files changed, 8 insertions, 5 deletions
diff --git a/m4/ax_check_gl.m4 b/m4/ax_check_gl.m4
index cdb15d8..964220d 100644
--- a/m4/ax_check_gl.m4
+++ b/m4/ax_check_gl.m4
@@ -70,7 +70,7 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
-#serial 14
+#serial 15
m4_define([_AX_CHECK_GL_PROGRAM],
[AC_LANG_PROGRAM([[
@@ -354,7 +354,7 @@ AC_DEFUN([_AX_CHECK_GL_PKG_CONFIG],dnl
# check headers
AC_LANG_PUSH([C])
_AX_CHECK_GL_SAVE_FLAGS()
- CFLAGS="${GL_FLAGS} ${CFLAGS}"
+ CFLAGS="${GL_CFLAGS} ${CFLAGS}"
AC_CHECK_HEADERS([windows.h],[],[],[AC_INCLUDES_DEFAULT])
AC_CHECK_HEADERS([GL/gl.h OpenGL/gl.h],
[ax_check_gl_have_headers="yes";break],
@@ -404,9 +404,12 @@ AC_DEFUN([_AX_CHECK_GL],[dnl
_AX_CHECK_GL_NEED_X()
# try first pkgconfig
- AS_IF([test "X${PKG_CONFIG}" != "X"],
- [ ax_check_gl_pkg_config=no],
- [ _AX_CHECK_GL_PKG_CONFIG()])
+ AC_MSG_CHECKING([for a working OpenGL implementation by pkg-config])
+ AS_IF([test "X${PKG_CONFIG}" = "X"],
+ [ AC_MSG_RESULT([no])
+ ax_check_gl_pkg_config=no],
+ [ AC_MSG_RESULT([yes])
+ _AX_CHECK_GL_PKG_CONFIG()])
# if no pkgconfig or pkgconfig fail try manual way
AS_IF([test "X$ax_check_gl_pkg_config" = "Xno"],