diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-09-24 05:04:24 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-09-24 05:04:24 +0200 |
commit | 170e2fd7c39c430b334ea80a1e4dfb10c6fd1e95 (patch) | |
tree | adf6e223244f404fc365d5eb7d470383b4947c6a /configure | |
parent | 3bc036171f2e14a8e51d7f3498b2af25a0016093 (diff) | |
download | ffmpeg-170e2fd7c39c430b334ea80a1e4dfb10c6fd1e95.tar.gz |
configure: Check if "-D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600" is needed for localtime_r()
Fixes build with musl
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -4234,6 +4234,15 @@ probe_libc(){ eval ${pfx}libc_type=solaris add_${pfx}cppflags -D__EXTENSIONS__ -D_XOPEN_SOURCE=600 fi + check_${pfx}cc <<EOF +#include <time.h> +void *v = localtime_r; +EOF +test "$?" != 0 && check_${pfx}cc -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 <<EOF && add_${pfx}cppflags -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 +#include <time.h> +void *v = localtime_r; +EOF + } probe_libc |