[FFmpeg-devel] [PATCH] Use _snprintf for mingw build
Ramiro Ribeiro Polla
Mon Oct 15 15:48:27 CEST 2007
Zuxy Meng wrote:
> 2007/10/15, Fred Rothganger <fred at rothganger.org>:
>> Zuxy Meng wrote:
>>> I don't think MSVC is a supported platform.
>> True. In fact, one exposes himself to censure by even daring to use it. :)
>> However, I'm not trying to compile FFmpeg under MSVC, but merely to link
>> to mingw binaries.
>>> Furthermore MS's _snprintf
>>> isn't the same as snprintf: the result of the former isn't guaranteed
>>> to be zero terminated.
>>> Actually MinGW runtime has provided a sane snprintf.
>> Are you suggesting there is a way to link in a better snprintf() when
>> building a executable image using MSVC? If so, please advise on the
>> procedure. Would this consist of linking one of the libmsvcr*.a files
>> from the mingw directory and completely suppressing any automatic
>> linkage of the MSVC runtime?
> You can either:
> 1. Convert libmingwex.a to a .lib and link it to your program.
No need. MSVC understands gcc generated .a files (and .o too).
Fred, there are no known issues on using FFmpeg's libs with MSVC if you
follow this wiki  correctly. If you encounter any problems with it,
please discuss on the forum hosted on the same site.
More information about the ffmpeg-devel