#40173: R build failure on OS X 10.8.4 building qdCocoa ---------------------+--------------------------- Reporter: one@… | Owner: kjell.konis@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: haspatch Port: R | ---------------------+--------------------------- Comment (by jeremyhu@…): Replying to [comment:14 kjell.konis@…]:
Replying to [comment:11 jeremyhu@…]:
You're setting the compiler to /usr/bin/gcc which may not exist. You should instead use the default compiler for objc and change the ones you want (per my post, which I referenced above).
You are using the c++ compiler from macports-gcc-XX which results in incompatibilities when trying to mix generated code with code built with the host's toolchains.
Hi Jeremy,
For your first point, I would rather be using `xcrun -find gcc` but I don't know how to get that to work in the Portfile so I hard coded it instead. This is something I am meaning to fix.
You can't assume that "gcc" even exists. You are going about this the wrong way by setting configure.compiler and then undoing the things you didn't want. You should just change what you want to change and leave configure.cc set to what it was before.
For your second point, R should not be using the host's toolchains. R keeps track of the tools used to build it and uses those to build its packages. Since R is fundamentally a computer algebra system, I think it is best if all parts of it get compiled by the same compiler family (I do make one exception for an Objective C file related only to Quartz graphics).
You can not mix C++ runtimes. If R uses any C++ API from another port or exposes any C++ API to other ports, it must be using a C++ compiler that uses the default C++ runtime.
Mixing gfortran with the Xcode C compiler du jour just seems like it's inviting something bad to happen.
Do you care to elaborate why you think that would be? Can you provide specific evidence of a problem? -- Ticket URL: <https://trac.macports.org/ticket/40173#comment:15> MacPorts <http://www.macports.org/> Ports system for OS X