Skip to content
Prev 35974 / 63424 Next

patch about compile R with clang

configure is a generated file, and so should not be edited directly. 
You have not told us what version of R these patches were against, but 
it looks to me as if wchar.h is included already in current R 
(R-patched/R-devel) -- certainly in the second case before wctype.h.
(It really should not be needed according to POSIX, but it was on 
MinGW-w64.   Also, headers are an issue not just for a compiler but an 
OS, and you have not told use that either.)

So can you please clarify what version of R, what OS, and what changes 
you think might be needed to m4/R.m4 in the R-devel version of R?
On Mon, 22 Feb 2010, Gong Yu wrote:

            
Hmm, it claims to be 'faster and better', but past reports on Mac OS X 
(it ships with Snow Leopard) suggested those claims to be exaggerated.
(It did not create as fast an R, although it compiled faster, and its 
error messages were markedly worse than other compilers despite claims 
to the contrary.)
Please use C comments not C++ ones: we prefer but do not require C99.

At least on my version of Linux (Fedora 12), these optimizations are 
only supposed to be used with 'GNU CC', and are inside a test for 
__GNUC__ >= 2.  So if clang is using them, this is a bug in clang (we 
have seem similar things with the Intel CC masquerading as GCC). 
Your OS may differ, of course.