Hello,
I have a solver library (in shared format, let's say libmylib.so) that I
would like to link to deal.II. In order to do this, I checked how the METIS
library is added to libdeal_II and tried to do the same for my library,
thus I added the files configure_my_lib.cmake and FindMylib.cmake under
cmake/configure and cmake/modules, respectively.
Strange thing is that in the output of build/CMakeCache.out I find:
DEAL_II_WITH_MYLIB:BOOL=ON
MYLIB_DIR:PATH=/marconi/home/userexternal/vpaludet/projects/mylib
MYLIB_INCLUDE_DIR:PATH=/marconi/home/userexternal/vpaludet/projects/mylib/include
MYLIB_LIBRARY:FILEPATH=/marconi/home/userexternal/vpaludet/projects/mylib/lib/libmylib.so
deal_II_LIB_DEPENDS:STATIC=general;/cineca/prod/opt/libraries/lapack/3.6.1/intel--pe-xe-2017--binary/lib/liblapack.a;general;/cineca/prod/\
opt/libraries/blas/3.6.0/intel--pe-xe-2017--binary/lib/libblas.a;general;imf;general;m;general;ipgo;general;irc;general;pthread;general;sv\
ml;general;irc_s;general;c;general;dl;general;/lib64/libz.so;general;/marconi/home/userexternal/vpaludet/projects/mylib/lib/libmylib.so
\
;general;/marconi/home/userexternal/vpaludet/lib/libmetis.so;general;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--\
binary/lib/libboost_iostreams.so;general;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--binary/lib/libboost_serialization.so;gene\
ral;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--binary/lib/libboost_system.so;general;/cineca/prod/opt/libraries/boost/1.61.0/\
intelmpi--2017--binary/lib/libboost_thread.so;general;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--binary/lib/libboost_regex.so\
;general;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--binary/lib/libboost_chrono.so;general;/cineca/prod/opt/libraries/boost/1.\
61.0/intelmpi--2017--binary/lib/libboost_date_time.so;general;/cineca/prod/opt/libraries/boost/1.61.0/intelmpi--2017--binary/lib/libboost_\
atomic.so
However, when I run "ldd build/lib/libdeal_II.so" I get:
linux-vdso.so.1 => (0x00007ffcbc1f5000)
libimf.so =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/lib/intel64/libimf.so
(0x00007f4e5fd11000)
libirc.so =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/lib/intel64/libirc.so
(0x00007f4e5faa7000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f4e5f874000)
libsvml.so =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/lib/intel64/libsvml.so
(0x00007f4e5e95b000)
libc.so.6 => /lib64/libc.so.6 (0x00007f4e5e598000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007f4e5e394000)
libz.so.1 => /lib64/libz.so.1 (0x00007f4e5e17e000)
libmetis.so => /marconi/home/userexternal/vpaludet/lib/libmetis.so
(0x00007f4e5dec4000)
libstdc++.so.6 =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/inspector/lib64/libstdc++.so.6
(0x00007f4e5dba5000)
libgcc_s.so.1 =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/inspector/lib64/libgcc_s.so.1
(0x00007f4e5d98e000)
libintlc.so.5 =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/lib/intel64/libintlc.so.5
(0x00007f4e5d722000)
/lib64/ld-linux-x86-64.so.2 (0x00007f4e670df000)
libm.so.6 => /lib64/libm.so.6 (0x00007f4e5d420000)
libmpifort.so.12 =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/impi/2017.3.196/lib64/libmpifort.so.12
(0x00007f4e5d076000)
libmpi.so.12 =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/impi/2017.3.196/lib64/libmpi.so.12
(0x00007f4e5c34e000)
librt.so.1 => /lib64/librt.so.1 (0x00007f4e5c146000)
libirng.so =>
/cineca/prod/opt/compilers/intel/pe-xe-2017/binary/lib/intel64/libirng.so
(0x00007f4e5bdd0000)
and I don't see my library there. On the other hand, If I try to compile an
executable, let's say step-3, and run ldd on it I see that it's linked to
libdeal_II.so and also libmylib.so. My question is why my library can be
seen only by the executable and not by libdeal_II.
Thank you for helping and I'm sorry if I didn't provide enough details
about this problem. Let me know if you need more data :)
Best!!
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see
https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.