<div dir="ltr">Dear petsc users,<div><br></div><div>I have been trying to use use PETSC on my project on windows. I have followed all steps and compiled petsc on windows using cygwin and cmake. Then I included it on my visual studio project with all other dependencies. After fixing several errors I got stuck with this one:</div><div><div><br></div><div>Error<span class="" style="white-space:pre">   </span>1<span class="" style="white-space:pre"> </span> error LNK2019: unresolved external symbol __imp_GetUserNameA referenced in function PetscGetUserName<span class="" style="white-space:pre">     </span>libpetsc.lib(fuser.o)<span class="" style="white-space:pre">     </span></div></div><div><br></div><div>Anyone has any Idea of which library I should include to solve such problem? </div><div><br></div><div>I am using windows 8 machine with visual studio 2013 and Intel fortran 2013, MS MPI, metis, parmetis, and mkl. All libraries are compiled to x64 and the platform on the VS project was set to x64. I have also activated the use of common windows libraries on the VS project to solve other problems. This is the configure I used:</div><div><br></div><div><div>./configure --with-cc='win32fe cl' --with-fc='win32fe ifort' --prefix=/cygdrive/c/Installed/petsc-opt/ --PETSC_ARCH=windows-intel-opt --with-parmetis=1 --with-parmetis-include=/cygdrive/c/Installed/Parmetis/include_all/ --with-parmetis-lib=\[/cygdrive/c/Installed/Parmetis/lib/parmetis.lib\] --with-metis=1 --with-metis-include=/cygdrive/c/Installed/Parmetis/include_all/ --with-metis-lib=\[/cygdrive/c/Installed/Parmetis/lib/metis.lib\] --with-mpi-include=[/cygdrive/c/Installed/MPI/Include/,/cygdrive/c/Installed/MPI/Include/x64/] --with-mpi-lib=[/cygdrive/c/Installed/MPI/Lib/x64/msmpi.lib,/cygdrive/c/Installed/MPI/Lib/x64/msmpifec.lib] --with-blas-lapack-lib=[/cygdrive/c/Installed/mkl/lib/intel64/mkl_intel_lp64.lib,/cygdrive/c/Installed/mkl/lib/intel64/mkl_core.lib,/cygdrive/c/Installed/mkl/lib/intel64/mkl_sequential.lib] --with-scalapack-include=/cygdrive/c/Installed/mkl/include --with-scalapack-lib=[/cygdrive/c/Installed/mkl/lib/intel64/mkl_scalapack_lp64.lib,/cygdrive/c/Installed/mkl/lib/intel64/mkl_blacs_msmpi_lp64.lib] --with-fortran-interfaces=1 --with-debugging=0</div></div><div><br></div><div>regards,</div></div>