We always add -lm (eventually) anyway, so just adding it to the GL lib test
should be sufficient. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12364 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
bc4e6fcdc3
commit
57964555cd
29
configure.in
29
configure.in
@ -2313,21 +2313,26 @@ if test "$wxUSE_OPENGL" = "yes"; then
|
||||
if test "$wxUSE_MAC" = 1; then
|
||||
OPENGL_LIBS="-framework OpenGL -framework AGL"
|
||||
else
|
||||
dnl -lGL requires -lm with soem OpenGL versions - although it would, of
|
||||
dnl course, be cleaner to test first without -lm and then with it, I don't
|
||||
dnl have time for this now so just always add -lm
|
||||
LIBS="$LIBS -lm"
|
||||
|
||||
dnl check for OpenGL libs availability first
|
||||
AC_CHECK_HEADER(GL/gl.h, [
|
||||
AC_CHECK_LIB(GL, glFlush, [
|
||||
OPENGL_LIBS="-lGL -lGLU"
|
||||
], [
|
||||
AC_CHECK_LIB(MesaGL, glFlush, [
|
||||
OPENGL_LIBS="-lMesaGL -lMesaGLU"
|
||||
dnl -lGL requires -lm with soem OpenGL versions
|
||||
|
||||
AC_CHECK_HEADER(GL/gl.h,
|
||||
[
|
||||
AC_CHECK_LIB(GL, glFlush,
|
||||
[
|
||||
OPENGL_LIBS="-lGL -lGLU"
|
||||
],
|
||||
[
|
||||
AC_CHECK_LIB(MesaGL, glFlush,
|
||||
[
|
||||
OPENGL_LIBS="-lMesaGL -lMesaGLU"
|
||||
],
|
||||
[],
|
||||
[-lm])
|
||||
],
|
||||
[-lm])
|
||||
])
|
||||
])
|
||||
])
|
||||
|
||||
if test "x$OPENGL_LIBS" = "x"; then
|
||||
dnl it should be an error and not a warning because OpenGL is not on
|
||||
|
Loading…
Reference in New Issue
Block a user