port PATH handling

Michael Sternberg sternberg at anl.gov
Mon Jan 29 10:24:54 PST 2007


Hello,

I'm testing to set a fortran dependency for port netCDF (this is a  
library which may be built with an optional fortran interface).  I  
have difficulty convincing port(1) to find the fortran compiler in  
$PATH.

Trying to use a commercial compiler (intel fortran), I source its  
dotfiles interactively (to augment $PATH etc.), then run:

	port -dk install netcdf +ifort

This fails because "configure" when run under port claims it cannot  
find the fortran compiler.  However, when I run the exact same  
command manually (as root), it succeeds (diff attached).

Does port(1) clean out $PATH ??


brahms:/opt/local root# port --version
MacPorts 1.400

[Really?  I pulled the svn src version for port and the dports tree  
because I cannot get rsync updates through a firewall.  Did I shoot  
myself in the foot?]


Regards, Michael

-------------- next part --------------
brahms:/opt/local root# diff /tmp/netcdf-port.log /tmp/netcdf-sh.log 
1c1,3
< DEBUG: Assembled command: 'cd "/opt/local/var/db/dports/build/_opt_local_src_macports-trunk_dports_science_netcdf/work/netcdf-3.6.0-p1/src" && FC=ifort FFLAGS="-O -mp -cm -w95" CPPFLAGS="-DNDEBUG -DpgiFortran" ./configure --prefix=/opt/local'
---
> brahms:/opt/local/var/db/dports/build/_opt_local_src_macports-trunk_dports_science_netcdf/work/netcdf-3.6.0-p1/src root# FC=ifort \
> >                         FFLAGS="-O -mp -cm -w95" \
> >                         CPPFLAGS="-DNDEBUG -DpgiFortran" ./configure --prefix=/opt/local
20c22
< checking whether ifort accepts -g... no
---
> checking whether ifort accepts -g... yes
22,28c24
< checking "ifort" as Fortran-90 compiler... failed to build test program
< checking for xlf90... no
< checking for f90... no
< checking for pgf90... no
< checking for g95... no
< configure: WARNING: "Could not find working Fortran-90 compiler"
< configure: WARNING: "The Fortran-90 interface will not be built"
---
> checking "ifort" as Fortran-90 compiler... works
53,54c49,52
< checking which ifort... no ifort in /opt/local/bin /opt/local/sbin /bin /sbin /usr/bin /usr/sbin /usr/X11R6/bin
< checking F90... unset
---
> checking which ifort... /opt/intel/fc/9.1.035/bin/ifort
> checking F90... ifort
> checking F90FLAGS... -O -mp -cm -w95
> checking which ifort... /opt/intel/fc/9.1.035/bin/ifort
66,67c64
< checking user-defined Fortran-77 compiler "ifort"... failed to compile test program
< configure: WARNING: "The Fortran-77 interface will not be built"
---
> checking user-defined Fortran-77 compiler "ifort"... works
69c66,81
< checking for Fortran preprocessor... cc -E
---
> checking if Fortran-77 compiler handles *.F files... yes
> checking for C-equivalent to Fortran routine "SUB"... sub_
> checking for Fortran "byte"... yes
> checking for Fortran "integer*2"... yes
> checking if Fortran "byte" is C "signed char"... yes
> checking if Fortran "byte" is C "short"... no
> checking if Fortran "byte" is C "int"... no
> checking if Fortran "byte" is C "long"... no
> checking if Fortran "integer*2" is C "short"... yes
> checking if Fortran "integer*2" is C "int"... no
> checking if Fortran "integer*2" is C "long"... no
> checking if Fortran "integer" is C "int"... yes
> checking if Fortran "real" is C "float"... yes
> checking if Fortran "doubleprecision" is C "double"... yes
> checking for Fortran-equivalent to netCDF "byte"... byte
> checking for Fortran-equivalent to netCDF "short"... integer*2
120d131
< --->  Building netcdf with target all


More information about the macports-users mailing list