This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libfortran/47945] REAL(8) output conversion error on MinGW32
- From: "burnus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 2 Mar 2011 17:04:01 +0000
- Subject: [Bug libfortran/47945] REAL(8) output conversion error on MinGW32
- Auto-submitted: auto-generated
- References: <bug-47945-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47945
--- Comment #11 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-03-02 17:03:47 UTC ---
(In reply to comment #9)
> It seems that MinGW has its own implementation of snprintf called
> __mingw_snprintf which can be activated by defining __USE_MINGW_ANSI_STDIO
In MinGW64, __USE_MINGW_ANSI_STDIO is set when _POSIX is specified. In MinGW
that does not seem to be the case and one needs to specify it either directly
or use another define such as _POSIX_SOURCE. Cf.
http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/mingw/include/_mingw.h?rev=1.61&cvsroot=src
>From libgfortran/libgfortran.h:
#if defined __MINGW32__
# define _POSIX 1
# define gfc_printf gnu_printf
#else