More patches from downstream

This commit is contained in:
Ben Byer 2007-10-27 23:33:51 -07:00 committed by Jeremy Huddleston
parent 21f35c1b7c
commit 6ff9f43ae2
15 changed files with 1404 additions and 673 deletions

10
GL/apple/Makefile.am Normal file
View File

@ -0,0 +1,10 @@
AM_CFLAGS = -I$(top_srcdir) \
-I$(top_srcdir)/GL/glx \
-I$(top_srcdir)/GL/include \
-I$(top_srcdir)/GL/mesa/glapi \
-I$(top_srcdir)/hw/darwin/quartz \
-I$(top_srcdir)/hw/darwin/quartz/xpr
noinst_LIBRARIES = libCGLcore.a
libCGLcore_a_SOURCES = indirect.c \
$(top_srcdir)/hw/dmx/glxProxy/compsize.c

View File

@ -1008,6 +1008,7 @@ static Bool init_visuals(int *nvisualp, VisualPtr *visualp,
return TRUE;
}
Bool enable_stereo = false;
/* based on code in i830_dri.c
This ends calling glAquaSetVisualConfigs to set the static
numconfigs, etc. */
@ -1022,16 +1023,18 @@ glAquaInitVisualConfigs(void)
int i = 0;
GLAQUA_DEBUG_MSG("glAquaInitVisualConfigs ");
/* count num configs:
2 stereo (on, off) (optional)
2 Z buffer (0, 24 bit)
2 AUX buffer (0, 2)
2 buffers (single, double)
2 stencil (0, 8 bit)
2 accum (0, 64 bit)
= 32 configs */
= 64 configs with stereo, or 32 without */
lclNumConfigs = 2 * 2 * 2 * 2 * 2; /* 32 */
if (enable_stereo) lclNumConfigs = 2 * 2 * 2 * 2 * 2 * 2; /* 64 */
else lclNumConfigs = 2 * 2 * 2 * 2 * 2; /* 32 */
/* alloc */
lclVisualConfigs = xcalloc(sizeof(__GLXvisualConfig), lclNumConfigs);
@ -1040,54 +1043,55 @@ glAquaInitVisualConfigs(void)
/* fill in configs */
if (NULL != lclVisualConfigs) {
i = 0; /* current buffer */
for (depth = 0; depth < 2; depth++) {
for (stereo = 0; stereo < (enable_stereo ? 2 : 1); stereo++) {
for (depth = 0; depth < 2; depth++) {
for (aux = 0; aux < 2; aux++) {
for (buffers = 0; buffers < 2; buffers++) {
for (stencil = 0; stencil < 2; stencil++) {
for (accum = 0; accum < 2; accum++) {
lclVisualConfigs[i].vid = -1;
lclVisualConfigs[i].class = -1;
lclVisualConfigs[i].rgba = TRUE;
lclVisualConfigs[i].redSize = -1;
lclVisualConfigs[i].greenSize = -1;
lclVisualConfigs[i].blueSize = -1;
lclVisualConfigs[i].redMask = -1;
lclVisualConfigs[i].greenMask = -1;
lclVisualConfigs[i].blueMask = -1;
lclVisualConfigs[i].alphaMask = 0;
if (accum) {
lclVisualConfigs[i].accumRedSize = 16;
lclVisualConfigs[i].accumGreenSize = 16;
lclVisualConfigs[i].accumBlueSize = 16;
lclVisualConfigs[i].accumAlphaSize = 16;
}
else {
lclVisualConfigs[i].accumRedSize = 0;
lclVisualConfigs[i].accumGreenSize = 0;
lclVisualConfigs[i].accumBlueSize = 0;
lclVisualConfigs[i].accumAlphaSize = 0;
}
lclVisualConfigs[i].doubleBuffer = buffers ? TRUE : FALSE;
lclVisualConfigs[i].stereo = FALSE;
lclVisualConfigs[i].bufferSize = -1;
lclVisualConfigs[i].depthSize = depth? 24 : 0;
lclVisualConfigs[i].stencilSize = stencil ? 8 : 0;
lclVisualConfigs[i].auxBuffers = aux ? 2 : 0;
lclVisualConfigs[i].level = 0;
lclVisualConfigs[i].visualRating = GLX_NONE_EXT;
lclVisualConfigs[i].transparentPixel = 0;
lclVisualConfigs[i].transparentRed = 0;
lclVisualConfigs[i].transparentGreen = 0;
lclVisualConfigs[i].transparentBlue = 0;
lclVisualConfigs[i].transparentAlpha = 0;
lclVisualConfigs[i].transparentIndex = 0;
i++;
}
}
}
for (buffers = 0; buffers < 2; buffers++) {
for (stencil = 0; stencil < 2; stencil++) {
for (accum = 0; accum < 2; accum++) {
lclVisualConfigs[i].vid = -1;
lclVisualConfigs[i].class = -1;
lclVisualConfigs[i].rgba = TRUE;
lclVisualConfigs[i].redSize = -1;
lclVisualConfigs[i].greenSize = -1;
lclVisualConfigs[i].blueSize = -1;
lclVisualConfigs[i].redMask = -1;
lclVisualConfigs[i].greenMask = -1;
lclVisualConfigs[i].blueMask = -1;
lclVisualConfigs[i].alphaMask = 0;
if (accum) {
lclVisualConfigs[i].accumRedSize = 16;
lclVisualConfigs[i].accumGreenSize = 16;
lclVisualConfigs[i].accumBlueSize = 16;
lclVisualConfigs[i].accumAlphaSize = 16;
} else {
lclVisualConfigs[i].accumRedSize = 0;
lclVisualConfigs[i].accumGreenSize = 0;
lclVisualConfigs[i].accumBlueSize = 0;
lclVisualConfigs[i].accumAlphaSize = 0;
}
lclVisualConfigs[i].doubleBuffer = buffers ? TRUE : FALSE;
lclVisualConfigs[i].stereo = stereo ? TRUE : FALSE;
lclVisualConfigs[i].bufferSize = -1;
lclVisualConfigs[i].depthSize = depth? 24 : 0;
lclVisualConfigs[i].stencilSize = stencil ? 8 : 0;
lclVisualConfigs[i].auxBuffers = aux ? 2 : 0;
lclVisualConfigs[i].level = 0;
lclVisualConfigs[i].visualRating = GLX_NONE_EXT;
lclVisualConfigs[i].transparentPixel = 0;
lclVisualConfigs[i].transparentRed = 0;
lclVisualConfigs[i].transparentGreen = 0;
lclVisualConfigs[i].transparentBlue = 0;
lclVisualConfigs[i].transparentAlpha = 0;
lclVisualConfigs[i].transparentIndex = 0;
i++;
}
}
}
}
}
}
}
}
if (i != lclNumConfigs)
GLAQUA_DEBUG_MSG("glAquaInitVisualConfigs failed to alloc visual configs");
@ -1095,7 +1099,6 @@ glAquaInitVisualConfigs(void)
GlxSetVisualConfigs(lclNumConfigs, lclVisualConfigs, lclVisualPrivates);
}
static void glAquaSetVisualConfigs(int nconfigs, __GLXvisualConfig *configs,
void **privates)
{

File diff suppressed because it is too large Load Diff

View File

@ -198,7 +198,7 @@ case $host_cpu in
ARM_VIDEO=yes
;;
i*86)
use_x86_asm="yes"
use_x86_asm="no"
I386_VIDEO=yes
case $host_os in
*linux*) DEFAULT_INT10=vm86 ;;
@ -223,7 +223,7 @@ case $host_cpu in
BSD_ARCH_SOURCES="sparc64_video.c ioperm_noop.c"
;;
x86_64*|amd64*)
use_x86_asm="yes"
use_x86_asm="no"
I386_VIDEO=yes
case $host_os in
*freebsd*) AC_DEFINE(USE_DEV_IO, 1, [BSD /dev/io]) ;;
@ -363,9 +363,10 @@ AC_ARG_WITH(os-name, AS_HELP_STRING([--with-os-name=OSNAME], [Name of OS
AC_ARG_WITH(os-vendor, AS_HELP_STRING([--with-os-vendor=OSVENDOR], [Name of OS vendor]),
[ OSVENDOR="$withval" ],
[ OSVENDOR="" ])
AC_ARG_VAR([MESA_SOURCE],[Path to Mesa source tree])
AC_ARG_WITH(mesa-source, AS_HELP_STRING([--with-mesa-source=MESA_SOURCE], [Path to Mesa source tree]),
[ MESA_SOURCE="$withval" ],
[ MESA_SOURCE="" ])
[ MESA_SOURCE="${MESA_SOURCE}" ])
AC_ARG_WITH(fontdir, AS_HELP_STRING([--with-fontdir=FONTDIR], [Path to top level dir where fonts are installed (default: ${libdir}/X11/fonts)]),
[ FONTDIR="$withval" ],
[ FONTDIR="${libdir}/X11/fonts" ])
@ -385,6 +386,11 @@ AC_ARG_WITH(rgb-path, AS_HELP_STRING([--with-rgb-path=PATH], [Path to RG
AC_ARG_WITH(dri-driver-path, AS_HELP_STRING([--with-dri-driver-path=PATH], [Path to DRI drivers (default: ${libdir}/dri)]),
[ DRI_DRIVER_PATH="$withval" ],
[ DRI_DRIVER_PATH="${libdir}/dri" ])
APPLE_APPLICATIONS_DIR="${bindir}/Applications"
AC_ARG_WITH(apple-applications-dir,AS_HELP_STRING([--with-apple-applications-dir=PATH], [Path to the Applications directory (default: ${bindir}/Applications)]),
[ APPLE_APPLICATIONS_DIR="${withval}" ].
[ APPLE_APPLICATIONS_DIR="${bindir}/Applications" ])
AC_ARG_ENABLE(builddocs, AS_HELP_STRING([--enable-builddocs], [Build docs (default: disabled)]),
[BUILDDOCS=$enableval],
[BUILDDOCS=no])
@ -401,6 +407,7 @@ AC_ARG_ENABLE(xres, AS_HELP_STRING([--disable-xres], [Build XRes exten
AC_ARG_ENABLE(xtrap, AS_HELP_STRING([--disable-xtrap], [Build XTrap extension (default: enabled)]), [XTRAP=$enableval], [XTRAP=yes])
AC_ARG_ENABLE(record, AS_HELP_STRING([--disable-record], [Build Record extension (default: enabled)]), [RECORD=$enableval], [RECORD=yes])
AC_ARG_ENABLE(xv, AS_HELP_STRING([--disable-xv], [Build Xv extension (default: enabled)]), [XV=$enableval], [XV=yes])
AC_ARG_ENABLE(quartz, AS_HELP_STRING([--enable-quartz], [Build with darwin quartz support (default: auto)]), [XQUARTZ=$enableval], [XQUARTZ=auto])
AC_ARG_ENABLE(xvmc, AS_HELP_STRING([--disable-xvmc], [Build XvMC extension (default: enabled)]), [XVMC=$enableval], [XVMC=yes])
AC_ARG_ENABLE(dga, AS_HELP_STRING([--disable-dga], [Build DGA extension (default: enabled)]), [DGA=$enableval], [DGA=yes])
AC_ARG_ENABLE(screensaver, AS_HELP_STRING([--disable-screensaver], [Build ScreenSaver extension (default: enabled)]), [SCREENSAVER=$enableval], [SCREENSAVER=yes])
@ -431,11 +438,11 @@ AC_ARG_ENABLE(xfree86-utils, AS_HELP_STRING([--enable-xfree86-utils], [Build
dnl DDXes.
AC_ARG_ENABLE(xorg, AS_HELP_STRING([--enable-xorg], [Build Xorg server (default: auto)]), [XORG=$enableval], [XORG=auto])
AC_ARG_ENABLE(dmx, AS_HELP_STRING([--enable-dmx], [Build DMX server (default: no)]), [DMX=$enableval], [DMX=no])
AC_ARG_ENABLE(xvfb, AS_HELP_STRING([--enable-xvfb], [Build Xvfb server (default: no)]), [XVFB=$enableval], [XVFB=yes])
AC_ARG_ENABLE(dmx, AS_HELP_STRING([--enable-dmx], [Build DMX server (default: auto)]), [DMX=$enableval], [DMX=auto])
AC_ARG_ENABLE(xvfb, AS_HELP_STRING([--enable-xvfb], [Build Xvfb server (default: yes)]), [XVFB=$enableval], [XVFB=yes])
AC_ARG_ENABLE(xnest, AS_HELP_STRING([--enable-xnest], [Build Xnest server (default: auto)]), [XNEST=$enableval], [XNEST=auto])
AC_ARG_ENABLE(xwin, AS_HELP_STRING([--enable-xwin], [Build XWin server (default: auto)]), [XWIN=$enableval], [XWIN=auto])
AC_ARG_ENABLE(xprint, AS_HELP_STRING([--enable-xprint], [Build Xprint extension and server (default: no)]), [XPRINT=$enableval], [XPRINT=no])
AC_ARG_ENABLE(xprint, AS_HELP_STRING([--enable-xprint], [Build Xprint extension and server (default: auto)]), [XPRINT=$enableval], [XPRINT=auto])
AC_ARG_ENABLE(xgl, AS_HELP_STRING([--enable-xgl], [Build Xgl server (default: no)]), [XGL=$enableval], [XGL=no])
AC_ARG_ENABLE(xglx, AS_HELP_STRING([--enable-xglx], [Build Xglx xgl module (default: no)]), [XGLX=$enableval], [XGLX=no])
AC_ARG_ENABLE(xegl, AS_HELP_STRING([--enable-xegl], [Build Xegl xgl module (default: no)]), [XEGL=$enableval], [XEGL=no])
@ -462,7 +469,7 @@ if test "x$SETUID" = "xauto" ; then
case $host_cpu in
sparc) SETUID="no" ;;
*) SETUID="yes" ;;
esac
esac ;;
esac
if test "x$SETUID" = xyes; then
touch testfile
@ -531,10 +538,6 @@ if test "x$XVMC" = xyes; then
AC_DEFINE(XvMCExtension, 1, [Build XvMC extension])
fi
AM_CONDITIONAL(DGA, [test "x$DGA" = xyes])
if test "x$DGA" = xyes; then
AC_DEFINE(DGA, 1, [Support DGA extension])
fi
AM_CONDITIONAL(COMPOSITE, [test "x$COMPOSITE" = xyes])
if test "x$COMPOSITE" = xyes; then
@ -580,7 +583,7 @@ if test "x$GLX" = xyes && ! test "x$MESA_SOURCE" = x; then
PKG_CHECK_MODULES([GL], [glproto >= 1.4.8])
AC_SUBST(XLIB_CFLAGS)
AC_DEFINE(GLXEXT, 1, [Build GLX extension])
GLX_LIBS='$(top_builddir)/GL/glx/libglx.la $(top_builddir)/GL/mesa/libGLcore.la'
GLX_LIBS='$(top_builddir)/GL/apple/indirect.o $(top_builddir)/GL/glx/libglx.la'
test -d GL || mkdir GL
case $host_os in
solaris*)
@ -696,14 +699,6 @@ if test "x$DPMSExtension" = xyes; then
AC_DEFINE(DPMSExtension, 1, [Support DPMS extension])
fi
if test "x$XF86VIDMODE" = xyes; then
AC_DEFINE(XF86VIDMODE, 1, [Support XFree86 Video Mode extension])
fi
if test "x$XF86MISC" = xyes; then
AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions])
fi
if test "x$XPRINT" = xauto; then
PKG_CHECK_MODULES([XPRINTPROTO], [printproto], [XPRINT=yes], [XPRINT=no])
fi
@ -835,7 +830,7 @@ AC_SUBST([VENDOR_STRING])
AC_SUBST([VENDOR_STRING_SHORT])
AC_SUBST([VENDOR_RELEASE])
AC_SUBST([VENDOR_MAN_VERSION])
AC_SUBST([XORG_DATE])
AC_DEFINE(DDXOSINIT, 1, [Use OsVendorInit])
AC_DEFINE(SERVER_LOCK, 1, [Use a lock to prevent multiple servers on a display])
AC_DEFINE(SMART_SCHEDULE, 1, [Include time-based scheduler])
@ -925,7 +920,19 @@ AC_DEFINE([SVR4],1,[Define to 1 on systems derived from System V Release 4])
AC_MSG_RESULT([yes])], AC_MSG_RESULT([no]))
XSERVER_CFLAGS="$XSERVER_CFLAGS $CORE_INCS $XEXT_INC $COMPOSITE_INC $DAMAGE_INC $FIXES_INC $XI_INC $MI_INC $MIEXT_SHADOW_INC $MIEXT_LAYER_INC $MIEXT_DAMAGE_INC $RENDER_INC $RANDR_INC $FB_INC"
AC_DEFINE_UNQUOTED(X_BYTE_ORDER,[$ENDIAN],[Endian order])
AC_DEFINE_UNQUOTED(_X_BYTE_ORDER,[$ENDIAN],[Endian order])
AH_VERBATIM([X_BYTE_ORDER],[
/* Deal with multiple architecture compiles on Mac OS X */
#ifndef __APPLE_CC__
#define X_BYTE_ORDER _X_BYTE_ORDER
#else
#ifdef __BIG_ENDIAN__
#define X_BYTE_ORDER X_BIG_ENDIAN
#else
#define X_BYTE_ORDER X_LITTLE_ENDIAN
#endif
#endif
])
AC_SUBST([XSERVER_LIBS])
@ -1099,6 +1106,61 @@ dnl has it in libc), or if libdl is needed to get it.
AC_CHECK_LIB([dl], [dlopen], XORG_LIBS="$XORG_LIBS -ldl"))
case $host_os in
darwin*)
XORG_OS="Darwin"
build_darwin=yes
if test "X$XQUARTZ" = Xauto; then
AC_CACHE_CHECK([for Carbon framework],xorg_cv_Carbon_framework,[
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -framework Carbon"
AC_LINK_IFELSE([char FSFindFolder();
int main() {
FSFindFolder();
return 0;}
],[xorg_cv_Carbon_framework=yes],
[xorg_cv_Carbon_framework=no])
LDFLAGS=$save_LDFLAGS])
if test "X$xorg_cv_Carbon_framework" = Xyes; then
AC_DEFINE([DARWIN_WITH_QUARTZ],[1],
[Have Quartz])
XQUARTZ=yes
else
XQUARTZ=no
fi
fi
AC_DEFINE(ROOTLESS,1,[Build Rootless code])
AC_CACHE_CHECK([for AGL framework],xorg_cv_AGL_framework,[
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -framework AGL"
AC_LINK_IFELSE([char aglEnable();
int main() {
aglEnable();
return 0;}
],[xorg_cv_AGL_framework=yes],
[xorg_cv_AGL_framework=no])
LDFLAGS=$save_LDFLAGS
])
AC_CHECK_LIB([Xplugin],[xp_init],[:])
AC_SUBST([APPLE_APPLICATIONS_DIR])
CFLAGS="${CFLAGS} -D__DARWIN__"
PLIST_VERSION_STRING=$VENDOR_VERSION_STRING
AC_SUBST([PLIST_VERSION_STRING])
PLIST_VENDOR_WEB=$VENDOR_WEB
AC_SUBST([PLIST_VENDOR_WEB])
# Not sure that we should be disabling all these...
if test "x$XF86MISC" = xyes; then
AC_MSG_NOTICE([Disabling XF86Misc extension])
XF86MISC=no
fi
if test "x$XF86VIDMODE" = xyes; then
AC_MSG_NOTICE([Disabling XF86VidMode extension])
XF86VIDMODE=no
fi
if test "x$DGA" = xyes; then
AC_MSG_NOTICE([Disabling DGA extension])
DGA=no
fi
;;
linux*)
if test "x$LNXAPM" = xyes; then
XORG_CFLAGS="$XORG_CFLAGS -DXF86PM"
@ -1240,11 +1302,14 @@ int main () {
case $host_cpu in
i*86)
xorg_bus_ix86pci=yes
case $host_os in
darwin*) ;;
*) xorg_bus_ix86pci=yes ;;
esac
;;
powerpc*)
case $host_os in
linux*|freebsd*|netbsd*|openbsd*|kfreebsd*-gnu)
darwin*|linux*|freebsd*|netbsd*|openbsd*|kfreebsd*-gnu)
;;
*)
xorg_bus_ppcpci="yes"
@ -1257,7 +1322,7 @@ int main () {
;;
x86_64*|amd64*)
case $host_os in
freebsd*|kfreebsd*-gnu)
darwin*|freebsd*|kfreebsd*-gnu)
# FreeBSD uses the system pci interface
;;
*)
@ -1297,7 +1362,13 @@ int main () {
GCC_WARNINGS="${GCC_WARNINGS} -Werror"
fi
XSERVER_CFLAGS="$GCC_WARNINGS $XSERVER_CFLAGS"
LD_EXPORT_SYMBOLS_FLAG="-rdynamic"
case $host_os in
darwin*) ;; # Symbols are exported by default, no need
# to do anything special. I think that the following
# is wrong anyway when using libtool. Should be using
# the libtool flag -export-dynamic?
*)LD_EXPORT_SYMBOLS_FLAG="-rdynamic" ;;
esac
fi
case $host_os in
openbsd*)
@ -1338,6 +1409,26 @@ int main () {
AC_SUBST([extdir])
AC_SUBST([logdir])
fi
if test "x$XF86VIDMODE" = xyes; then
AC_DEFINE(XF86VIDMODE, 1, [Support XFree86 Video Mode extension])
fi
if test "x$XF86MISC" = xyes; then
AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions])
fi
# Support for objc in autotools is minimal and not documented.
OBJC='$(CC)'
OBJCLD='$(CCLD)'
OBJCLINK='$(LINK)'
OBJCFLAGS='$(CFLAGS)'
AC_SUBST([OBJC])
AC_SUBST([OBJCCLD])
AC_SUBST([OBJCLINK])
AC_SUBST([OBJCFLAGS])
# internal, undocumented automake func follows :(
_AM_DEPENDENCIES([OBJC])
AM_CONDITIONAL([XORG], [test "x$XORG" = xyes])
AM_CONDITIONAL([XORG_BUS_LINUXPCI], [test "x$xorg_bus_linuxpci" = xyes])
AM_CONDITIONAL([XORG_BUS_FREEBSDPCI], [test "x$xorg_bus_freebsdpci" = xyes])
@ -1355,6 +1446,8 @@ AM_CONDITIONAL([SOLARIS_ASM_INLINE], [test "x$solaris_asm_inline" = xyes])
AM_CONDITIONAL(MFB, [test "x$XORG" = xyes])
AM_CONDITIONAL(CFB, [test "x$XORG" = xyes])
AM_CONDITIONAL(AFB, [test "x$XORG" = xyes])
AM_CONDITIONAL([BUILD_DARWIN],[test "X$build_darwin" = Xyes])
AM_CONDITIONAL([XQUARTZ],[test "X$XQUARTZ" = Xyes])
dnl Xprint DDX
@ -1364,7 +1457,7 @@ AC_MSG_RESULT([$XPRINT])
if test "x$XPRINT" = xyes; then
PKG_CHECK_MODULES([XPRINT], [printproto x11 xfont $XDMCP_MODULES xau])
XPRINT_EXTENSIONS="$XEXT_LIB $DBE_LIB $XTRAP_LIB $RECORD_LIB $RENDER_LIB $COMPOSITE_LIB $RANDR_LIB $XI_LIB $FIXES_LIB $DAMAGE_LIB $XI_LIB $GLX_LIBS"
XPRINT_LIBS="$XPRINT_LIBS $DIX_LIB $XKB_LIB $XKB_STUB_LIB $XPRINT_EXTENSIONS $MI_LIB $MIEXT_DAMAGE_LIB $CWRAP_LIB $OS_LIB"
XPRINT_LIBS="$DIX_LIB $XPRINT_LIBS $XKB_LIB $XKB_STUB_LIB $XPRINT_EXTENSIONS $MI_LIB $MIEXT_DAMAGE_LIB $CWRAP_LIB $OS_LIB"
AC_SUBST([XPRINT_CFLAGS])
AC_SUBST([XPRINT_LIBS])
@ -1409,7 +1502,6 @@ if test "x$XPRINT" = xyes; then
fi
AM_CONDITIONAL(XP_USE_FREETYPE, [test "x$XPRINT" = xyes && test "x$XP_USE_FREETYPE" = xyes])
dnl XWin DDX
AC_MSG_CHECKING([whether to build XWin DDX])
@ -1595,8 +1687,11 @@ AC_DEFINE_DIR(XKM_OUTPUT_DIR, XKBOUTPUT, [Path to XKB output dir])
AC_SUBST(XKB_COMPILED_DIR)
AM_CONDITIONAL(DGA, [test "x$DGA" = xyes])
if test "x$DGA" = xyes; then
AC_DEFINE(DGA, 1, [Support DGA extension])
fi
dnl and the rest of these are generic, so they're in config.h
AC_DEFINE(XFreeXDGA, 1, [Build XDGA support])
AC_DEFINE(XResExtension, 1, [Build XRes extension])
AC_TRY_COMPILE([
@ -1678,6 +1773,7 @@ XORG_RELEASE_VERSION
AC_OUTPUT([
Makefile
GL/Makefile
GL/apple/Makefile
GL/glx/Makefile
GL/mesa/Makefile
GL/mesa/array_cache/Makefile
@ -1710,6 +1806,8 @@ miext/damage/Makefile
miext/shadow/Makefile
miext/cw/Makefile
miext/rootless/Makefile
miext/rootless/safeAlpha/Makefile
miext/rootless/accel/Makefile
os/Makefile
randr/Makefile
render/Makefile
@ -1787,6 +1885,22 @@ hw/xgl/glxext/module/Makefile
hw/xnest/Makefile
hw/xwin/Makefile
hw/darwin/Makefile
hw/darwin/bundle/Makefile
hw/darwin/bundle/Dutch.lproj/Makefile
hw/darwin/bundle/English.lproj/Makefile
hw/darwin/bundle/French.lproj/Makefile
hw/darwin/bundle/German.lproj/Makefile
hw/darwin/bundle/Japanese.lproj/Makefile
hw/darwin/bundle/Portuguese.lproj/Makefile
hw/darwin/bundle/Spanish.lproj/Makefile
hw/darwin/bundle/Swedish.lproj/Makefile
hw/darwin/bundle/ko.lproj/Makefile
hw/darwin/iokit/Makefile
hw/darwin/quartz/Makefile
hw/darwin/quartz/cr/Makefile
hw/darwin/quartz/fullscreen/Makefile
hw/darwin/quartz/xpr/Makefile
hw/darwin/utils/Makefile
hw/kdrive/Makefile
hw/kdrive/ati/Makefile
hw/kdrive/chips/Makefile

View File

@ -235,7 +235,6 @@ glxMesa_la_DEPENDENCIES = XDarwinApp
endif
endif
if HAVE_X_PLUGIN
xprplugindir = $(darwinappdir)/Contents/Resources/xpr.bundle/Contents/MacOS
xprplugin_LTLIBRARIES =
@ -259,9 +258,6 @@ xpr_la_LDFLAGS = -shrext '' -Wl,-framework,ApplicationServices \
-module -avoid-version -no-undefined
xpr_la_DEPENDENCIES = XDarwinApp
endif
if HAVE_AGL_FRAMEWORK
glxCGLplugindir = $(darwinappdir)/Contents/Resources/glxCGL.bundle/Contents/MacOS
glxCGLplugin_LTLIBRARIES =
glxCGL_la_SOURCES =
@ -293,10 +289,6 @@ glxAGL_la_LDFLAGS = -shrext '' \
-module -avoid-version -no-undefined
glxAGL_la_DEPENDENCIES = XDarwinApp
endif
man1_MANS = XDarwin.man
uninstall-hook:

View File

@ -5,10 +5,9 @@ AM_OBJCFLAGS = @XORG_CFLAGS@
INCLUDES = -I$(srcdir) -I$(srcdir)/.. @XORG_INCS@
AM_DEFS = -DHAS_CG_MACH_PORT -DHAS_KL_API
if HAVE_X_PLUGIN
AM_DEFS += -DBUILD_XPR
XPR = xpr
endif
DEFS = @DEFS@ $(AM_DEFS) -DXBINDIR=\"${bindir}\"
SUBDIRS = cr fullscreen $(XPR)

View File

@ -338,14 +338,16 @@ extern void XFree86DGAExtensionInit(INITARGS);
#endif
#ifdef GLXEXT
typedef struct __GLXprovider __GLXprovider;
extern __GLXprovider __glXMesaProvider;
extern void GlxPushProvider(__GLXprovider *impl);
#ifndef __DARWIN__
extern void GlxExtensionInit(INITARGS);
extern void GlxWrapInitVisuals(miInitVisualsProcPtr *);
#else
#if defined(__DARWIN__) && !defined(INXQUARTZ)
extern __GLXprovider* __DarwinglXMesaProvider;
extern void DarwinGlxPushProvider(__GLXprovider *impl);
extern void DarwinGlxExtensionInit(INITARGS);
extern void DarwinGlxWrapInitVisuals(miInitVisualsProcPtr *);
#else
extern __GLXprovider __glXMesaProvider;
extern void GlxPushProvider(__GLXprovider *impl);
extern void GlxExtensionInit(INITARGS);
extern void GlxWrapInitVisuals(miInitVisualsProcPtr *);
#endif
#endif
#ifdef XF86DRI
@ -630,12 +632,12 @@ InitExtensions(argc, argv)
#endif
#endif
#ifdef GLXEXT
GlxPushProvider(&__glXMesaProvider);
#ifndef __DARWIN__
if (!noGlxExtension) GlxExtensionInit();
#else
#if defined(__DARWIN__) && !defined(INXQUARTZ)
DarwinGlxPushProvider(__DarwinglXMesaProvider);
if (!noGlxExtension) DarwinGlxExtensionInit();
#else
GlxPushProvider(&__glXMesaProvider);
if (!noGlxExtension) GlxExtensionInit();
#endif
#endif
#ifdef XFIXES

View File

@ -2,4 +2,7 @@ SUBDIRS = damage shadow
if COMPOSITE
SUBDIRS += cw
endif
if XQUARTZ
SUBDIRS += rootless
endif
DIST_SUBDIRS = damage shadow cw rootless

View File

@ -1,14 +1,13 @@
EXTRA_DIST = \
accel/rlAccel.c \
accel/rlAccel.h \
accel/rlBlt.c \
accel/rlCopy.c \
accel/rlFill.c \
accel/rlFillRect.c \
accel/rlFillSpans.c \
accel/rlGlyph.c \
accel/rlSolid.c \
README.txt \
AM_CFLAGS = \
$(DIX_CFLAGS) \
$(XORG_CFLAGS)
INCLUDES = -I$(top_srcdir)/hw/xfree86/os-support
SUBDIRS = safeAlpha accel
noinst_LTLIBRARIES = librootless.la
librootless_la_SOURCES = \
rootlessCommon.c \
rootlessCommon.h \
rootlessConfig.h \
@ -17,7 +16,7 @@ EXTRA_DIST = \
rootlessScreen.c \
rootlessValTree.c \
rootlessWindow.c \
rootlessWindow.h \
safeAlpha/safeAlpha.h \
safeAlpha/safeAlphaPicture.c \
safeAlpha/safeAlphaWindow.c
rootlessWindow.h
EXTRA_DIST = \
README.txt

View File

@ -0,0 +1,18 @@
AM_CFLAGS = \
$(DIX_CFLAGS) \
$(XORG_CFLAGS)
INCLUDES = -I$(srcdir)/.. -I$(top_srcdir)/hw/xfree86/os-support
noinst_LTLIBRARIES = librlAccel.la
librlAccel_la_SOURCES = rlAccel.c \
rlBlt.c \
rlCopy.c \
rlFill.c \
rlFillRect.c \
rlFillSpans.c \
rlGlyph.c \
rlSolid.c
EXTRA_DIST = rlAccel.h

View File

@ -33,6 +33,10 @@
#include <dix-config.h>
#endif
#include <stddef.h> /* For NULL */
#include <limits.h> /* For CHAR_BIT */
#include <assert.h>
#include "rootlessCommon.h"
#include "rootlessWindow.h"
@ -325,8 +329,8 @@ RootlessEnsureFrame(WindowPtr pWin)
RootlessWindowRec *winRec;
#ifdef SHAPE
RegionRec shape;
RegionPtr pShape = NULL;
#endif
RegionPtr pShape = NULL;
if (WINREC(pWin) != NULL)
return WINREC(pWin);

View File

@ -0,0 +1,12 @@
AM_CFLAGS = \
$(DIX_CFLAGS) \
$(XORG_CFLAGS)
INCLUDES = -I$(srcdir)/.. -I$(top_srcdir)/hw/xfree86/os-support
noinst_LTLIBRARIES = libsafeAlpha.la
libsafeAlpha_la_SOURCES = safeAlphaPicture.c \
safeAlphaWindow.c
EXTRA_DIST = safeAlpha.h

View File

@ -33,15 +33,19 @@
* Copyright © 2000 Keith Packard, member of The XFree86 Project, Inc.
*/
#ifdef HAVE_DIX_CONFIG_H
#include <dix-config.h>
#endif
#ifdef RENDER
#include <stddef.h> /* For NULL */
#include "fb.h"
#include "picturestr.h"
#include "mipict.h"
#include "fbpict.h"
#include "safeAlpha.h"
#include "rootlessCommon.h"
# define mod(a,b) ((b) == 1 ? 0 : (a) >= 0 ? (a) % (b) : (b) - (-a) % (b))

View File

@ -32,6 +32,10 @@
* Copyright © 1998 Keith Packard
*/
#ifdef HAVE_DIX_CONFIG_H
#include <dix-config.h>
#endif
#include "fb.h"
#include "safeAlpha.h"
#include "rootlessCommon.h"

View File

@ -74,6 +74,7 @@ SOFTWARE.
#define TRANS_SERVER
#define TRANS_REOPEN
#include <X11/Xtrans/Xtrans.h>
#include <X11/Xtrans/Xtransint.h>
#include <errno.h>
#include <signal.h>
#include <stdio.h>
@ -670,9 +671,15 @@ ClientAuthorized(ClientPtr client,
XID auth_id;
char *reason = NULL;
XtransConnInfo trans_conn;
struct sockaddr *saddr;
priv = (OsCommPtr)client->osPrivate;
trans_conn = priv->trans_conn;
saddr = (struct sockaddr *) (trans_conn->addr);
/* Allow any client to connect without authorization on a launchd socket,
because it is securely created -- this prevents a race condition on launch */
if (saddr->sa_len > 11 && saddr->sa_family == AF_UNIX &&
!strncmp(saddr->sa_data, "/tmp/launch", 11)) goto done;
auth_id = CheckAuthorization (proto_n, auth_proto,
string_n, auth_string, client, &reason);
@ -721,6 +728,7 @@ ClientAuthorized(ClientPtr client,
}
}
priv->auth_id = auth_id;
done:
priv->conn_time = 0;
#ifdef XDMCP