libftdi Archives

Subject: Re: libftdi 1.1 release candidate (rc1)

From: Xiaofan Chen <xiaofanc@xxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Wed, 29 Jan 2014 20:33:29 +0800
On Wed, Jan 29, 2014 at 5:28 PM, Anders Larsen <al@xxxxxxxxxxx> wrote:
> On 2014-01-29 03:36, Xiaofan Chen wrote:
>>
>> Adding -std=c99 and -D__USE_MINGW_ANSI_STDIO does not really help.
>> But I think I understand the problem now. MinGW and MinGW-w64 use
>> Microsoft's C runtime which seems to have problems.
>>
>> So I think probably we can ignore the warnings for the 1.1 release.
>
>
> it likely means that the examples will not work as-is on Windows due
> to the format strings being misinterpreted there.
>
> I guess that's not such a big deal, but perhaps it should at least
> be documented somewhere?

You can see from the build logs that using the more and more popular
MinGW-w64 official tool chain, there is only one warning for the examples
build. I hear that MinGW-w64 has better C99 compliance than MinGW.org.
MinGW-w64 offers both 32 and 64bit toolchain and it seems to me most
of the Linux distros now switch to MinGW-w64. Therefore I guess this
is less an issue now.

As far as the examples, they do seem to run fine under Windows but
I have not really tested all of them (I may not have the right hardware).

Scanning dependencies of target bitbang
[ 46%] Building C object examples/CMakeFiles/bitbang.dir/bitbang.c.obj
C:\work\libftdi\libftdi1-1.1\examples\bitbang.c: In function 'main':
C:\work\libftdi\libftdi1-1.1\examples\bitbang.c:64:9: warning: unknown conversio
n type character 'h' in format [-Wformat=]
         printf("%02hhx ",buf[0]);
         ^
C:\work\libftdi\libftdi1-1.1\examples\bitbang.c:64:9: warning: too many argument
s for format [-Wformat-extra-args]
Linking C executable bitbang.exe
[ 46%] Built target bitbang

-- 
Xiaofan

--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx   

Current Thread