You need to compile all your software (MPI, libraries, applications)
with the same symbol-mangling compiler flags. You're seeing these
errors because you have a mismatch of name mangling semantics (in this
case, underscores).
Example: if you use -fsecond-underscore to compile one of them, you
need to use it to compile all of them. FWIW: LAM (and OMPI) will
default to whatever the native name mangling scheme is. You can
override it by specifying LDFLAGS on LAM's (OMPI's) configure command
line.
On May 28, 2009, at 3:32 PM, Silviu Groza wrote:
>
> Removing -fsecond-underscore gives a new set of errors. According to
> dalton user mailing list, these errors are explicitally overcome by
> addind "-fsecond-underscore" due to gfortran inside mpif77.
>
> Here is the new set of errors:
>
> ---------------> Linking sequential dalton.x ...
> mpif77 -march=x86-64 -O3 -ffast-math -fexpensive-optimizations -
> funroll-loops -fno-range-check \
> -o /mnt/sda6/home/dalton-2.0/bin/dalton.x abacus/dalton.o cc/
> crayio.o abacus/linux_mem_allo.o \
> abacus/herpar.o eri/eri2par.o amfi/amfi.o amfi/symtra.o gp/
> mpi_dummy.o -Labacus -labacus -Lrsp -lrsp -Lsirius -lsirius -labacus
> -Leri -leri -Ldensfit -ldensfit -Lcc -lcc -Ldft -ldft -Lgp -lgp -
> Lpdpack -lpdpack -L/usr/lib -llapack -lblas
> eri/eri2par.o: In function `nodstr_':
> eri2par.F:(.text+0x41ac): undefined reference to `dft_cslave_'
> rsp/librsp.a(rspoli.o): In function `rspoli_':
> rspoli.F:(.text+0x1fbb): undefined reference to `dft_lin_respab_'
> rspoli.F:(.text+0x2bf9): undefined reference to `dft_lin_respf_'
> sirius/libsirius.a(sirdiis.o): In function `dft_add_ks_':
> sirdiis.F:(.text+0x2598): undefined reference to `dft_kohn_shamab_'
> sirius/libsirius.a(sirlintrn.o): In function `master.0.lintrn_':
> sirlintrn.F:(.text+0x3d6f): undefined reference to `dft_lin_respf_'
> sirius/libsirius.a(sirtr1.o): In function `tr1fcy_':
> sirtr1.F:(.text+0xc8fa): undefined reference to `dft_lin_respf_'
> dft/libdft.a(general.o): In function `fort_print':
> general.c:(.text+0x2b0): undefined reference to `fort_wrt__'
> dft/libdft.a(grid-gen.o): In function `gen_lmg_init':
> grid-gen.c:(.text+0x4c35): undefined reference to `get_maxl_nucind__'
> dft/libdft.a(grid-gen.o): In function `grid_gen_atom_new':
> grid-gen.c:(.text+0x4d05): undefined reference to `get_no_atoms__'
> grid-gen.c:(.text+0x4d83): undefined reference to
> `get_atom_by_icent__'
> dft/libdft.a(grid-gen.o): In function `grid_generate':
> grid-gen.c:(.text+0x5d9c): undefined reference to `ishell_cnt__'
> grid-gen.c:(.text+0x5dd7): undefined reference to `ishell_cnt__'
> dft/libdft.a(grid-gen.o): In function `grid_open':
> grid-gen.c:(.text+0x7713): undefined reference to `get_grid_paras__'
> grid-gen.c:(.text+0x7ab5): undefined reference to `set_grid_done__'
> grid-gen.c:(.text+0x7b15): undefined reference to `ishell_cnt__'
> grid-gen.c:(.text+0x7b26): undefined reference to `get_no_atoms__'
> grid-gen.c:(.text+0x7bae): undefined reference to
> `get_atom_by_icent__'
> dft/libdft.a(grid-gen.o): In function `grid_open_cmo':
> grid-gen.c:(.text+0x8289): undefined reference to
> `dft_get_ao_dens_mat__'
> dft/libdft.a(gen-so-int.o): In function `dftsoi_':
> gen-so-int.c:(.text+0xa2): undefined reference to
> `dft_get_ao_dens_mat__'
> gen-so-int.c:(.text+0x303): undefined reference to `write_soi__'
> dft/libdft.a(integrator.o): In function `dft_integrator_bl_new':
> integrator.c:(.text+0x19a): undefined reference to
> `dft_get_thresholds__'
> integrator.c:(.text+0x214): undefined reference to `ishell_cnt__'
> dft/libdft.a(integrator.o): In function `dft_grid_new':
> integrator.c:(.text+0x3ab): undefined reference to
> `dft_get_thresholds__'
> dft/libdft.a(integrator.o): In function `dft_integrate_ao_bl':
> integrator.c:(.text+0x50d): undefined reference to `ishell_cnt__'
> integrator.c:(.text+0x580): undefined reference to
> `construct_ioridx__'
> integrator.c:(.text+0x771): undefined reference to
> `getrho_blocked_gga__'
> integrator.c:(.text+0xa4f): undefined reference to
> `getrho_blocked_lda__'
> dft/libdft.a(prop-eval.o): In function `dft_lin_respf__':
> prop-eval.c:(.text+0x40d3): undefined reference to
> `dft_get_ao_dens_mat__'
> dft/libdft.a(prop-eval.o): In function `lin_resp_cb_b_lda':
> prop-eval.c:(.text+0x4943): undefined reference to
> `getexp_blocked_lda__'
> dft/libdft.a(prop-eval.o): In function `lin_resp_cb_b_gga':
> prop-eval.c:(.text+0x5a67): undefined reference to
> `getexp_blocked_gga__'
> dft/libdft.a(prop-eval.o): In function `dft_lin_respab__':
> prop-eval.c:(.text+0xa148): undefined reference to
> `dft_get_ao_dens_matab__'
> dft/libdft.a(prop-eval.o): In function `dft_lin_resp_':
> prop-eval.c:(.text+0xaa77): undefined reference to
> `dft_get_ao_dens_mat__'
> collect2: ld returned 1 exit status
> mpif77: No such file or directory
> make: *** [linux.x] Error 1
>
> But adding -fsecond-underscore gives the errors in the first message.
> Still don't know what is going wrong.
>
> Thank you,
> Silviu
>
> Try removing the -fsecond-underscore option from your FFLAGS in the
> makefile. LAM/MPI was likely built without that option, which means
> that
> the name mangling convention is different between when LAM was
> compiled
> and your application was built. Removing the option should ensure the
> same name mangling is used.
>
>
>
> _______________________________________________
> This list is archived at http://www.lam-mpi.org/MailArchives/lam/
>
--
Jeff Squyres
Cisco Systems
|