<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi, <div class=""> </div><div class=""> I have compile petsc on my Ubuntu machine (also Mac OS 10.12 separately) to link to the system lapack and blas libraries (shown below). </div><div class=""><br class=""></div><div class=""> I have created an interface class to dgeev in lapack to calculate the eigenvalues of a matrix. </div><div class=""><br class=""></div><div class=""> My application code links to multiple libraries: libMesh, petsc, slepc, hdf5, etc. </div><div class=""><br class=""></div><div class=""> If I test my interface inside this application code, I get junk results. </div><div class=""><br class=""></div><div class=""> However, on the same machine, if I use the interface in a separate main() function without linking to any of the libraries except lapack and blas, then I get expected results. </div><div class=""><br class=""></div><div class=""> Also, this problem does not show up on Mac. </div><div class=""><br class=""></div><div class=""> I am not sure what could be causing this and don’t quite know where to start. Could Petsc have anything to do with this? </div><div class=""><br class=""></div><div class=""> Any insight would be greatly appreciated. </div><div class=""><br class=""></div><div class="">Regards,</div><div class="">Manav</div><div class=""><br class=""></div><div class=""><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures; color: #34bc26" class="">manav@manav1</span><span style="font-variant-ligatures: no-common-ligatures" class="">:</span><span style="font-variant-ligatures: no-common-ligatures; color: #5230e1" class="">~/test</span><span style="font-variant-ligatures: no-common-ligatures" class="">$ ldd /opt/local/lib/libpetsc.so</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>linux-vdso.so.1 => (0x00007fff3e7a8000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libsuperlu_dist.so.5 => /opt/local/lib/libsuperlu_dist.so.5 (0x00007f721fbd1000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libparmetis.so => /opt/local/lib/libparmetis.so (0x00007f721f990000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libmetis.so => /opt/local/lib/libmetis.so (0x00007f721f718000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libsuperlu.so.5 => /opt/local/lib/libsuperlu.so.5 (0x00007f721f4a7000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f721f124000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>liblapack.so.3 => /usr/lib/liblapack.so.3 (0x00007f721e92c000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libblas.so.3 => /usr/lib/libblas.so.3 (0x00007f721e6bd000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f721e382000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f721e079000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libmpi_mpifh.so.12 => /usr/lib/libmpi_mpifh.so.12 (0x00007f721de20000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libgfortran.so.3 => /usr/lib/x86_64-linux-gnu/libgfortran.so.3 (0x00007f721daf4000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f721d8f0000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libmpi.so.12 => /usr/lib/libmpi.so.12 (0x00007f721d61a000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f721d403000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f721d1e6000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f721ce1d000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>/lib64/ld-linux-x86-64.so.2 (0x000055d739f1b000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f721cbcf000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libopen-pal.so.13 => /usr/lib/libopen-pal.so.13 (0x00007f721c932000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libquadmath.so.0 => /usr/lib/x86_64-linux-gnu/libquadmath.so.0 (0x00007f721c6f2000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libibverbs.so.1 => /usr/lib/libibverbs.so.1 (0x00007f721c4e3000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libopen-rte.so.12 => /usr/lib/libopen-rte.so.12 (0x00007f721c269000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f721c064000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f721be5e000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f721bc56000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007f721ba52000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libhwloc.so.5 => /usr/lib/x86_64-linux-gnu/libhwloc.so.5 (0x00007f721b818000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libnuma.so.1 => /usr/lib/x86_64-linux-gnu/libnuma.so.1 (0x00007f721b60c000)</span></div><div style="margin: 0px; line-height: normal; font-family: Monaco; color: rgb(244, 244, 244); background-color: rgba(0, 0, 0, 0.85098);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><span class="Apple-tab-span" style="white-space:pre"> </span>libltdl.so.7 => /usr/lib/x86_64-linux-gnu/libltdl.so.7 (0x00007f721b402000)</span></div></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><br class=""></span></div></body></html>