Commit 3558acac authored by Alexandre Julliard's avatar Alexandre Julliard

glu32: Load libGLU dynamically.

parent acb480e7
......@@ -10783,14 +10783,14 @@ _ACEOF
fi
if test "x$with_glu" != "xno"
then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gluLookAt in -lGLU" >&5
$as_echo_n "checking for gluLookAt in -lGLU... " >&6; }
if ${ac_cv_lib_GLU_gluLookAt+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -lGLU" >&5
$as_echo_n "checking for -lGLU... " >&6; }
if ${ac_cv_lib_soname_GLU+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
ac_check_soname_save_LIBS=$LIBS
LIBS="-lGLU $OPENGL_LIBS $X_LIBS -lm $X_EXTRA_LIBS $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
......@@ -10809,21 +10809,34 @@ return gluLookAt ();
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_GLU_gluLookAt=yes
else
ac_cv_lib_GLU_gluLookAt=no
case "$LIBEXT" in
dll) ac_cv_lib_soname_GLU=`$ac_cv_path_LDD conftest.exe | grep "GLU" | sed -e "s/dll.*/dll/"';2,$d'` ;;
dylib) ac_cv_lib_soname_GLU=`$OTOOL -L conftest$ac_exeext | grep "libGLU\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libGLU\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
*) ac_cv_lib_soname_GLU=`$READELF -d conftest$ac_exeext | grep "NEEDED.*libGLU\\.$LIBEXT" | sed -e "s/^.*\\[\\(libGLU\\.$LIBEXT[^ ]*\\)\\].*$/\1/"';2,$d'`
if ${ac_cv_lib_soname_GLU:+false} :; then :
ac_cv_lib_soname_GLU=`$LDD conftest$ac_exeext | grep "libGLU\\.$LIBEXT" | sed -e "s/^.*\(libGLU\.$LIBEXT[^ ]*\).*$/\1/"';2,$d'`
fi ;;
esac
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_GLU_gluLookAt" >&5
$as_echo "$ac_cv_lib_GLU_gluLookAt" >&6; }
if test "x$ac_cv_lib_GLU_gluLookAt" = xyes; then :
:
LIBS=$ac_check_soname_save_LIBS
fi
if ${ac_cv_lib_soname_GLU:+false} :; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
$as_echo "not found" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_soname_GLU" >&5
$as_echo "$ac_cv_lib_soname_GLU" >&6; }
if test "x$ac_cv_lib_GLU_gluLookAt" != xyes; then :
cat >>confdefs.h <<_ACEOF
#define SONAME_LIBGLU "$ac_cv_lib_soname_GLU"
_ACEOF
fi
if test "x$ac_cv_lib_soname_GLU" = "x"; then :
case "x$with_glu" in
x) as_fn_append wine_notices "|libGLU ${notice_platform}development files not found, GLU won't be supported." ;;
xno) ;;
......@@ -10928,7 +10941,7 @@ esac
enable_winex11_drv=${enable_winex11_drv:-no}
fi
test "x$ac_cv_lib_GLU_gluLookAt" != xyes && enable_glu32=${enable_glu32:-no}
test "x$ac_cv_lib_soname_GLU" = "x" && enable_glu32=${enable_glu32:-no}
if test "$ac_cv_header_CL_cl_h" = "yes"
then
......
......@@ -1142,8 +1142,8 @@ This probably prevents linking to OpenGL. Try deleting the file and restarting c
$X_LIBS -lm $X_EXTRA_LIBS)
if test "x$with_glu" != "xno"
then
AC_CHECK_LIB(GLU,gluLookAt,[:],,[$OPENGL_LIBS $X_LIBS -lm $X_EXTRA_LIBS])
WINE_NOTICE_WITH(glu,[test "x$ac_cv_lib_GLU_gluLookAt" != xyes],
WINE_CHECK_SONAME(GLU,gluLookAt,,,[$OPENGL_LIBS $X_LIBS -lm $X_EXTRA_LIBS])
WINE_NOTICE_WITH(glu,[test "x$ac_cv_lib_soname_GLU" = "x"],
[libGLU ${notice_platform}development files not found, GLU won't be supported.])
fi
......@@ -1167,7 +1167,7 @@ without X support, which probably isn't what you want. You will need
to install ${notice_platform}development packages of Xlib/Xfree86 at the very least.],
[enable_winex11_drv])
test "x$ac_cv_lib_GLU_gluLookAt" != xyes && enable_glu32=${enable_glu32:-no}
test "x$ac_cv_lib_soname_GLU" = "x" && enable_glu32=${enable_glu32:-no}
dnl **** Check for OpenCL ****
if test "$ac_cv_header_CL_cl_h" = "yes"
......
MODULE = glu32.dll
IMPORTLIB = glu32
EXTRAINCL = $(X_CFLAGS)
EXTRALIBS = -lGLU $(OPENGL_LIBS) $(X_LIBS) $(X_EXTRA_LIBS)
C_SRCS = \
glu.c
......@@ -1412,6 +1412,9 @@
/* Define to the soname of the libGL library. */
#undef SONAME_LIBGL
/* Define to the soname of the libGLU library. */
#undef SONAME_LIBGLU
/* Define to the soname of the libgnutls library. */
#undef SONAME_LIBGNUTLS
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment