Compiling ROMS on SUNOS

Discussion on computers, ROMS installation and compiling

Moderators: arango, robertson

Post Reply
Message
Author
elhunter
Posts: 9
Joined: Mon Dec 11, 2006 6:13 pm
Location: IMCS

Compiling ROMS on SUNOS

#1 Post by elhunter » Mon Dec 11, 2006 9:59 pm

Hello,

This is my first attempt at compiling ROMS and I am having a difficulty.Hopefully I am not doing anything all that silly.

Here are some relevant versions.
squall{58}% uname -a
SunOS squall 5.8 Generic_108528-22 sun4u sparc SUNW,UltraAX-i2
squall{61}% make -v
GNU Make 3.80
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
squall{18}% f95 -V
f95: Sun Fortran 95 8.2 2005/10/13


It seems to do OK unitl I get to:

/usr/lib/cpp -P -DSUN -I/usr/local/include -DSUNOS -DSUN4U -DF95 -IROMS/Include -IROMS/Adjoint
-IROMS/Nonlinear -IROMS/Representer -IROMS/Tangent -IROMS/SeaIce -IROMS/Drivers -IMaster ROMS
/Modules/mod_netcdf.F > mod_netcdf.f90
ROMS/Bin/cpp_clean mod_netcdf.f90
f95 -c -u -fast mod_netcdf.f90
f95: Warning: -xarch=native has been explicitly specified, or implicitly specified by a macro
option, -xarch=native on this architecture implies -xarch=v8plusa which generates code that does not run on pre UltraSPARC processors

MODULE mod_netcdf
^
"mod_netcdf.f90", Line = 1, Column = 14: ERROR: The compiler has detected errors in module "MOD_NETCDF". No module information file will be created for this module.

c
^
"mod_netcdf.f90", Line = 17, Column = 1: ERROR: The assignment statement is not allowed in a m
odule.

c Functions in the FORTRAN interface
^
"mod_netcdf.f90", Line = 18, Column = 1: ERROR: The assignment statement is not allowed in a module.

c
^
"mod_netcdf.f90", Line = 40, Column = 1: ERROR: The assignment statement is not allowed in a module.

c masks for the struct NC flag field; passed in as 'mode' arg to
^
"mod_netcdf.f90", Line = 41, Column = 1: ERROR: The assignment statement is not allowed in a module.


Netcdf libraries are installed in /usr/local/lib amd /usr/local/inlcude/. I also removed the -U flag as Kate suggested in a post earlier today, with the same result.


It seems to be a compiler problem. Perhaps I should give g95 a try.

Thanks,
Eli

elhunter
Posts: 9
Joined: Mon Dec 11, 2006 6:13 pm
Location: IMCS

Resolution

#2 Post by elhunter » Tue Dec 12, 2006 2:40 pm

Hello,

Well as it turns out the problem was with my netcdf.inc file. It was using "c" as a comment instead of "!". I upgraded my netcdf libraries and it seems to be compiling fine.

Thanks,
Eli

Post Reply