File: glut.m4

package info (click to toggle)
gnu-smalltalk 3.1-6
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 33,300 kB
  • ctags: 13,999
  • sloc: ansic: 88,106; sh: 23,223; asm: 7,889; perl: 4,493; cpp: 3,539; awk: 1,483; yacc: 1,355; xml: 1,272; makefile: 1,192; lex: 843; sed: 258; objc: 124
file content (32 lines) | stat: -rw-r--r-- 938 bytes parent folder | download
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