[vlc-devel] [PATCH] build: create a macro to check for, and replace, possibly-inline functions.

Diego Elio Pettenò flameeyes at flameeyes.eu
Tue Mar 10 13:31:02 CET 2015


On 10 March 2015 at 12:17, Rémi Denis-Courmont <remi at remlab.net> wrote:
>>
>> +VLC_REPLACE_FUNC_INLINE([gmtime_r], [
>> +    #define _POSIX_C_SOURCE 200809L
>
>
> Forcing a build environment only for a test is not a good idea IMNSHO.

That's just a requirement of the gmtime_r feature test macros. It does
check that the function exists in the expected build environment.

> AC_CHECK_DECL(S) and AC_LIBOBJ would be much simpler. We already do that for nanosleep().

It would be simpler, I disagree with it being any better. As I said on
IRC I had more trouble than it's worth with AC_CHECK_DECL and I'd
rather not touch it with a ten feet pole.

> Revectoring the v/asprintf checks is a good idea (though personally I would have left the original AC_REPLACE_FUNCS), but belongs in a separate patch. Also same comments as above.

I have no particular care whether this is in the same or separate; I
do not understand what you mean with "[you] would have left the
original AC_REPLACE_FUNCS" — if you mean that you would have not moved
(v)asprintf to separate tests, well that's not what we want to discuss
here, right?



More information about the vlc-devel mailing list