>
> How about the attached patch? It ensures that _POSIX_THREAD_SAFE_FUNCTIONS
> is defined if we declare *_r functions. This conforms POSIX better and you
> may simply detect those functions in the code using this macro. You said on
> IRC that all those changes are needed because VLC maintainer wants
> mingw-w64 to be POSIX compatible, would that make him happy?
>

Unfortunately No. localtime_r and gmtime_r are discovered with
AC_REPLACE_FUNCS in autotools
http://git.videolan.org/?p=vlc.git;a=blob;f=configure.ac;h=2704b28cfab8aa6e143a28e09b022dfdbcda10b2;hb=HEAD#l560

I submitted this patch but it was rejected because he said that localtime_r
and gmtime_r should not be inline as that breaks the spec so he won't
accept any kind of work around and that we should comply with the spec.
He said that is is bad enough that we have done this for asprintf and
vasprintf but they aren't part of the spec which is why he allows a
specific check for them. Essentially the only way to fix it is to use
functions.



On Fri, Jan 30, 2015 at 10:20 AM, Jacek Caban <ja...@codeweavers.com> wrote:

>  On 01/30/15 06:00, Martell Malone wrote:
>
>  Correct
>
> Seems like the patch works as I intended :)
>
>  I will do a patch to turn them back to functions without inline and
> hopefully this puts all the issues to rest :)
>
>
> This will bring back previous problems again. I don't see how using
> _POSIX_C_SOURCE would change it. Also, you still have an issue about
> time32_t vs time64_t.
>
> How about the attached patch? It ensures that _POSIX_THREAD_SAFE_FUNCTIONS
> is defined if we declare *_r functions. This conforms POSIX better and you
> may simply detect those functions in the code using this macro. You said on
> IRC that all those changes are needed because VLC maintainer wants
> mingw-w64 to be POSIX compatible, would that make him happy?
>
> Cheers,
> Jacek
>
>
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming. The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is
> your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more. Take a
> look and join the conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> Mingw-w64-public mailing list
> Mingw-w64-public@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
>
>

Attachment: 0009-Fix-localtime_r-and-gmtime_r-inline-issues.patch
Description: Binary data

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to