[mpich-discuss] Compiling shared libraries with Fortran 77 compiler and unexpected option

Dave Goodell goodell at mcs.anl.gov
Tue Sep 6 09:36:44 CDT 2011


Hi Thomas,

I took a look at the patch and it seems reasonable.  F77_SHL should probably be made "precious" with AC_ARG_VAR since it is now an input/output variable instead of strictly an output variable.  Also, should "-PIC" be added to the list of options to try so that MPICH2 would guess the right argument automatically for nagfor?

However we are currently in the process of switching to using libtool to build our shared libraries, which entirely eliminates the code passage that you have modified.  So unless our plans change substantially for some reason I think we will not incorporate this patch into MPICH2 right now.  We will certainly refer anyone who has trouble building 1.4.1 and earlier to your patch.

Thanks,
-Dave

On Sep 6, 2011, at 5:08 AM CDT, Thomas Jahns wrote:

> Hello,
> 
> I'm using
> - NAG Fortran 5.2.747 (nagfor) for F77/F90 sources with
> - gcc 4.6 for C and as "driver" for nagfor and
> - g++ 4.6
> 
> on Debian squeeze. And tried to build mpich2 1.4.1
> 
> Unfortunately the configure-script of mpich2 has its own idea of what F77_SHL
> should look like and produces a configuration that fails to produce a shared
> libmpich, libmpichf90 amdn libfmpich. I therefore made a patch to the top-level
> configure to accept a user-provided argument like
> 
> ./configure F77=nagfor F77_SHL="nagfor -PIC"
> 
> in preference to trying out several pre-configured alternatives as is the case
> now. With this patch one can set the PIC-F77-compiler.
> 
> Please notify me if the attached patch[1] is or is not acceptable to mpich2.
> 
> Ciao, Thomas
> 
> 1: apply with patch -p1 <mpich2-1.4.1-f77_shl.patch when in the top-level source
> directory
> -- 
> Thomas Jahns
> DKRZ GmbH, Department: Application software
> 
> Deutsches Klimarechenzentrum
> Bundesstraße 45a
> D-20146 Hamburg
> 
> Phone: +49-40-460094-151
> Fax: +49-40-460094-270
> Email: Thomas Jahns <jahns at dkrz.de>
> <mpich2-1.4.1-f77_shl.patch>_______________________________________________
> mpich-discuss mailing list
> mpich-discuss at mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss



More information about the mpich-discuss mailing list