Opened 11 years ago
Closed 11 years ago
#40173 closed defect (fixed)
R build failure on OS X 10.8.4 building qdCocoa
Reported by: | one@… | Owned by: | kjellpk (Kjell Konis) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.2.0 |
Keywords: | haspatch | Cc: | watsodw, jeremyhu (Jeremy Huddleston Sequoia), stromnov (Andrey Stromnov) |
Port: | R |
Description
Clean install of R port fails
Attachments (2)
Change History (19)
Changed 11 years ago by one@…
comment:1 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
Owner: | changed from macports-tickets@… to kjell.konis@… |
---|
comment:2 Changed 11 years ago by kjellpk (Kjell Konis)
Configure is not choosing the specified OBJC compiler. Should be /usr/bin/gcc (set in the Portfile) because that is the only one that works. Not sure why this is happening because it doesn't happen for me.
:info:configure R is now configured for x86_64-apple-darwin12.4.0 :info:configure :info:configure Source directory: . :info:configure Installation directory: /opt/local/Library/Frameworks :info:configure :info:configure C compiler: /opt/local/bin/gcc-mp-4.7 -std=gnu99 -pipe -Os -DOS_OBJECT_USE_OBJC=0 -m64 :info:configure Fortran 77 compiler: /opt/local/bin/gfortran-mp-4.7 -pipe -Os -m64 :info:configure :info:configure C++ compiler: /opt/local/bin/g++-mp-4.7 -pipe -Os -m64 :info:configure Fortran 90/95 compiler: /opt/local/bin/gfortran-mp-4.7 -pipe -Os -m64 :info:configure Obj-C compiler: /opt/local/bin/gcc-mp-4.7 -pipe -Os -m64 -fobjc-exceptions :info:configure :info:configure Interfaces supported: X11, aqua :info:configure External libraries: readline, BLAS(vecLib), ICU, lzma :info:configure Additional capabilities: PNG, JPEG, TIFF, NLS, cairo :info:configure Options enabled: framework, shared BLAS, R profiling :info:configure :info:configure Recommended packages: yes :info:configure
Changed 11 years ago by kjellpk (Kjell Konis)
Attachment: | Portfile.diff added |
---|
comment:3 Changed 11 years ago by kjellpk (Kjell Konis)
Oops! My bad, someone (not me - yay) revised the R port and removed the OBJC compiler. The attached patch puts everything back the way it should be.
comment:4 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | david.w.watson@… jeremyhu@… added |
---|---|
Keywords: | haspatch added |
comment:5 follow-up: 7 Changed 11 years ago by kjellpk (Kjell Konis)
Any pointers on where that central place is? The only way I can figure out to force configure.objc to come after configure.compiler is to put them in the same block.
comment:6 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Ugg, sorry about that. Drive by from getting it to build on Mavericks. Sorry for the regression.
Please see my email to macports-dev (yesterday I believe) on this very subject!
comment:7 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Replying to kjell.konis@…:
Any pointers on where that central place is? The only way I can figure out to force configure.objc to come after configure.compiler is to put them in the same block.
https://lists.macosforge.org/pipermail/macports-dev/2013-August/023908.html
comment:8 Changed 11 years ago by kjellpk (Kjell Konis)
In the short term, could someone either commit my patch or back out r109194 to get the R port working again?
comment:9 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
It will still be broken after backing out r109194. It may build for you, but it'll still be broken.
comment:10 Changed 11 years ago by kjellpk (Kjell Konis)
Guess I'm confused, what do you mean by broken?
comment:11 follow-up: 14 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
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.
comment:12 Changed 11 years ago by buchere@…
Hi Kjell, Jeremy, Ryan and Friends,
Changing "/opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports/math/R/Portfile",
by adding 3 times "configure.objc /usr/bin/gcc",
as described in "Portfile.diff" in "comment:2",
seems to work fine for me. At least R compiled.
Thanx a bunch!
I do not understand comment:11 "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." What are the host's tool chains? Which code would be built with them?
Elmar
comment:14 follow-up: 15 Changed 11 years ago by kjellpk (Kjell Konis)
Replying to 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.
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). Mixing gfortran with the Xcode C compiler du jour just seems like it's inviting something bad to happen.
Kjell
comment:15 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Replying to kjell.konis@…:
Replying to 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?
comment:16 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
r110215 should take care of this.
comment:17 Changed 11 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Resolution: | → fixed |
---|---|
Status: | new → closed |
log