Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

Problems about compiling CAM3.1 on OSF1 platform

Hi, everyone,
After I finish configure by

./configure -cam_bld ./mywork -nc_inc /usr/local/NetCDF3.6.0/include -nc_lib /usr/local/NetCDF3.6.0/lib/ -mpi_inc /usr/local/MPICH1.2.7/include/ -mpi_lib /usr/local/MPICH1.2.7/lib/,

I try to compile cam3 like, gmake , however, there are some problems coming out like the followings,

f90 -I. -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/physics/cam1 -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/control -I/data1/sunxg/CAM3.1/cam1/models/csm_share/shr -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/utils -I/data1/sunxg/CAM3.1/cam1/models/utils/timing -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/advection/slt -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/src/ocnsice/dom -I/data1/sunxg/CAM3.1/cam1/models/lnd/clm2/src/main -I/data1/sunxg/CAM3.1/cam1/models/lnd/clm2/src/biogeophys -I/data1/sunxg/CAM3.1/cam1/models/lnd/clm2/src/biogeochem -I/data1/sunxg/CAM3.1/cam1/models/lnd/clm2/src/mksrfdata -I/data1/sunxg/CAM3.1/cam1/models/lnd/clm2/src/riverroute -I/data1/sunxg/CAM3.1/cam1/models/ice/csim4 -I/usr/local/NetCDF3.6.0/include -I/usr/local/MPICH1.2.7/include/ -I/data1/sunxg/CAM3.1/cam1/models/atm/cam/bld/esmf/mod/modO/alpha -I/usr/local/NetCDF3.6.0/lib/ -DCAM -DNO_SHR_VMATH -DHIDE_SHR_MSG -r8 -i4 -c -omp -automatic -fpe3 -check omp_bindings -I/usr/local/MPICH1.2.7/include/ -O2 -inline speed -DOSF1 -free -fpe3 /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90
f90: Warning: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 22: Conflicting attributes or multiple declaration of name. [NPES]
use spmd_dyn, only: npes, cut, cutex, neighs, neighs_proc, &
----------------------^
f90: Warning: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 22: Conflicting attributes or multiple declaration of name. [CUT]
use spmd_dyn, only: npes, cut, cutex, neighs, neighs_proc, &
----------------------------^
f90: Error: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 45: The same named entity from different modules and/or program units cannot be referenced. [NPES]
if (npes .lt. 2) return
------^
f90: Error: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 61: The same named entity from different modules and/or program units cannot be referenced. [CUT]
call intersct(cut(1,iam),cutex(1,others),outreg)
----------------------^
f90: Error: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 75: The same named entity from different modules and/or program units cannot be referenced. [CUT]
call intersct(cut(1,othern),cutex(1,iam),inreg)
----------------------^
f90: Error: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 98: The same named entity from different modules and/or program units cannot be referenced. [CUT]
call intersct(cut(1,iam),cutex(1,othern),outreg)
----------------------^
f90: Error: /data1/sunxg/CAM3.1/cam1/models/atm/cam/src/dynamics/eul/bndexch.F90, line 112: The same named entity from different modules and/or program units cannot be referenced. [CUT]
call intersct(cut(1,others),cutex(1,iam),inreg)
----------------------^
gmake: *** [bndexch.o] Error 1

so, I'd like your helps about how to solve these problems.

Thanks in advance.
 
I've tried to solve the problem, the reason for causing such problems is that the code of bndexch.F90 has a little bug, the use moduler sentence is defined twice.


However, after fixing such problem, I met another one, that is when gmake is going to finish linking all object files into executable file, cam, the -lelan cannot be finded, the details are

f90 -o /data1/sunxg/CAM3.1/cam1/models/atm/cam/bld/mywork/cam BalanceCheckMod.o BareGroundFluxesMod.o Biogeophysics1Mod.o Biogeophysics2Mod.o BiogeophysicsLakeMod.o CanopyFluxesMod.o DGVMAllocationMod.o DGVMEcosystemDynMod.o DGVMEstablishmentMod.o DGVMFireMod.o DGVMKillMod.o DGVMLightMod.o DGVMMod.o DGVMMortalityMod.o DGVMReproductionMod.o DGVMRestMod.o DGVMTurnoverMod.o DriverInitMod.o FracWetMod.o FrictionVelocityMod.o Hydrology1Mod.o Hydrology2Mod.o HydrologyLakeMod.o QSatMod.o RtmMod.o RunoffMod.o STATICEcosysDynMod.o SnowHydrologyMod.o SoilHydrologyMod.o SoilTemperatureMod.o SurfaceAlbedoMod.o SurfaceRadiationMod.o TridiagonalMod.o VOCEmissionMod.o abortutils.o acbnd.o accFldsMod.o accumulMod.o advnce.o aer_optics.o aerosol_intr.o albice.o albocean.o areaMod.o atm_lndMod.o atmdrvMod.o bandij.o basdy.o basdz.o basiy.o bilin.o binary_io.o bnddyi.o bndexch.o buffer.o caer.o caerbnd.o cam.o camice.o camoce.o carbon_intr.o carbonscales.o ccsm_msg.o check_energy.o chem_surfvals.o chemistry.o cldconst.o cldinti.o cldsav.o cldwat.o clm_csmMod.o clm_varcon.o clm_varctl.o clm_varpar.o clm_varsur.o clmtype.o clmtypeInitMod.o cloud_fraction.o cloudsimulator.o cmparray_mod.o comhd.o commap.o comspe.o comsrf.o comsrfdiag.o constituents.o controlMod.o convect_deep.o convect_shallow.o courlim.o cpslec.o cubxdr.o cubydr.o cubzdr.o dadadj.o datetime.o decompMod.o decompinit.o diag_dynvar_ic.o diagnostics.o difcor.o diffusion_solver.o dmsbnd.o do_close_dispose.o do_restwrite.o dp_coupling.o driver.o drydep_mod.o dust.o dust_intr.o dust_sediment_mod.o dycore.o dyn.o dyn_grid.o dynconst.o dyndrv.o dynpkg.o engy_tdif.o engy_te.o error_messages.o esinti.o extx.o extys.o extyv.o f_wrappers.o fft99.o filenames.o fileutils.o filterMod.o flxint.o flxoce.o gauaw_mod.o geopotential.o get_memusage.o getdatetime.o gffgch.o ghg_defaults.o gptl.o gptl_papi.o gptlutil.o grcalc.o grdxy.o grmult.o gw_drag.o hb_diff.o hdinti.o herxin.o heryin.o herzin.o histFileMod.o histFldsMod.o history.o hk_conv.o hordif.o hordif1.o hrintp.o hycoef.o icarus_scops.o ice_constants.o ice_data.o ice_dh.o ice_diagnostics.o ice_globalcalcs.o ice_kinds_mod.o ice_ocn_flux.o ice_sfc_flux.o ice_srf.o ice_tstm.o infnan.o iniTimeConst.o iniTimeVar.o inicFileMod.o inidat.o initGridCellsMod.o inital.o initcom.o initext.o initializeMod.o initindx.o inti.o intp_util.o ioFileMod.o iobinary.o iop.o kdpfnd.o lagyin.o lcbas.o lcdbas.o limdx.o limdy.o limdz.o linebuf_stdout.o linemsdyn.o lininterp.o lnd2atmMod.o lp_coupling.o marsaglia.o massfix.o mkglacier.o mkgridMod.o mklai.o mklanwat.o mkpft.o mkrank.o mksoicol.o mksoitex.o mksrfdatMod.o mkurban.o molec_diff.o mpiinc.o mpishorthand.o nanMod.o ncdio.o ncdio_atm.o omcalc.o ozone_data.o param_cldoptics.o pdelb0.o pft2colMod.o pftvarcon.o phcs.o phys_adiabatic.o phys_buffer.o phys_gmean.o phys_grid.o phys_idealized.o physconst.o physics_types.o physpkg.o pkg_cld_sediment.o pkg_cldoptics.o plevs0.o pmgrid.o ppgrid.o prescribed_aerosols.o print_coverage.o print_memusage.o prognostics.o program_csm.o program_off.o pspect.o qmassa.o qmassd.o qneg3.o qneg4.o quad.o quicksort.o rad_constituents.o radae.o radheat.o radiation.o radlw.o radsw.o ramp_scon.o readinitial.o realloc4.o realloc7.o reordp.o restFileMod.o restart.o restart_dynamics.o restart_physics.o rgrid.o rstwr.o runtime_opts.o scan2.o scandyn.o scanslt.o scm0.o scyc.o seasalt_intr.o settau.o sgexx.o shr_alarm_mod.o shr_cal_mod.o shr_const_mod.o shr_date_mod.o shr_file_mod.o shr_kind_mod.o shr_mpi_mod.o shr_msg_mod.o shr_orb_mod.o shr_sys_mod.o shr_timer_mod.o shr_vmath_fwrap.o shr_vmath_mod.o snowdp2lev.o soxbnd.o spegrd.o spetru.o sphdep.o spmdGathScatMod.o spmdMod.o spmd_dyn.o spmd_phys.o spmd_utils.o spmdinit.o srchutil.o srfoce.o srfxfer.o sst_data.o stats.o stepon.o stratiform.o string_utils.o subgridAveMod.o sulbnd.o sulchem.o sulemis.o sulfur_intr.o surfFileMod.o swap_comm.o system_messages.o tfilt_massfix.o threadutil.o time_manager.o timeinterp.o tphysac.o tphysbc.o tphysidl.o tracers.o tracers_suite.o trb_mtn_stress.o trjmps.o trunc.o tsinti.o tstep.o units.o upper_bc.o vertical_diffusion.o vertinterp.o virtem.o volcanicmass.o volcemission.o volcrad.o vrtmap.o wetdep.o wrap_mpi.o wrap_nf.o wv_saturation.o xqmass.o zenith.o zm_conv.o -L/usr/local/NetCDF3.6.0/lib -lnetcdf -L/usr/local/MPICH1.2.7/lib -lmpich -L/data1/sunxg/CAM3.1/cam1/models/atm/cam/bld/mywork/esmf/lib/libO/alpha -lesmf -omp -lcxml -lmpich -lelan
ld:
Can't locate file for: -lelan
f90: Severe: Failed while trying to link.
gmake: *** [/data1/sunxg/CAM3.1/cam1/models/atm/cam/bld/mywork/cam] Error 1
 
Top