Hi,

Apologies for breaking the threading on this, I've only just signed up to
the list and the last email was from September 2015.

I've started to look into building R for Windows using MSYS2 as both the
build environment and tools + libraries provider (where possible). I've
managed to get the testsuite to pass on a recent MSYS2 MinGW-w64 x86-64 GCC:
gcc.exe (Rev1, Built by MSYS2 project) 5.3.1 20160228

I've attached two patches that I needed, described below. I hope this is
the appropriate place and way to suggest patches. Comments for improvements
are very welcome.

0005-Win32-Extend-sqrt-NA_real_-hack-to-all-GCC-versions.patch
Removes the __GNUC__ <= 4 for Windows ISNAN R_sqrt hack and doesn't replace
it with any version check since I don't see any reason to second-guess when
it might be fixed. When it is fixed in MinGW-w64 we can just remove the
hack and be happy (I would hope to be able to get round to this in the next
few months).

0006-Win32-GCC-5.3-Fix-ISNAN-int-emits-UD2-insn.patch
The reason that boxplot.stats() was crashing was because when isnan() is
called with an int it emits a UD2 instruction to force a crash, so let us
just cast the input value to a double to prevent that. The code for this
can be seen here:
https://github.com/Alexpux/mingw-w64/blob/master/mingw-w64-headers/crt/math.h#L612-L622

--

Best regards,

Ray Donnelly,

Continuum Analytics Inc.
______________________________________________
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to