On Fri, Jun 5, 2015 at 3:24 PM, Luca Barbato <[email protected]> wrote: > The C runtime C99 compatibility had been improved a lot and it now > rejects some of the compatibility defines provided for the older > versions. > > Bug-Id: 864 > CC: [email protected] > --- > > Thanks to Hugo, Thomas and Rob for getting me the crtversion.h when I asked > it. > > configure | 16 +++++++++------- > 1 file changed, 9 insertions(+), 7 deletions(-) > > diff --git a/configure b/configure > index 18f0518..9013972 100755 > --- a/configure > +++ b/configure > @@ -3021,9 +3021,6 @@ probe_cc(){ > _ld_path='-libpath:' > _flags='-nologo' > _cflags='-D_USE_MATH_DEFINES -D_CRT_SECURE_NO_WARNINGS > -Dinline=__inline -FIstdlib.h -Dstrtoll=_strtoi64' > - if [ $pfx = hostcc ]; then > - append _cflags -Dsnprintf=_snprintf > - fi > elif $_cc 2>&1 | grep -q Intel; then > _type=icl > _ident=$($_cc 2>&1 | head -n1) > @@ -3047,9 +3044,6 @@ probe_cc(){ > # -Qvec- -Qsimd- to prevent miscompilation, -GS for consistency > # with MSVC which enables it by default. > _cflags='-D_USE_MATH_DEFINES -FIstdlib.h -Dstrtoll=_strtoi64 -Qms0 > -Qvec- -Qsimd- -GS' > - if [ $pfx = hostcc ]; then > - append _cflags -Dsnprintf=_snprintf > - fi > elif $_cc --version 2>/dev/null | grep -q ^cparser; then > _type=cparser > _ident=$($_cc --version | head -n1) > @@ -3742,7 +3736,15 @@ probe_libc(){ > eval test \$${pfx_no_}cc_type = "gcc" && > add_${pfx}cppflags -D__printf__=__gnu_printf__ > elif check_${pfx}cpp_condition crtversion.h "defined > _VC_CRT_MAJOR_VERSION"; then > - eval ${pfx}libc_type=msvcrt > + if check_${pfx}cpp_condition crtversion.h "_VC_CRT_MAJOR_VERSION >= > 14"; then > + eval ${pfx}libc_type=msvcrt_c99 > + else > + eval ${pfx}libc_type=msvcrt > + > + if [ $pfx = host_ ]; then > + add_host_cppflags -Dsnprintf=_snprintf > + fi > + fi > # The MSVC 2010 headers (Win 7.0 SDK) set _WIN32_WINNT to > # 0x601 by default unless something else is set by the user. > # This can easily lead to us detecting functions only present
avutil/internal.h uses HAVE_LIBC_MSVCRT, which this would break. Personally, I would prefer just acting based on the version in the msvcrt libc handling code later in the file, instead of changing the type define. - Hendrik _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
