From: Frank Mahler <nhchance@rrzn-user.uni-hannover.de>
Newsgroups: comp.parallel.mpi
Subject: Re: mpich, gcc-2.7.2.3, linux-2.0.35 uncompilable...
Date: Wed, 14 Oct 1998 11:21:30 +0200
Organization: see if I'm online: http://champ.tci.uni-hannover.de/
Message-Id: <36246D1A.1D33010B@rrzn-user.uni-hannover.de>
References: <361DF876.788A3B31@rrzn-user.uni-hannover.de>
    <6vvuiq$ua8$1@nnrp1.dejanews.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit


don_schad@my-dejanews.com wrote:
> 
> In article <361DF876.788A3B31@rrzn-user.uni-hannover.de>,
>   Frank Mahler <nhchance@rrzn-user.uni-hannover.de> wrote:
> > Hi *.mpi :-)
> >
> > I desperately tried to compile mpich-1.1.1 with gcc-2.7.2.3 on my
> > linux-2.0.35 box. At home I successfully completed using gcc-2.7.0 and
> > linux-2.1.115, but at work all went wrong:
> >
> > I did ./configure -f90nag ; make and all gets well, until it comes to
> > "make linktest":
> 
> I have succesfully compiled mpi w/ the 2.0.35/gcc-2.7.2.3 setup (at
> least the C part, I still can't get the nag f95 compiler to work).
> 
> Try doing the compilation with -L followed by directory where the
> mpi libraries are located (e.g. -L/home/mahler/tmp/mpich/lib[LINUX/ch_p4]).
> Also try mpicc -echo -c <filename.c> to see exactly what it is trying
> to link to.
> 
> If that doesn't work (or perhaps if it does) check for hard-wired
> paths in mpicc.  I seem to recall having to change one or two.
Thanks for your hints, at least it's working now!

BUT: I DID NOT CHANGE A THING...

What I did was deleting the config.status (or only the .log?) and rerun
./configure. Now it compiled and worked (at least the examples).
 
> ps - please let me know if you get the f90 to work.
You man f95?

Ok. As far as I understand it, configure finds out, how the FORTRAN
compiler generates the names for subroutines and functions and then sets
the preprocessor flags for mpich compilation to UNDERSCORE,
DOUBLEUNDERSCORE or something else...

Unfortunately this means, 1st: patching configure to have an option
-f95nag and try to see, if the automatic mechanism works for f95 as
well, 2nd: rerun configure and make an mpich that handles f95
correctly...

OR

use the ./configure -fortnames=DOUBLEUNDERSCORE option to force mpich to
use 2 underscores at the end of the mpi subroutines...

The disadvantage left is, that you'll need TWO versions of mpich, one
for f90 and one for f95... All you CAN do is decide once, which
(FORTRAN-) compiler you'll use in future and then create a correct mpich
installation. Unfortunately the other compiler won't do any mpi since
then...

HTH...
             ...Frank

