forked from bonzini/smalltalk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
glut.m4
32 lines (28 loc) · 938 Bytes
/
glut.m4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
dnl I'd like this to be edited in -*- Autoconf -*- mode...
dnl
AC_DEFUN([GST_HAVE_GLUT], [
AC_REQUIRE([AC_PATH_XTRA])
AC_CHECK_HEADERS([GLUT/glut.h GL/glut.h])
AC_CACHE_CHECK([how to link with GLUT], gst_cv_glut_libs, [
if test $ac_cv_header_GLUT_glut_h = yes || \
test $ac_cv_header_GL_glut_h = yes; then
case $host in
*-*-darwin*) gst_cv_glut_libs='-Wl,-framework,GLUT' ;;
*) gst_cv_glut_libs='-lglut $(X_LIBS) $(X_PRE_LIBS) -lX11' ;;
esac
else
gst_cv_glut_libs='not found'
fi
])
if test "$gst_cv_glut_libs" != "not found"; then
LIBGLUT="$gst_cv_glut_libs"
AC_DEFINE(HAVE_GLUT, 1, [Define if your system has GLUT installed.])
if test $ac_cv_header_GLUT_glut_h = yes; then
gst_cv_glut_header_dir='GLUT'
else
gst_cv_glut_header_dir='GL'
fi
AC_DEFINE_UNQUOTED(GL_GLUT_H, [<$gst_cv_glut_header_dir/glut.h>], [Define to the #include directive for GLUT.])
fi
AC_SUBST(LIBGLUT)
])dnl