summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac9
2 files changed, 10 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 68fdc12..5297b21 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -22,7 +22,7 @@ bin_PROGRAMS = xdriinfo
xdriinfo_CFLAGS = $(XDRIINFO_CFLAGS)
# mesa should really use pkg-config ...
-xdriinfo_LDADD = $(XDRIINFO_LIBS) -lGL
+xdriinfo_LDADD = $(XDRIINFO_LIBS)
xdriinfo_SOURCES = \
xdriinfo.c
diff --git a/configure.ac b/configure.ac
index 30ff257..06e0375 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,6 +37,15 @@ PKG_CHECK_MODULES(XDRIINFO, x11 glproto)
AC_SUBST(XDRIINFO_CFLAGS)
AC_SUBST(XDRIINFO_LIBS)
+# Checks for non-pkg-config packages (Mesa or vendor OpenGL)
+AC_CHECK_HEADER([GL/glx.h], [],
+ AC_MSG_FAILURE([cannot find GL/glx.h - make sure Mesa or other OpenGL package is installed]))
+
+AC_SEARCH_LIBS([glXGetProcAddress], [GL], [],
+ AC_MSG_FAILURE([cannot find GL library - make sure Mesa or other OpenGL package is installed]),
+ [$XDRIINFO_LIBS])
+
+
XORG_MANPAGE_SECTIONS
XORG_RELEASE_VERSION