using a different compiler with macports
I'm trying to find the config file in macports to change the CC and CXX default parameters that configure uses when it is run on each package. Can someone help me with this. thx, wj
Wes James wrote:
I'm trying to find the config file in macports to change the CC and CXX default parameters that configure uses when it is run on each package. Can someone help me with this.
Not that easily possible, it is absolutely centered on using gcc. But there is the port gcc_select which allows you to maintain certain symlinks for gcc, g++, etc. Additionally, each port is free to choose another compiler subset (because it might require it). What exactly are you trying to do? Rainer
On Thu, Feb 21, 2008 at 7:29 PM, Rainer Müller <raimue@macports.org> wrote:
Wes James wrote:
I'm trying to find the config file in macports to change the CC and CXX default parameters that configure uses when it is run on each package. Can someone help me with this.
Not that easily possible, it is absolutely centered on using gcc. But there is the port gcc_select which allows you to maintain certain symlinks for gcc, g++, etc. Additionally, each port is free to choose another compiler subset (because it might require it).
What exactly are you trying to do?
Rainer
I have a professor that is using the pgi compiler (http://www.pgroup.com/) and i was trying to find a way to set CC=pgcc and CXX=pgcpp and maybe some other things for macport to use for compiling as defaults. thx
On Feb 22, 2008, at 00:30, Wes James wrote:
On Thu, Feb 21, 2008 at 7:29 PM, Rainer Müller wrote:
Wes James wrote:
I'm trying to find the config file in macports to change the CC and CXX default parameters that configure uses when it is run on each package. Can someone help me with this.
Not that easily possible, it is absolutely centered on using gcc. But there is the port gcc_select which allows you to maintain certain symlinks for gcc, g++, etc. Additionally, each port is free to choose another compiler subset (because it might require it).
What exactly are you trying to do?
Rainer
I have a professor that is using the pgi compiler (http://www.pgroup.com/) and i was trying to find a way to set CC=pgcc and CXX=pgcpp and maybe some other things for macport to use for compiling as defaults.
MacPorts doesn't support that. Maintainers have enough to do already without needing to deal with users potentially using a different compiler than they did. Ports are written to compile with the system's gcc by default, or the port can define a different compiler to use if necessary. You could write specific ports that make use of pgi, if that's necessary. I don't see a port for pgi itself, so you could start by making a port for pgi if you want.
Wes James wrote:
On Thu, Feb 21, 2008 at 7:29 PM, Rainer Müller <raimue@macports.org> wrote:
Wes James wrote:
I'm trying to find the config file in macports to change the CC and CXX default parameters that configure uses when it is run on each package. Can someone help me with this.
Not that easily possible, it is absolutely centered on using gcc. But there is the port gcc_select which allows you to maintain certain symlinks for gcc, g++, etc. Additionally, each port is free to choose another compiler subset (because it might require it).
What exactly are you trying to do?
Rainer
I have a professor that is using the pgi compiler (http://www.pgroup.com/) and i was trying to find a way to set CC=pgcc and CXX=pgcpp and maybe some other things for macport to use for compiling as defaults.
You can't change the defaults (no configuration, as they're hardcoded) but you can set the values CC and CXX passed to configure at runtime: port build configure.cc=pgcc configure.cxx=pgcpp If used a lot, a new "configure.compiler=pgi" option could be added to the current list of presets (such as "gcc-4.0" and "macports-gcc-4.2") ? Then again, there is no default configuration for that either... So it would just mean having to set one variable instead of two. --anders PS. For us non-academics, the price tag looks a bit steep. But it (and the Intel compilers) could be added anyway. port build configure.cc=icc configure.cxx=icpc
Ryan Schmidt wrote:
You could write specific ports that make use of pgi, if that's necessary. I don't see a port for pgi itself, so you could start by making a port for pgi if you want.
As I can see this compiler is a commercial product and it's source code is not available. Rainer
participants (4)
-
Anders F Björklund
-
Rainer Müller
-
Ryan Schmidt
-
Wes James