- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi there,
I'm trying to compile the PETSc 3.14.1 libraries on Windows with Intel Compiler (from Parallel Studio XE), MKL and MPI (all v. 2019 update 5). I've run into an issue when linking which gives the following error:
Creating library C:\Users\rpepper\git\library\tools\windows\petsc\PETSC-~1\ARCH-M~1\lib\libpetsc.lib and object C:\Users\rpepper\git\library\tools\windows\petsc\PETSC-~1\ARCH-M~1\lib\libpetsc.exp
eventlog.o : error LNK2001: unresolved external symbol MPI_Wtime
plexgeometry.o : error LNK2001: unresolved external symbol MPI_Wtime
plog.o : error LNK2001: unresolved external symbol MPI_Wtime
xmllogevent.o : error LNK2001: unresolved external symbol MPI_Wtime
classlog.o : error LNK2001: unresolved external symbol MPI_Wtime
stagelog.o : error LNK2001: unresolved external symbol MPI_Wtime
sfwindow.o : error LNK2019: unresolved external symbol MPI_Win_create_dynamic referenced in function PetscSFGetWindow
sfwindow.o : error LNK2019: unresolved external symbol MPI_Win_attach referenced in function PetscSFGetWindow
sfwindow.o : error LNK2019: unresolved external symbol MPI_Win_allocate referenced in function PetscSFGetWindow
C:\Users\rpepper\git\library\tools\windows\petsc\PETSC-~1\ARCH-M~1\lib\libpetsc.dll : fatal error LNK1120: 4 unresolved externals
What is strange is that if I try and compile a test MPI executable, the function MPI_Wtime appears to be present. I assume it's some error in how I'm linking MPI to PETSc but haven't been able to figure out a solution. I've tried using VS2015 and VS2019.
I'm using the following for configure:
./configure --with-debugging=0 \
--with-blaslapack-lib="-L/cygdrive/c/PROGRA~2/INTELS~1/COMPIL~1/windows/mkl/lib/intel64 mkl_intel_lp64_dll.lib mkl_sequential_dll.lib mkl_core_dll.lib" \
--with-cc="win32fe icl" \
--with-cxx="win32fe icl" \
--with-fc=0 \
--with-precision="single" \
--with-mpi-include="/cygdrive/c/PROGRA~2/INTELS~1/COMPIL~1/windows/mpi/intel64/include" \
--with-mpi-lib="/cygdrive/c/PROGRA~2/INTELS~1/COMPIL~1/windows/mpi/intel64/lib/libmpi_ilp64.lib" \
--with-mpiexec="/cygdrive/c/PROGRA~2/INTELS~1/COMPIL~1/windows/mpi/intel64/bin/mpiexec -localonly" \
--prefix="../$PETSC_VERSION-single"
Has anyone run into a similar issue?
Best,
Ryan
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am not exactly sure to build PETS on win, but you may try an additionally to link against mkl_scalapack_lp64_dll.lib mkl_blacs_lp64_dll.lib impi.lib. Please check what the mkl linker will suggest.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks! Adding the lmpi.lib file did indeed fix it
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page