This one is addressing the remaining warning issues when using %lld or %zu
with MinGW.

The purpose of this patch it to remove warnings when the
-D__USE_MINGW_ANSI_STDIO flag is used in MinGW. This flag is intended to
make MinGW more C99 compliant with regards to printfs, and should become the
recommended way of compiling OpenOCD on MinGW platforms.

Unlike what I thought earlier, I wasn't able to remove the need to patch
helper/log.h and helper/command.h, so the change of "__attribute__ ((format
(printf, x, y)))" to "__attribute__ ((format (gnu_printf, x, y)))" is part
of the patch.

The only other file that needs modification is /target/arm11.h as, with
__USE_MINGW_ANSI_STDIO enabled, "%zu" becomes a valid modifier for size_t
printout and should be used to prevent warnings on 64bit platforms.

A couple of separate patches will follow for the 2 remaining Win64 issues.

Regards

Attachment: patch_mingw_ansi_stdio.diff
Description: Binary data

_______________________________________________
Openocd-development mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to