Re: [AMBER] Problem build pmemd

From: Robert Duke <rduke.email.unc.edu>
Date: Fri, 13 Mar 2009 12:40:09 +0000

This is a simple matter of name mangling conventions between c and fortran,
and you have some combination of c and fortran compilers that are not
agreeing with each other. To figure out what you need to do, try the
following in the pmemd directory after the compilation has been done (been
linking has not succeeded):

nm pmemd.o | grep unlimit_stack
nm pmemd_clib.o | grep unlimit_stack

Look at the outputs - they probably differ. You need to get the c compiler
to be producing stuff from pmemd_clib.c that looks like what fortran is
expecting (which is what you see in pmemd.o, related to a call from fortran
to the c routine).

So at the top of the pmemd_clib.c source file there is a manifest constants
hack that handles this. Depending on which of the defined constants is
defined by CFLAGS in config.h, the names of the pmemd c library routines
will be mangled differently. The current choices for the defined constants
are CLINK_CAPS, NO_C_UNDERSCORE, DBL_C_UNDERSCORE, and nothing.
So do this in config.h by including the manifest constant in the config.h
file - for example, you might use:
CFLAGS = -DNO_C_UNDERSCORE

For some compilers it is possible to change the name mangling expected by
the fortran compiler by including a fortran compiler flag instead.
Determining this requires reading the compiler manuals. I don't have a clue
what compilers you have on this platform, but this covers all possible
avenues. Presuming that the mpi routines are linking properly, you want to
approach this problem by using the CFLAGS defined constant (if mpi is not
linking either, then you have to get fortran to recognize the mpi names or
recompile the mpi libraries in such a way that the exported mpi_* names are
recognized).

Regards - Bob Duke

----- Original Message -----
From: "Yiannis Georgiadis" <giannis.cc.uoa.gr>
To: "AMBER Mailing List" <amber.ambermd.org>
Sent: Friday, March 13, 2009 8:14 PM
Subject: [AMBER] Problem build pmemd


>
> Has anyone managed to build pmemd in hpux 11i platform ?
> I am using hpf90 and gcc and I am getting at linking :
>
> /usr/ccs/bin/ld : Unsatisfied symbols:
>
> get_wall_time
> unlimit_stack
>
> Yiannis Georgiadis
> UoA Computer Center Sys Admin
>
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber
>


_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Sun Mar 15 2009 - 01:08:38 PDT
Custom Search