comparison aclocal.m4 @ 7825:13871b7de124

Import sources for OpenGL-based renderer. * * * fixed some gcc warnings in gl-render code (casts & virtual destructor)
author Michael Goffioul <michael.goffioul@gmail.com>
date Mon, 11 Feb 2008 16:42:14 +0100
parents a2870fd8ac58
children caab78e7e377
comparison
equal deleted inserted replaced
7824:adb520646d7e 7825:13871b7de124
1051 else 1051 else
1052 AC_MSG_RESULT(no) 1052 AC_MSG_RESULT(no)
1053 ifelse([$2], , , [$2]) 1053 ifelse([$2], , , [$2])
1054 fi 1054 fi
1055 ]) 1055 ])
1056 1056 dnl
1057 dnl Check for OpenGL. If found, define OPENGL_LIBS
1058 dnl
1059 AC_DEFUN([OCTAVE_OPENGL], [
1060 OPENGL_LIBS=
1061 case $canonical_host_type in
1062 *-*-msdosmsvc)
1063 AC_CHECK_HEADERS(windows.h)
1064 ;;
1065 esac
1066 have_opengl_incs=no
1067 AC_CHECK_HEADERS(GL/gl.h, [
1068 AC_CHECK_HEADERS(GL/glu.h, [
1069 have_opengl_incs=yes], [], [
1070 #ifdef HAVE_WINDOWS_H
1071 # include <windows.h>
1072 #endif])], [], [
1073 #ifdef HAVE_WINDOWS_H
1074 # include <windows.h>
1075 #endif])
1076 if test "$have_opengl_incs" = "yes"; then
1077 case $canonical_host_type in
1078 *-*-msdosmsvc)
1079 save_LIBS="$LIBS"
1080 LIBS="$LIBS -lopengl32"
1081 AC_MSG_CHECKING([for glEnable in -lopengl32])
1082 AC_TRY_LINK([
1083 #if HAVE_WINDOWS_H
1084 # include <windows.h>
1085 #endif
1086 #include <GL/gl.h>], [
1087 glEnable(GL_SMOOTH);], OPENGL_LIBS="-lopengl32 -lglu32")
1088 LIBS="$save_LIBS"
1089 if test "x$OPENGL_LIBS" != "x"; then
1090 AC_MSG_RESULT(yes)
1091 else
1092 AC_MSG_RESULT(no)
1093 fi
1094 ;;
1095 *)
1096 save_LDFLAGS="$LDFLAGS"
1097 LDFLAGS="$LDFLAGS -L/usr/X11R6/lib"
1098 AC_CHECK_LIB(GL, glEnable, OPENGL_LIBS="-L/usr/X11R6/lib -lGL -lGLU")
1099 LDFLAGS="$save_LDFLAGS"
1100 ;;
1101 esac
1102 fi
1103 AC_SUBST(OPENGL_LIBS)
1104 ])