AMBER Archive (2006)

Subject: Re: AMBER: building AMBER9 with gfortran/cygwin

From: Andreas Svrcek-Seiler (svrci_at_tbi.univie.ac.at)
Date: Fri Aug 25 2006 - 05:39:08 CDT


Hi,
> I am trying to build AMBER9 on CYGWIN with gcc 4.1.1, most modules can be
> compiled successfully, however, it failed at compiling sander:
>
> character(len=len(MVPM_FORWARD)) ::
> matrix_vector_product_method=MVPM_FORWARD
> 1
> Error: 'matrix_vector_product_method' at (1) must have constant character
> length in this context
> In file _lmod.f:262
>
> character(len=len(MC_METHOD_QUICK_QUENCH)) :: Monte_Carlo_method &
> 1
> Error: 'monte_carlo_method' at (1) must have constant character length in
> this context
> In file _lmod.f:325
>
> character(len=len(XMIN_METHOD_LBFGS)) :: xmin_method = XMIN_METHOD_LBFGS
                                                     1
> Error: 'xmin_method' at (1) must have constant character length in this

Here's a workaround:

182c182
< character(len=*) :: matrix_vector_product_method=MVPM_FORWARD

---
>    character(len=len(MVPM_FORWARD)) :: 
matrix_vector_product_method=MVPM_FORWARD
194c194
<    character(len=*) :: Monte_Carlo_method &
---
>    character(len=len(MC_METHOD_QUICK_QUENCH)) :: Monte_Carlo_method &
257c257
<    character(len=*) :: xmin_method = XMIN_METHOD_LBFGS
---
>    character(len=len(XMIN_METHOD_LBFGS)) :: xmin_method = XMIN_METHOD_LBFGS

...just change lines from the diff above in lmod.f - then compilation runs through (at least here). Note that 1) I'm not sure the lmod routines work after applying this patch. 2) This seems to be a workaround for a compiler-bug (not sure- my F90 knowledge is quite limited). 3) make test.sander runs through except for the noesy test, which terminates with:

Namelist reports error in reading noeexp -- Subscript out of range implies dimensioning problem -- (see nmr.h)

...which seems unrelated to the patch above

4) (related to point 2): ifort doesn't compile lmod.f after applying this patch.

I hope this helps, good luck Andreas

----------------------------------------------------------------------- The AMBER Mail Reflector To post, send mail to amber_at_scripps.edu To unsubscribe, send "unsubscribe amber" to majordomo_at_scripps.edu