PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

MM5 MPP
Goto page Previous  1, 2, 3  Next
 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
mkcolg



Joined: 30 Jun 2004
Posts: 6208
Location: The Portland Group Inc.

PostPosted: Wed May 10, 2006 1:05 pm    Post subject: Reply with quote

Hi Sluce,

We were able to compile and link MM5 MPP without problems here using the PGI 6.1-1 CDK which includes a precomiled version of MPICH. We used the MM5.TAR.gz and MPP.TAR.gz packages found at UCAR's ftp site and performed the following steps:

1) Unpacked the two packages. MM5 first, then unpacked MPP within the new MM5 directory.
2) Uncommented section 7g in the "configure.users" file.
3) Changed the "LINUX_MPIHOME" to the base directory of our MPICH installation. In our case this is /usr/pgi/linux86-64/6.1-1.
4) Added "CC = pgcc" so "parseconfig" is built correctly.
5) Added "-I/path/to/MM5/include" to the FCFLAGS. This is used to find "parame.incl".
6) Added "-DDEC_ALPHA" to FCFLAGS. This is needed to run MM5 correctly in 64-bit mode.
7) Removed "-tp p6 -pc 32" from FCFLAGS and LDOPTIONS. "-tp p6" sets the target architecture to a 32-bit Pentium II. "-pc 32" sets the x87 precision control to 32-bits. This flag is not needed on a 64-bit target system.
8) Typed 'make'


As for your errors. MPI_Fint is typedef'd in both "mpi_fortdefs.h" and "mpio.h". However, in my MPICH install it's guarded by a define flag "NEEDS_MPI_FINT" in "mpio.h". Either your install does not have this guard or "NEEDS_MPI_FINT" is defined in your mpicc script or another header file. If you can figure out why MPI_Fint is being typedef'd twice, you should be able to proceed.

I don't know what version of MPICH your using, but if your so inclined, you can try building MPICH from scratch using the same source use use. We wrote a guide on building MPICH 1.2.7 which might be helpful. Of course, this should not be neccessary.

I hope this helps but since I can't recreate your exact error it's difficult to give anything but an educated guess as to the problem.

- Mat
Back to top
View user's profile
slunce



Joined: 04 May 2006
Posts: 7

PostPosted: Thu May 11, 2006 1:41 pm    Post subject: Reply with quote

Hi,
Mat thank you for your help
Mat it impossible to follow your recommendation: to download the latest version of MM5, because I have to work with MM5-urbanized version. In this urbanized version there are some additional files and and there are some changes in programs. So if download the newest version of MM5 that means that I have rewrite the code, but I can do this . I have no idea how to solve this multiple definition problem
L/librsl.a -O2 -Mcray=pointer -Mnoframe -byteswapio -L/usr/local/topspin/mpi/mpich/lib64 -lfmpich -lmpich
transm_col.o(.text+0x0): In function `transm_col_':
: multiple definition of `transm_col_'
transm_col.o(.text+0x0): first defined here
make[1]: [all] Error 2 (ignored)

but I hope that someone can guess how it can be fixed it

hris
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6208
Location: The Portland Group Inc.

PostPosted: Thu May 11, 2006 2:40 pm    Post subject: Reply with quote

Ok, let's figure out where the second "transm_col_" definition is coming from. Run the following commands to determine which objects contain this definition:
Code:
foreach i ( `find ./ -name "*.o"` )
echo $i
nm $i | grep -i transm_col
end

My guess is that you have compiled physics/radiation/sfc/transm.F twice, once as transm.o and an second as transm_col.o, but used the define flag "-DMPP1_COLUMNWISE" in both cases. Transm has two interfaces, transm and transm_col, and the define flag chooses which one to use. If this is the case, then recompile transm.o without the define flag.

- Mat
Back to top
View user's profile
slunce



Joined: 04 May 2006
Posts: 7

PostPosted: Thu May 11, 2006 6:48 pm    Post subject: Reply with quote

Mat, here is the result of

foreach i ( `find ./ -name "*.o"` )
echo $i
nm $i | grep -i transm_col
end

/MPP/RSL/RSL/set_padarea.o
./MPP/RSL/RSL/set_f_padarea.o
./MPP/RSL/RSL/domain_def.o
./MPP/RSL/RSL/mesh_topo.o
./MPP/RSL/RSL/decomp.o
./MPP/RSL/RSL/within_nest.o
./MPP/RSL/RSL/show_decomp.o
./MPP/RSL/RSL/rsl_nl.o
./MPP/RSL/RSL/rsl_new_decom.o
./MPP/RSL/RSL/rsl_malloc.o
./MPP/RSL/RSL/index.o
./MPP/RSL/RSL/border.o
./MPP/RSL/RSL/pt.o
./MPP/RSL/RSL/rsl_initial.o
./MPP/RSL/RSL/proc.o
./MPP/RSL/RSL/proc_f.o
./MPP/RSL/RSL/buf_for_proc.o
./MPP/RSL/RSL/comp_sten.o
./MPP/RSL/RSL/message_def.o
./MPP/RSL/RSL/stencil_def.o
./MPP/RSL/RSL/pack_message.o
./MPP/RSL/RSL/rsl_io.o
./MPP/RSL/RSL/exch_sten.o
./MPP/RSL/RSL/rsl_probe.o
./MPP/RSL/RSL/comp_cells_f.o
./MPP/RSL/RSL/comp_cells.o
./MPP/RSL/RSL/fort_realread.o
./MPP/RSL/RSL/fort_intread.o
./MPP/RSL/RSL/fort_complexread.o
./MPP/RSL/RSL/fort_characterread.o
./MPP/RSL/RSL/fort_close.o
./MPP/RSL/RSL/fort_realwrite.o
./MPP/RSL/RSL/fort_intwrite.o
./MPP/RSL/RSL/fort_complexwrite.o
./MPP/RSL/RSL/rsl_ioserve.o
./MPP/RSL/RSL/cd.o
./MPP/RSL/RSL/fort_characterwrite.o
./MPP/RSL/RSL/rsl_init_f.o
./MPP/RSL/RSL/rsl_mm_io.o
./MPP/RSL/RSL/handle_spec1.o
./MPP/RSL/RSL/handle_spec2.o
./MPP/RSL/RSL/rsl_funit_close.o
./MPP/RSL/RSL/rsl.o
./MPP/RSL/RSL/fort_bdyin_real.o
./MPP/RSL/RSL/xpose.o
./MPP/RSL/RSL/rsl_bcast.o
./MPP/RSL/RSL/rsl_merge.o
./MPP/RSL/RSL/rsl_order.o
./MPP/RSL/RSL/handle_spec3.o
./MPP/RSL/RSL/rsl_bcast_f.o
./MPP/RSL/RSL/rsl_merge_f.o
./MPP/RSL/RSL/rsl_move.o
./MPP/RSL/RSL/rsl_debug.o
./MPP/RSL/RSL/rsl_mon_bcast.o
./MPP/RSL/RSL/rsl_fopen_f.o
./MPP/RSL/RSL/rsl_socket.o
./MPP/RSL/RSL/debug.o
./MPP/RSL/RSL/rsl_fclose_f.o
./MPP/RSL/RSL/comp_slabs.o
./MPP/RSL/RSL/comp_slabs_f.o
./MPP/RSL/RSL/destroy_list.o
./MPP/RSL/RSL/comp_world.o
./MPP/RSL/RSL/rsl_child_info.o
./MPP/RSL/RSL/get_bdy_info.o
./MPP/RSL/RSL/patchmap.o
./MPP/RSL/RSL/default_decomposition.o
./MPP/RSL/RSL/rsl_remap_state.o
./MPP/RSL/RSL/boundary_safe.o
./MPP/RSL/RSL/period_def.o
./MPP/RSL/RSL/fill_boundary.o
./MPP/RSL/RSL/process_refs.o
./MPP/RSL/RSL/comp_xpose.o
./MPP/RSL/RSL/rsl_error_dup.o
./MPP/RSL/RSL/fort_bdyin_dbl.o
./MPP/RSL/RSL/xpose_def.o
./MPP/RSL/RSL/mpi_init_f.o
./MPP/RSL/RSL/vicopy.o
./MPP/RSL/RSL/fort_doubleread.o
./MPP/RSL/RSL/fort_doublewrite.o
./MPP/RSL/RSL/comp_period.o
./MPP/RSL/RSL/exch_period.o
./MPP/RSL/RSL/period_refs.o
./MPP/RSL/RSL/rsl_hemiforce.o
./MPP/RSL/RSL/rsl_mpi_compat.o
./MPP/build/acm.o
./MPP/build/addall.o
./MPP/build/addrx1c.o
./MPP/build/addrx1n.o
./MPP/build/after_surface.o
./MPP/build/after_urbsol.o
./MPP/build/bare.o
./MPP/build/before_surface.o
./MPP/build/before_urbsol.o
./MPP/build/bdyin.o
./MPP/build/bdyrst.o
./MPP/build/bdyten.o
./MPP/build/bdyval.o
./MPP/build/cadjmx.o
./MPP/build/cal_albedo.o
./MPP/build/coef_diffu.o
./MPP/build/coefcd2d.o
./MPP/build/coefcd3d.o
./MPP/build/condload.o
./MPP/build/consat.o
./MPP/build/convad.o
./MPP/build/couple.o
./MPP/build/date.o
./MPP/build/dcpl3d.o
./MPP/build/dcpl3dwnd.o
./MPP/build/decouple.o
./MPP/build/define_comms.o
./MPP/build/diffu.o
./MPP/build/dm_io.o
./MPP/build/dots.o
./MPP/build/dtfrz.o
./MPP/build/eddymm4.o
./MPP/build/fcqvsat.o
./MPP/build/fcqvsat_snow.o
./MPP/build/fillcrs.o
./MPP/build/fkill_model.o
./MPP/build/gamma.o
./MPP/build/gauss.o
./MPP/build/hadv.o
./MPP/build/init.o
./MPP/build/initsav.o
./MPP/build/initts.o
./MPP/build/kfbmdata.o
./MPP/build/kill_model.o
./MPP/build/lb_alg.o
./MPP/build/lbdyin.o
./MPP/build/mhz.o
./MPP/build/mm5.o
./MPP/build/mp_equate.o
./MPP/build/mp_initdomain.o
./MPP/build/mp_shemi.o
./MPP/build/mparrcopy.o
./MPP/build/mpaspect.o
./MPP/build/nconvp.o
./MPP/build/nudge.o
./MPP/build/output.o
./MPP/build/outsav.o
./MPP/build/outtap.o
./MPP/build/outts.o
./MPP/build/outts_c.o
./MPP/build/param.o
./MPP/build/paramr.o
./MPP/build/qflux.o
./MPP/build/radsfc.o
./MPP/build/rdinit.o
./MPP/build/savread.o
./MPP/build/settbl.o
./MPP/build/setvegfr.o
./MPP/build/sfcmm4.o
./MPP/build/sfcrad.o
./MPP/build/shutdo.o
./MPP/build/slab.o
./MPP/build/smass.o
./MPP/build/soilav.o
./MPP/build/solar1.o
./MPP/build/solve.o
./MPP/build/sound.o
./MPP/build/subch.o
./MPP/build/surface_soil.o
./MPP/build/trans.o
./MPP/build/transm.o
./MPP/build/upshot_mm5.o
./MPP/build/urbevapflx.o
./MPP/build/urbradnet.o
./MPP/build/urbsol.o
./MPP/build/vadv.o
./MPP/build/vdiff.o
./MPP/build/vecgath.o
./MPP/build/vegeland.o
./MPP/build/write_big_header.o
./MPP/build/write_fieldrec.o
./MPP/build/write_flag.o
./MPP/build/exmoisr.o
./MPP/build/exmoiss.o
./MPP/build/cup.o
./MPP/build/cupara3.o
./MPP/build/maximi.o
./MPP/build/minimi.o
./MPP/build/gspbl.o
./MPP/build/slab_col.o
./MPP/build/sfcrad_col.o
U transm_col_
./MPP/build/transm_col.o
0000000000000000 T transm_col_
./MPP/build/acm_col.o
./MPP/build/after_urbsol_col.o
./MPP/build/before_urbsol_col.o
./MPP/build/eddymm4_col.o
./MPP/build/radsfc_col.o
U transm_col_
./MPP/build/sfcmm4_col.o
./MPP/build/smass_col.o
./MPP/build/urbsol_col.o
./MPP/build/vdiff_col.o
./MPP/build/urbevapflx_col.o
./MPP/build/urbradnet_col.o
./MPP/build/cal_albedo_col.o
./MPP/build/coefcd2d_col.o
./MPP/build/coefcd3d_col.o
./MPP/build/lwrad.o
./MPP/build/swrad.o
./MPP/build/inirad.o
./MPP/build/o3data.o
./MPP/build/mm5atm.o
./MPP/build/rrtm.o
./MPP/build/rrtm_gasabs.o
./MPP/build/rrtm_init.o
./MPP/build/rrtm_k_g.o
./MPP/build/rrtm_rtrn.o
./MPP/build/rrtm_setcoef.o
./MPP/build/rrtm_taumol.o
./MPP/build/milliclock.o
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6208
Location: The Portland Group Inc.

PostPosted: Thu May 11, 2006 8:05 pm    Post subject: Reply with quote

Hmmm. Since it's only defined once in the MPP objects, the second reference could be coming from a library. Use 'nm' and 'grep' again with the libraries to see if it's coming from one of them.

Also, why don't you try removing "transm_col.o" from the link.

- Mat
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Goto page Previous  1, 2, 3  Next
Page 2 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group