compilation error rdrag=???

Report or discuss software problems and other woes

Moderators: arango, robertson

Post Reply
Message
Author
undave
Posts: 11
Joined: Mon Jul 16, 2007 5:30 pm
Location: Florida Gulf Coast University

compilation error rdrag=???

#1 Unread post by undave »

I'm trying to adapt the cppdefs.h from a project that successfully compiled about 10 years ago. The ana_drag.h file assigns rdrag=???, which the compiler does not like. How do I assign the value? I tried other BBL combinations but had similar problems. I tried copying the expression for the upwelling case assigned to rdrag, which did not work, nor did simply assigning a scalar value. Interestingly, when I look at the analytical.f90 file from the old compilation, there are no "rdrag" variables. The compiler error is below, and my cppdefs.h follows

TIA

....
cd /projects/dafu8991/CALUS/Build; /curc/sw/intel/17.4/impi/2017.3.196/bin64/mpif90 -c -heap-arrays -fp-model precise -ip -O3 -free analytical.f90
analytical.f90(373): error #5078: Unrecognized token '?' skipped
rdrag(i,j)=???
---------------------^
analytical.f90(373): error #5078: Unrecognized token '?' skipped
rdrag(i,j)=???
----------------------^
analytical.f90(373): error #5078: Unrecognized token '?' skipped
rdrag(i,j)=???
-----------------------^
analytical.f90(373): error #5082: Syntax error, found END-OF-STATEMENT when expecting one of: <REAL_KIND_CON> <REAL_CONSTANT> <DBLPRC_CONSTANT> <DBLPRC_KIND_CON> <QUAPRC_CONSTANT> ...
rdrag(i,j)=???
------------------------^
compilation aborted for analytical.f90 (code 1)
make: *** [/projects/dafu8991/CALUS/Build/analytical.o] Error 1

The cppdefs.h file:
/*
$
*******************************************************************************
** Copyright (c) 2002-2007 The ROMS/TOMS Group **
** Licensed under a MIT/X style license **
** See License_ROMS.txt **
*******************************************************************************
**
**
*/

#undef WBLGRAV_HTG
#undef STATIONS
#define WET_DRY
#define CURVGRID
#define FLOATS
#define UV_ADV
#define UV_COR
#define DJ_GRADPS
#define TS_PSOURCE
#define UV_PSOURCE
#undef ANA_INITIAL
#undef DIAGNOSTICS_UV
#undef DIAGNOSTICS_TS

/* define one advection scheme here*/
#undef TS_U3HADVECTION
#undef TS_SVADVECTION
#define TS_MPDATA

#define SPLINES
#define TS_DIF2
#define MIX_GEO_TS
#define NONLIN_EOS
#define SALINITY
#define MASKING
#define SOLVE3D
/* turned off the writing of averages 17 Feb 2009
#define AVERAGES
#define AVERAGES_AKV
#define AVERAGES_AKT
#define AVERAGES_AKS
#define AVERAGES_FLUXES
*/

/* BBL run with full sediment run */
# define SEDIMENT
# define SUSPLOAD
# define ANA_WWAVE
#ifdef ANA_WWAVE
# define WAVES_HEIGHT
# define WAVES_BOT_PERIOD
# undef WAVES_TOP_PERIOD
# define WAVES_LENGTH
# undef WAVES_UB
#endif
# undef ANA_SEDIMENT
# undef SWAN
# undef RIVER_SEDIMENT
# undef SED_DENS
# undef BEDLOAD_MPM

/* define only one of the four following */
#undef UV_LOGDRAG
#undef MB_BBL
#undef SG_BBL
#define SSW_BBL

#ifdef SG_BBL
#define SG_CALC_ZNOT
#undef SG_LOGINT
#endif

#ifdef MB_BBL
#define MB_CALC_ZNOT
#undef MB_Z0BIO
#undef MB_Z0BL
#undef MB_Z0RIP
#endif

#ifdef SSW_BBL
#define SSW_CALC_ZNOT
#undef SSW_LOGINT
#undef SSW_Z0RIP
#endif

/* define one vertical mixing scheme here*/
#undef LMD_MIXING
#define MY25_MIXING
#undef GLS_MIXING
#if defined GLS_MIXING || defined MY25_MIXING
# define KANTHA_CLAYSON
# define N2S2_HORAVG
#endif

#define CRAIG_BANNER
#define CHARNOK
#undef ANA_SRFLUX
#undef ALBEDO
#define DIURNAL_SRFLUX
#define ANA_SSFLUX
#define ANA_BSFLUX
#define ANA_BPFLUX
#define ANA_BTFLUX
#define ANA_SPFLUX

#define BULK_FLUXES
#ifdef BULK_FLUXES
# undef LONGWAVE
# undef SOLAR_SOURCE
# define ANA_RAIN
# define ANA_SRFLUX
# undef COOL_SKIN
#endif
/* don't have longwave radiation so calculating it */
#define LONGWAVE

/* using tides from OSU tidal prediction website now */
#define SSH_TIDES
#define UV_TIDES

/* #define NORTH_FSGRADIENT
#define NORTH_M2GRADIENT */


#define WEST_M2FLATHER
#define WEST_FSCHAPMAN
#define WEST_M3GRADIENT
/*#define WEST_M3RADIATION*/
#define WEST_TGRADIENT

#define EAST_M2FLATHER
#define EAST_FSCHAPMAN
#define EAST_M3GRADIENT
/*#define EAST_M3RADIATION*/
#define EAST_TGRADIENT

#define SOUTH_M2FLATHER
#define SOUTH_FSCHAPMAN
#define SORTH_M3GRADIENT
/*#define SOUTH_M3RADIATION*/
#define SOUTH_TGRADIENT

#define NORTHERN_WALL

#define ANA_FSOBC
#define ANA_M2OBC

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: compilation error rdrag=???

#2 Unread post by kate »

If you look at analytical.F, it should only be sucking in ana_drag.h if both ANA_DRAG and UV_DRAG_GRID are defined. I don't see either of those in your cpp file, so I don't know where that's coming from.

undave
Posts: 11
Joined: Mon Jul 16, 2007 5:30 pm
Location: Florida Gulf Coast University

Re: compilation error rdrag=???

#3 Unread post by undave »

Thanks for your response. I added
#undef ANA_DRAG
#undef UV_DRAG_GRID
to the end of the cppdefs.h and got a new error, below:



cd /projects/dafu8991/CALUS/Build; /curc/sw/intel/17.4/impi/2017.3.196/bin64/mpif90 - c -heap-arrays -fp-model precise -ip -O3 -free analytical.f90
analytical.f90(791): error #6401: The attributes of this name conflict with those mad e accessible by a USE statement. [EWPERIODIC]
logical :: EWperiodic=.FALSE.
-----------------^
analytical.f90(791): error #6562: A data initialization-expr is not valid for this ob ject. [EWPERIODIC]
logical :: EWperiodic=.FALSE.
-----------------^
analytical.f90(792): error #6401: The attributes of this name conflict with those mad e accessible by a USE statement. [NSPERIODIC]
logical :: NSperiodic=.FALSE.
-----------------^
analytical.f90(792): error #6562: A data initialization-expr is not valid for this ob ject. [NSPERIODIC]
logical :: NSperiodic=.FALSE.
-----------------^
analytical.f90(1224): error #6401: The attributes of this name conflict with those ma de accessible by a USE statement. [EWPERIODIC]
logical :: EWperiodic=.FALSE.
-----------------^
analytical.f90(1224): error #6562: A data initialization-expr is not valid for this o bject. [EWPERIODIC]
logical :: EWperiodic=.FALSE.
-----------------^
analytical.f90(1225): error #6401: The attributes of this name conflict with those ma de accessible by a USE statement. [NSPERIODIC]
logical :: NSperiodic=.FALSE.
-----------------^
analytical.f90(1225): error #6562: A data initialization-expr is not valid for this o bject. [NSPERIODIC]
logical :: NSperiodic=.FALSE.
-----------------^
analytical.f90(885): error #6404: This name does not have a type, and must have an ex plicit type. [R_DATE]
CALL caldate (r_date, tdays(ng), year, yday, month, iday, hour)
--------------------^
analytical.f90(937): error #6634: The shape matching rules of actual arguments and du mmy arguments have been violated. [EWPERIODIC]
& NghostPoints, EWperiodic, NSperiodic, &
----------------------------------------^
analytical.f90(937): error #6634: The shape matching rules of actual arguments and du mmy arguments have been violated. [NSPERIODIC]
& NghostPoints, EWperiodic, NSperiodic, &
----------------------------------------------------^
compilation aborted for analytical.f90 (code 1)
make: *** [/projects/dafu8991/CALUS/Build/analytical.o] Error 1

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: compilation error rdrag=???

#4 Unread post by kate »

Well, next is to look at the analytical.f90 file to see what ana_xxx.h files all those errors are coming from. There's got to be a method to this madness, but I can't tell what from here.

Post Reply