[petsc-users] ld: cannot find -lpetsc error

Diana Valencia valencia at astro.utoronto.ca
Tue Oct 13 21:04:35 CDT 2015


I meant to say that the code is working with PETSC despite the fact that when I tested, petsc did not pass the ex5 test.
cheers
Diana
_______________________
Diana Valencia
Assistant Professor,  Physics & Astrophysics
Department of Physical and Environmental Sciences 
University of Toronto, Scarborough
1265 Military Trail, Toronto, ON, Canada, M1C 1A4
Voice 416 208-2986

> On Oct 13, 2015, at 9:57 PM, Satish Balay <balay at mcs.anl.gov> wrote:
> 
> "however ex5 in the test examples failed"
> 
> Sorry - this message is a bit confusing. Is petsc working fine for
> your - or are you still having issues?
> 
> Satish
> 
> On Tue, 13 Oct 2015, Diana Valencia wrote:
> 
>> Dear Satish and all petsc users
>> Thank you for your email. Antoine Rozel also from the petsc community was able to help me (he also uses the same third party code I was trying to compile)
>> The version we use is old, because apparently is the one that works the best for the third party code.
>> I had to reinstall petsc, and somehow this fixed it.  The code compiled and is now running fine, however ex5 in the test examples failed.
>> Thanks for the input.
>> Diana
>> 
>> _______________________
>> Diana Valencia
>> Assistant Professor,  Physics & Astrophysics
>> Department of Physical and Environmental Sciences 
>> University of Toronto, Scarborough
>> 1265 Military Trail, Toronto, ON, Canada, M1C 1A4
>> Voice 416 208-2986
>> 
>>> On Oct 8, 2015, at 4:31 PM, Satish Balay <balay at mcs.anl.gov> wrote:
>>> 
>>> 1. Are you able to compile [using petsc makefile] and run PETSc examples?
>>> 
>>> 2. You are missing the link option -L/cluster/home/valencia/PETSC/petsc-3.2-p7/arch-linux2-c-opt/lib
>>> 
>>> [you should verify the output from the example compile/link commands -
>>> and the compile/link command for this application.]
>>> 
>>> BTW: This is an old version of petsc.
>>> 
>>> Satish
>>> 
>>> On Thu, 8 Oct 2015, Diana Valencia wrote:
>>> 
>>>> Dear PETSc users,
>>>> 
>>>> In hopes that one of you can help me solve a compiling problem.
>>>> 
>>>> I am compiling a third party code (stagyy and stagyympi) on a cluster. I load the intel and open_mpi libraries to the cluster before compiling with petsc.
>>>> After compiling all the subroutines, I get an error building the code. Here is the stout:
>>>> 
>>>> I have set the PETSC_DIR and PETSC_ARCH in the .bashrc file, so I don’t think this is the problem.
>>>> 
>>>> Thank you in advance for all your help.
>>>> Diana
>>>> 
>>>> 
>>>> .
>>>> .
>>>> .
>>>> mpif90  -w -O2 -assume byterecl -r8 -I /cluster/home/valencia/PETSC/petsc-3.2-p7/arch-linux2-c-opt/include -c main.f90
>>>> mpif90  -w -O2 -assume byterecl -r8 -I /cluster/home/valencia/PETSC/petsc-3.2-p7/arch-linux2-c-opt/include -c advdif.f90
>>>> mpif90  -w -O2 -assume byterecl -r8 -I /cluster/home/valencia/PETSC/petsc-3.2-p7/arch-linux2-c-opt/include -o stagyy main.o advdif.o communication.o continents.o evocore.o geometry.o init.o io.o iter.o melting.o miscellaneous.o MPDATA.o multi.o refstate.o phase_change.o poisson.o prolongate_restrict.o relax_all.o relax_cell.o relax_point.o residues.o tracers.o v_advection.o vee_cycle.o viscosity.o  crw.o geoid.o implicit_diffusion.o linpack.o plot.o wrtpng.o blas123.o lapack.o nxs_dummy.o  PETScimple_mod.o xdmf_hdf5_io_dummy.o bcs_mod.o composition_mod.o control_mod.o continents_mod.o vgrid_mod.o init_mod.o io_mod.o iter_mod.o melting_mod.o meltingfns_mod.o multi_mod.o phase_change_mod.o plot_mod.o precision_mod.o refstat_mod.o stencil_mod.o timestep_mod.o timing_mod.o tracers_mod.o viscosity_mod.o thermochem_mod.o platesLea_mod.o -lpng     -L/lib  -lpetsc -lX11 -lpthread -Wl,-rpath,/lib -lcmumps -ldmumps -lsmumps -lzmumps -lmumps_common -lpord -lparmetis -lmetis -lscalapack -lblacs -lsuperlu_4.2 -lml -lmpi_cxx -lumfpack -lamd -lflapack -lfblas -ldl -L/cluster/apps/openmpi/1.6.5/x86_64/intel_15.0.0/lib -lmpi -lopen-rte -lopen-pal -lnuma -lrt -lnsl -lutil -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/compiler/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/ipp/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/mkl/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/tbb/lib/intel64 -L/cluster/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2 -L/cluster/apps/gcc/4.8.2/lib64 -L/cluster/apps/gcc/4.8.2/lib -limf -lsvml -lirng -lipgo -ldecimal -lcilkrts -lstdc++ -lgcc_s -lirc -lpthread -lirc_s -lmpi_f90 -lmpi_f77 -lm -lm -lifport -lifcore -lm -lm -lm -lmpi_cxx -ldl -lmpi -lopen-rte -lopen-pal -lnuma -lrt -lnsl -lutil -limf -lsvml -lirng -lipgo -ldecimal -lcilkrts -lstdc++ -lgcc_s -lirc -lpthread -lirc_s -ldl 
>>>> ld: cannot find -lpetsc
>>>> make: *** [stagyy] Error 1
>>>> mpif90  -w -O2 -assume byterecl -r8 -I /cluster/home/valencia/PETSC/petsc-3.2-p7/arch-linux2-c-opt/include -o stagyympi main.o advdif.o communication.o continents.o evocore.o geometry.o init.o io.o iter.o melting.o miscellaneous.o MPDATA.o multi.o refstate.o phase_change.o poisson.o prolongate_restrict.o relax_all.o relax_cell.o relax_point.o residues.o tracers.o v_advection.o vee_cycle.o viscosity.o  crw.o geoid.o implicit_diffusion.o linpack.o plot.o wrtpng.o blas123.o lapack.o nxs_to_mpi.o PETScimple_mod.o xdmf_hdf5_io_dummy.o bcs_mod.o composition_mod.o control_mod.o continents_mod.o vgrid_mod.o init_mod.o io_mod.o iter_mod.o melting_mod.o meltingfns_mod.o multi_mod.o phase_change_mod.o plot_mod.o precision_mod.o refstat_mod.o stencil_mod.o timestep_mod.o timing_mod.o tracers_mod.o viscosity_mod.o thermochem_mod.o platesLea_mod.o -lpng     -L/lib  -lpetsc -lX11 -lpthread -Wl,-rpath,/lib -lcmumps -ldmumps -lsmumps -lzmumps -lmumps_common -lpord -lparmetis -lmetis -lscalapack -lblacs -lsuperlu_4.2 -lml -lmpi_cxx -lumfpack -lamd -lflapack -lfblas -ldl -L/cluster/apps/openmpi/1.6.5/x86_64/intel_15.0.0/lib -lmpi -lopen-rte -lopen-pal -lnuma -lrt -lnsl -lutil -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/compiler/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/ipp/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/mkl/lib/intel64 -L/cluster/apps/intel/composer_xe_2015.0.090/composer_xe_2015.0.090/tbb/lib/intel64 -L/cluster/apps/gcc/4.8.2/lib/gcc/x86_64-unknown-linux-gnu/4.8.2 -L/cluster/apps/gcc/4.8.2/lib64 -L/cluster/apps/gcc/4.8.2/lib -limf -lsvml -lirng -lipgo -ldecimal -lcilkrts -lstdc++ -lgcc_s -lirc -lpthread -lirc_s -lmpi_f90 -lmpi_f77 -lm -lm -lifport -lifcore -lm -lm -lm -lmpi_cxx -ldl -lmpi -lopen-rte -lopen-pal -lnuma -lrt -lnsl -lutil -limf -lsvml -lirng -lipgo -ldecimal -lcilkrts -lstdc++ -lgcc_s -lirc -lpthread -lirc_s -ldl 
>>>> ld: cannot find -lpetsc
>>>> make: *** [stagyympi] Error 1
>>>> make: Target `both' not remade because of errors.
>>>> 
>>>> _______________________
>>>> Diana Valencia
>>>> Assistant Professor,  Physics & Astrophysics
>>>> Department of Physical and Environmental Sciences 
>>>> University of Toronto, Scarborough
>>>> 1265 Military Trail, Toronto, ON, Canada, M1C 1A4
>>>> Voice 416 208-2986
>>>> 
>>>> 
>> 
>> 



More information about the petsc-users mailing list