- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We are using icpc to dynamically link to an oracle library as follows (in suse linux 11.4)
icpc -shared -m64 -static-intel -Wl,--version-script .... (object list) ... -L/home/oracle/app/oracle/product/12.1.0/dbhome_1/lib -lclntsh
In the directory /home/oracle/app/oracle/product/12.1.0/dbhome_1/lib, we have the symbolic link:
lrwxrwxrwx 1 oracle oinstall 69 May 8 2017 libclntsh.so -> /home/oracle/app/oracle/product/12.1.0/dbhome_1/lib/libclntsh.so.12.1
We assume that this link will produce a library which will dependant on libclntsh.so . But the resulted library is dependent on libclntsh.so.12.1, which is the symolic linked library. This causes our library not to be version in dependent.
Please advise.
Thanks in advanced
- Tags:
- CC++
- Development Tools
- Intel® C++ Compiler
- Intel® Parallel Studio XE
- Intel® System Studio
- Optimization
- Parallel Computing
- Vectorization
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
The ldd shows a dependency on libclntsh.so.12.1. I did some more research. This is the problem with Oracle library. There are 2 ways to ship a library that support older version linking:
a/ make sure when you create the library , the SONAME is non version (objdump -x lib.so | grep SONAME). The SONAME of the library will be used to stored the dependency when another shared library is built using your lib. Thus Mutilple version of a shared lirary can have the same SONAME, allowing a shared library to be backward compatible.
b/ Or you use the same name with the version as the SONAME (default) . In this case libclntsh.so.12.1. However, you product when installed need to make a link to from this to the latest library that you ship (libclntsh.so.18.1) to allow backward compatible.
Oracle chose the approach b/, but the install has problem creating the link to the old version causing my problem.
With this, I will close this question. Thx
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What ldd on this library print?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
The ldd shows a dependency on libclntsh.so.12.1. I did some more research. This is the problem with Oracle library. There are 2 ways to ship a library that support older version linking:
a/ make sure when you create the library , the SONAME is non version (objdump -x lib.so | grep SONAME). The SONAME of the library will be used to stored the dependency when another shared library is built using your lib. Thus Mutilple version of a shared lirary can have the same SONAME, allowing a shared library to be backward compatible.
b/ Or you use the same name with the version as the SONAME (default) . In this case libclntsh.so.12.1. However, you product when installed need to make a link to from this to the latest library that you ship (libclntsh.so.18.1) to allow backward compatible.
Oracle chose the approach b/, but the install has problem creating the link to the old version causing my problem.
With this, I will close this question. Thx

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page