Hi all,
I’m trying to make MM5 works on my PC with Debian distro.
It would be nice if someone could give me some hint about this error I got when running PREGRID after a succesful compilation:
Situation:
-I execute the pregrid.csh script that starts ‘pregrid_on84.exe’
-‘pregrid_on84.exe’ make a call to ‘rd_on84()’ fortran routine.
-From there, a call is made to ‘ron84_record()’ fortran routine.
-From there, a last call is made to COPEN() which resides in a C code.
Erroneous result:
-The name of file to be opened arrives bad to COPEN().
-There are many garbage chars appended to real file name.
Original file name (sent by fortran code): ON84FILE
File name when arrives cio.c: “ON84FILE ÐUnknown nk: NULLrd_on84.fNot using field number PRESSUREPSFC`ê”
I compile the codes as following (default package settings):
================================
compile cio.c:
cc -DDEC -DBIT32 -I. -c cio.c
create library:
ar ru ./libpgu.a [...several objects...] cio.o
Compile codes:
/lib/cpp -I. -c -P -DDEC -DBIT32 -traditional ron84_record.F > ron84_record.f
pgf90 -c Mfreeform -byteswapio -I. ron84_record.f
/lib/cpp -I. -c -P -DDEC -DBIT32 -traditional rd_on84.F > rd_on84.f
pgf90 -c Mfreeform -byteswapio -I. rd_on84.f
Link and creation of executable:
pgf90 -o pregrid_on84.exe rd_on84.o ron_record.o libpgu.a
=========================================
I guess it must be someting dealing with null termination of strings and the way it differs between fortran and C
Thanks for your suggestions
Jean