Skip to content
Permalink
Browse files

Enable dynamic X11 on Mac OS X.

  • Loading branch information
icculus committed Nov 17, 2005
1 parent 22d1555 commit ac89c744b89049f2af2c65597332fca68b3043ac
Showing with 13 additions and 25 deletions.
  1. +13 −25 configure.in
@@ -614,8 +614,16 @@ CheckX11()
, enable_x11_shared=yes)

dnl !!! FIXME: if a platform needs more than this, fill it in!
x11_lib='libX11.so.6'
x11ext_lib='libXext.so.6'
case "$target" in
*-*-darwin* )
x11_lib='/usr/X11R6/lib/libX11.6.dylib'
x11ext_lib='/usr/X11R6/lib/libXext.6.dylib'
;;
*)
x11_lib='libX11.so.6'
x11ext_lib='libXext.so.6'
;;
esac

if test x$have_loadso != xyes && \
test x$enable_x11_shared = xyes; then
@@ -626,6 +634,8 @@ CheckX11()
test x$enable_x11_shared = xyes && test x$x11_lib != x && test x$x11ext_lib != x; then
CFLAGS="$CFLAGS $X_CFLAGS -DENABLE_X11 -DXTHREADS -DX11_DYNAMIC=\$(x11_lib) -DX11EXT_DYNAMIC=\$(x11ext_lib) -I$srcdir/include -I$srcdir/src/video"
SYSTEM_LIBS="$SYSTEM_LIBS $X_LIBS"
echo "-- dynamic libX11 -> $x11_lib"
echo "-- dynamic libX11ext -> $x11ext_lib"
AC_SUBST(x11_lib)
AC_SUBST(x11ext_lib)
else
@@ -769,28 +779,6 @@ CheckX11()
fi
}


dnl Check for X11 on Mac OS X / Darwin
CheckMacX11()
{
AC_ARG_ENABLE(video-x11,
[ --enable-video-x11 use X11 video driver [default=no]],
, enable_video_x11=no)
if test x$enable_video = xyes -a x$enable_video_x11 = xyes; then
AC_PATH_X
AC_PATH_XTRA
if test x$have_x = xyes; then
CFLAGS="$CFLAGS $X_CFLAGS -DENABLE_X11 -DXTHREADS -I$srcdir/include -I$srcdir/src/video"
if test x$ac_cv_func_shmat != xyes; then
CFLAGS="$CFLAGS -DNO_SHARED_MEMORY"
fi
SYSTEM_LIBS="$SYSTEM_LIBS $X_LIBS -lX11 -lXext"
VIDEO_SUBDIRS="$VIDEO_SUBDIRS x11"
VIDEO_DRIVERS="$VIDEO_DRIVERS x11/libvideo_x11.la"
fi
fi
}

dnl Find the X11 DGA 2.0 include and library directories
CheckDGA()
{
@@ -2721,7 +2709,7 @@ case "$target" in
CheckDiskAudio
CheckCOCOA
CheckCARBON
CheckMacX11
CheckX11
CheckMacGL
CheckPTHREAD
CheckSIGACTION

0 comments on commit ac89c74

Please sign in to comment.