[Cogl] [PATCH 6/8] config: Don't read a config file at startup when using --disable-glib

Robert Bragg robert at sixbynine.org
Tue Sep 18 07:41:56 PDT 2012


I think this is fine for now, though it doesn't seem quite right that
we disable this arbitrary feature when --disable-glib is passed. Maybe
later we could add a separate option to disable reading a cogl.conf
and that would have a knock on affect of not building GKeyFile + the
corresponding encoding support when building without glib.

Reviewed-by: Robert Bragg <robert at linux.intel.com>

regards,
- Robert

On Mon, Sep 17, 2012 at 8:08 PM, Damien Lespiau
<damien.lespiau at gmail.com> wrote:
> From: Damien Lespiau <damien.lespiau at intel.com>
>
> GKeyFile is a bit too much to import in a standalone build for my taste
> as it depends on the encoding part of glib.
> ---
>  cogl/cogl-config.c |   12 ++++++++++++
>  1 files changed, 12 insertions(+), 0 deletions(-)
>
> diff --git a/cogl/cogl-config.c b/cogl/cogl-config.c
> index a000dd9..5731783 100644
> --- a/cogl/cogl-config.c
> +++ b/cogl/cogl-config.c
> @@ -38,6 +38,16 @@ char *_cogl_config_renderer;
>  char *_cogl_config_disable_gl_extensions;
>  char *_cogl_config_override_gl_version;
>
> +#ifndef COGL_HAS_GLIB_SUPPORT
> +
> +void
> +_cogl_config_read (void)
> +{
> +
> +}
> +
> +#else /* COGL_HAS_GLIB_SUPPORT */
> +
>  /* Array of config options that just set a global string */
>  static const struct
>  {
> @@ -127,3 +137,5 @@ _cogl_config_read (void)
>
>    g_key_file_free (key_file);
>  }
> +
> +#endif /* COGL_HAS_GLIB_SUPPORT */
> --
> 1.7.7.5
>
> _______________________________________________
> Cogl mailing list
> Cogl at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/cogl


More information about the Cogl mailing list