[Spice-devel] [PATCH spice-gtk v6 1/4] Add check for macOS and macOS specific define to allow ucontext
Frediano Ziglio
fziglio at redhat.com
Wed May 31 13:04:40 UTC 2017
>
> From: Christophe de Dinechin <dinechin at redhat.com>
>
> Signed-off-by: Christophe de Dinechin <dinechin at redhat.com>
Acked-by: Frediano Ziglio <fziglio at redhat.com>
Frediano
> ---
> configure.ac | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/configure.ac b/configure.ac
> index ff00d73..62acafc 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -62,6 +62,18 @@ esac
> AC_MSG_RESULT([$os_win32])
> AM_CONDITIONAL([OS_WIN32],[test "$os_win32" = "yes"])
>
> +AC_MSG_CHECKING([for native macOS])
> +case "$host_os" in
> + *darwin*)
> + os_mac=yes
> + ;;
> + *)
> + os_mac=no
> + ;;
> +esac
> +AC_MSG_RESULT([$os_mac])
> +AM_CONDITIONAL([OS_MAC],[test "$os_mac" = "yes"])
> +
> AC_CHECK_HEADERS([sys/socket.h netinet/in.h arpa/inet.h])
> AC_CHECK_HEADERS([termios.h])
> AC_CHECK_HEADERS([epoxy/egl.h],
> @@ -468,6 +480,9 @@ esac
> if test "$with_coroutine" = "auto"; then
> if test "$os_win32" = "yes"; then
> with_coroutine=winfiber
> + elif test "$os_mac" = "yes"; then
> + with_coroutine=ucontext
> + AC_DEFINE([_XOPEN_SOURCE], [1], [Define _XOPEN_SOURCE on macOS for
> ucontext])
> else
> with_coroutine=ucontext
> fi
More information about the Spice-devel
mailing list