Commit 7aad79c5 authored by Keith Packard's avatar Keith Packard

Make XTrans FD passing support optional. Define only on Linux

Until other operating systems have a libXtrans port for FD passing,
disable this on non-Linux systems.

Note that this define affects how libXtrans gets built into the X
server, which is why it need only define the symbol
Signed-off-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
parent ab4b1fb3
......@@ -1118,6 +1118,41 @@ case "$DRI2,$HAVE_DRI2PROTO" in
esac
AM_CONDITIONAL(DRI2, test "x$DRI2" = xyes)
AC_ARG_ENABLE(xtrans-send-fds, AS_HELP_STRING([--disable-xtrans-send-fds], [Use Xtrans support for fd passing (default: auto)]), [XTRANS_SEND_FDS=$enableval], [XTRANS_SEND_FDS=auto])
case "x$XTRANS_SEND_FDS" in
xauto)
case "$host_os" in
linux*)
XTRANS_SEND_FDS=yes
;;
*)
XTRANS_SEND_FDS=no
;;
esac
esac
case "x$XTRANS_SEND_FDS" in
xyes)
AC_DEFINE(XTRANS_SEND_FDS, 1, [Enable xtrans fd passing support])
;;
esac
case "$DRI3,$XTRANS_SEND_FDS" in
yes,yes | auto,yes)
;;
yes,no)
AC_MSG_ERROR([DRI3 requested, but xtrans fd passing support not found.])
DRI3=no
;;
no,*)
;;
*)
AC_MSG_NOTICE([DRI3 disabled because xtrans fd passing support not found.])
DRI3=no
;;
esac
PKG_CHECK_MODULES([DRI3PROTO], $DRI3PROTO,
[HAVE_DRI3PROTO=yes], [HAVE_DRI3PROTO=no])
......
......@@ -452,4 +452,7 @@
/* Have support for X shared memory fence library (xshmfence) */
#undef HAVE_XSHMFENCE
/* Use XTrans FD passing support */
#undef XTRANS_SEND_FDS
#endif /* _DIX_CONFIG_H_ */
......@@ -221,4 +221,7 @@
/* Have support for X shared memory fence library (xshmfence) */
#undef HAVE_XSHMFENCE
/* Use XTrans FD passing support */
#undef XTRANS_SEND_FDS
#endif /* _XORG_SERVER_H_ */
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