Re: [f2py] What's the preferred way to select a compiler
Pearu Peterson <[email protected]> Tue, 21 Jun 2011 21:01:32 +0300
| Newsgroups | gmane.comp.python.f2py.user |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Jun 21, 2011 at 4:02 PM, Marcel Loose <loose-JEfgvD5ZcVNmR6Xm/[email protected]> wrote: > Hi all, > > I'm a bit puzzled as to what is the proper way to select a compiler. I > noticed that you can either select a compiler by vendor, using the > --fcompiler option; or by specifying the full path to f77 and/or f90, > using --f77exec and/or --f90exec. > > The simplest way is to select a compiler by vendor since in most cases the defaults should just work. The --f77exec and --f90exec options are useful when either testing f2py with different compiler versions of the same vendor or when compilers are installed to non-standard locations. > Related questions: > * If I specify --f77exec and/or --f90exec, will these compilers > then take precedence? > They will override the corresponding paths in default --fcompiler key. So, if the default is gnu95, and you specify, say, --f90exec=/path/to/intel/f90, then you'll get problems. > * And what's the precedence between f77 and f90? > When talking about gnu compilers then in recent numpy f90, that is --fcompiler=gnu95, is default. In older numpy g77 (equivalent to --fcompiler=gnu) was the default. * Do I always need to specify full paths to both f77 and f90. > No, when numpy.distutils is able to find them from PATH. While implementing support for various Fortran compilers, I have always specified the compiler by vendor. This means that the compilers are assumed to be installed and the compiler environment variables are set according to the instructions of compiler vendors. People often skip the last requirement and then they will need to set the full paths to f77 or f90. HTH, Pearu _______________________________________________ f2py-users mailing list f2py-users-Y4l6ocDipWCuvFJfX82//[email protected] http://cens.ioc.ee/mailman/listinfo/f2py-users