On Tue, Jan 26, 2021 at 4:50 AM Pedro Rodrigues <pjsgr...@gmail.com> wrote:
> Hello > > I tried to build under Linux but got this error message: > > > /usr/bin/ld: > > /home/ubuntu/Dev/petsc/arch-linux2-c-debug/lib/libmpi.a(lib_libmpi_la-initthread.o): > relocation R_X86_64_TPOFF32 against hidden symbol `MPIR_Per_thread' can not > be used when making a shared object > /usr/bin/ld: > /home/ubuntu/Dev/petsc/arch-linux2-c-debug/lib/libpetsc.a(str.o): > relocation R_X86_64_PC32 against symbol `petscstack' can not be used when > making a shared object; recompile with -fPIC > /usr/bin/ld: final link failed: bad value > collect2: error: ld returned 1 exit status > make[1]: *** [Makefile:12332: libmesh_opt.la] Error 1 > make[1]: Leaving directory '/home/ubuntu/Dev/libmesh' > make: *** [Makefile:32014: all-recursive] Error 1 > > Can you help? > Hmm... did you request PETSc to download/build its own MPI? And only static libs? Just wondering because it looks like your MPI and PETSc /home/ubuntu/Dev/petsc/arch-linux2-c-debug/lib/libmpi.a /home/ubuntu/Dev/petsc/arch-linux2-c-debug/lib/libpetsc.a are both static (foo.a) libs. If this was intentional, you'll probably need to configure libmesh with --disable-shared --enable-static (yes, you need both) to be consistent with PETSc and MPI. -- John _______________________________________________ Libmesh-users mailing list Libmesh-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libmesh-users