Skip to content
Prev 7875 / 15075 Next

Here's what Steve said

On Mar 21, 2011, at 9:19 AM, Prof Brian Ripley wrote:

            
I'm more worried about the things they break ;). Fink and MacPorts software does not inter-operate well with anything outside and the quality of the ports is dubious (and new OS support lags quite a bit).

But this is mostly irrelevant to the compilers - we have had a setup to use GNU build of gfortran before (including the use of Apple's drivers to support Apple-style flags like -arch). The real issue is the mess with run-rime libraries, for example. We can't use static libraries because we load multiple shared objects into one binary, so the implication is that there will be different dylib versions around (system, GNU compiler etc.) - causing potential trouble.
Quartz Cocoa back-end in R is objective C, but that should still be inter-operable. R.app can be compiled with clang and linked to R regardless of the way R was compiled.
This is just a matter of the compiler driver by Apple which selects the proper compiler/cross-compiler, adds -m32 or -m64 and uses lipo to create the final result. We can use that driver even with GNU gcc.
The situation is not unlike on Windows -- so far we were able to re-use the canonical tools for the OS, but that may not longer be possible. Maintaining tools outside of the canonical OS tools is always possible, but increases the risk of incompatibilities. This is especially true for external parts (libraries) that we do not supply - they are currently built with Apple's tools so it's fairly safe to use them. If we have to switch to a different toolset, it may lead to issues.

The bottom line is that there are options, we just can't rely on the canonical OS tools anymore. Before Apple's gcc 4.2 branch we did not have native (Xcode) Fortran and there were constantly some issues. Then gcc 4.2 came along and we had a fairly smooth sailing so far. So it just means more work for me, that's all ;).

Cheers,
Simon

BTW: GNU doesn't make things easier, either. Most rect GCCs rely on very weird dependencies that are not exactly written in a portable way and a pain to compile...