[Trilinos-Users] [EXTERNAL] Makefile: Can't find .so files

Rush, Simon simon.rush at ttu.edu
Mon Sep 5 10:18:22 EDT 2016

Hi Andrew,

       I included your suggested two lines, but unfortunately, ran into the same issues. Here is the output from my make command and the attempt to execute; note the file compiles, it is in trying to run it I get errors.

make command:

/usr/bin/g++ -c -std=c++11 -O3  "-I/usr/local/Trilinos/BUILDS/SERIAL-OPT/include" -I/usr/include -I/usr/local/include -DMYAPP_EPETRA src_file.cpp
/usr/bin/ar cr libmyappLib.a src_file.o
/usr/bin/g++ -std=c++11 -O3  libmyappLib.a -o MyApp.exe -lgfortran "-I/usr/local/Trilinos/BUILDS/SERIAL-OPT/include" -I/usr/include -I/usr/local/include -DMYAPP_EPETRA "-L/usr/local/Trilinos/BUILDS/SERIAL-OPT/lib"  -lpdeopt -lsundanceStdFwk -lsundanceStdMesh -lsundanceCore -lsundanceInterop -lsundanceUtils -lplaya -lnoxepetra -lnoxlapack -lnox -lModeLaplace -lanasaziepetra -lanasazi -lbelosepetra -lbelos -lml -lifpack -lmapvarlib -lfastqlib -lblotlib -lplt -lsvdi_cgi_cps -lvdicps_dual -lvdx11cps -lsvdi_cgi_met -lsvdi_cgi_pst -lsvdi_cgi_x11 -lsvdi_cdr -lsvdi_cgi -lsuplib -lsupes -laprepro_lib -lchaco -lIonit -lIotr -lIohb -lIogn -lIoex -lIoss -lnemesis -lexodus_for -lexodus -lmapvarlib -lfastqlib -lblotlib -lplt -lsvdi_cgi_cps -lvdicps_dual -lvdx11cps -lsvdi_cgi_met -lsvdi_cgi_pst -lsvdi_cgi_x11 -lsvdi_cdr -lsvdi_cgi -lsuplib -lsupes -laprepro_lib -lchaco -lIonit -lIotr -lIohb -lIogn -lIoex -lIoss -lnemesis -lexodus_for -lexodus -lamesos -laztecoo -lepetraext -ltriutils -lepetra -lteuchosremainder -lteuchosnumerics -lteuchoscomm -lteuchosparameterlist -lteuchoscore -lteuchosremainder -lteuchosnumerics -lteuchoscomm -lteuchosparameterlist -lteuchoscore /usr/lib/x86_64-linux-gnu/libX11.so /usr/local/lib/libnetcdf.so /usr/local/lib/liblapack.so /usr/local/lib/libblas.so /usr/lib/x86_64-linux-gnu/libpthread.so


./MyApp.exe: error while loading shared libraries: libteuchoscomm.so.11: cannot open shared object file: No such file or directory

Thanks for y'all's help!

From: Bradley, Andrew Michael <ambradl at sandia.gov>
Sent: Sunday, September 4, 2016 3:30 PM
To: Rush, Simon; trilinos-users at trilinos.org
Subject: Re: [EXTERNAL] [Trilinos-Users] Makefile: Can't find .so files

Hi Simon,

I'm taking a wild guess here. I suspect that for some reason (possibly a bug in the build system?), Trilinos_LIBRARY_DIRS and Trilinos_INCLUDE_DIRS are coming out as having relative, rather than absolute, paths, and these relative paths have nothing to do with your app's location.

As a kludge, try modifying the Makefile like this:

# Add these two extra lines ...
# ... before reaching here.

Here I've assumed MYAPP_TRILINOS_DIR is an installation containing lib/ and include/ directories.

Let us know if this fixes your app's build. Whether or not it does, would you send us the full output of the make command so that we can examine the print_info target's output?



From: Trilinos-Users <trilinos-users-bounces at trilinos.org> on behalf of Rush, Simon <simon.rush at ttu.edu>
Sent: Sunday, September 4, 2016 2:03 PM
To: trilinos-users at trilinos.org
Subject: [EXTERNAL] [Trilinos-Users] Makefile: Can't find .so files


      I'm a grad student working with Trilinos, and I can't get my Makefile to compile a simple program with a few Anasazi header files included. Attached is my Makefile, which I took from https://trilinos.org/oldsite/Export_Makefile_example.txt. Even though I have clearly included Teuchos as a package, and /my_build/lib, I am getting errors about not being able to find .so files that are located at /my_build/lib. Can anyone tell me what I am doing wrong?

Simon Rush
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://trilinos.org/pipermail/trilinos-users/attachments/20160905/b7b214c3/attachment.html>

More information about the Trilinos-Users mailing list