[Spice-devel] [PATCHv3 spice-gtk 01/14] compat: add strtok_r fallback

Christophe Fergeau cfergeau at redhat.com
Thu Feb 20 06:24:28 PST 2014


On Mon, Feb 17, 2014 at 10:35:40PM +0100, Marc-André Lureau wrote:
> diff --git a/gtk/glib-compat.h b/gtk/glib-compat.h
> index c30a735..62580e2 100644
> --- a/gtk/glib-compat.h
> +++ b/gtk/glib-compat.h
> @@ -1,5 +1,8 @@
>  /* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
>  /*
> +   Copyright (C) 2012-2014 Red Hat, Inc.
> +   Copyright © 1998-2009 VLC authors and VideoLAN
> +
>     This library is free software; you can redistribute it and/or
>     modify it under the terms of the GNU Lesser General Public
>     License as published by the Free Software Foundation; either
> @@ -18,6 +21,7 @@
>  
>  #include <glib-object.h>
>  #include <gio/gio.h>
> +#include "config.h"

If you add config.h here, it has to go as the very first include.

>  
>  #if !GLIB_CHECK_VERSION(2,26,0)
>  #define G_DEFINE_BOXED_TYPE(TypeName, type_name, copy_func, free_func) G_DEFINE_BOXED_TYPE_WITH_CODE (TypeName, type_name, copy_func, free_func, {})

> diff --git a/gtk/glib-compat.c b/gtk/glib-compat.c
> index 9ffadbb..5714173 100644
> --- a/gtk/glib-compat.c
> +++ b/gtk/glib-compat.c
> @@ -1,5 +1,8 @@
>  /* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
>  /*
> +   Copyright (C) 2012-2014 Red Hat, Inc.
> +   Copyright © 1998-2009 VLC authors and VideoLAN
> +
>     This library is free software; you can redistribute it and/or
>     modify it under the terms of the GNU Lesser General Public
>     License as published by the Free Software Foundation; either
> @@ -14,6 +17,7 @@
>     License along with this library; if not, see <http://www.gnu.org/licenses/>.
>  */
>  
> +#include <string.h>
>  #include "glib-compat.h"

and glib-compat.h needs to go before string.h here.

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20140220/e57d0ec5/attachment.pgp>


More information about the Spice-devel mailing list