[Cogl] [PATCH] Fix generating the unit test wrappers when building with MingW32

Robert Bragg robert at sixbynine.org
Mon Sep 2 10:01:26 PDT 2013


This looks good to land to me:

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

thanks,
Robert

On Mon, Sep 2, 2013 at 6:00 PM, Neil Roberts <neil at linux.intel.com> wrote:
> For some reason the unit test symbols end up in the read-only data
> section when building on windows rather than the initialised data
> section so they have a different letter in the list generated by nm.
> They also begin with an underscore because windows likes to add
> underscores to symbols for some reason. This patch changes the regular
> expressions in the code to generate the wrapper list so that it
> accepts either way.
> ---
>  tests/unit/Makefile.am | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am
> index d75cd0e..9502472 100644
> --- a/tests/unit/Makefile.am
> +++ b/tests/unit/Makefile.am
> @@ -21,7 +21,7 @@ stamp-test-unit: Makefile test-unit$(EXEEXT)
>         @mkdir -p wrappers
>         source $(top_builddir)/cogl/libcogl2.la ; \
>           $(NM) $(top_builddir)/cogl/.libs/"$$dlname"| \
> -         grep 'D unit_test_'|sed 's/.\+ D //' > unit-tests
> +         grep '[DR] _\?unit_test_'|sed 's/.\+ [DR] _\?//' > unit-tests
>         @chmod +x $(top_srcdir)/tests/test-launcher.sh
>         @( echo "/stamp-test-unit" ; \
>            echo "/test-unit$(EXEEXT)" ; \
> --
> 1.8.3.1
>
> _______________________________________________
> Cogl mailing list
> Cogl at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/cogl


More information about the Cogl mailing list