How do I prevent linking "directly" to a shared library name? I have this problem with some shared libs like openssl when I try to link to the soname but still end up linking to the shared lib name. eg
I have in /usr/lib...
libssl.so -> libssl.so.0
libssl.so.0 -> libssl.so.0.9.6
libssl.so.0.9.6
And when I try to link to libssl.so...
gcc foo.c -lssl -o foo
I would expect 'ldd foo' to give...
libssl.so.0 => /usr/lib/libssl.so.0.9.6 (0x40016000)
...
blah blah
But what I end up with is...
libssl.so.0.9.6 => /usr/lib/libssl.so.0.9.6 (0x40016000)
^^^^^^^^^
...
blah blah
How do I prevent this? Also some software seem to link to a
specific version of libc. So when I upgrade my libc, things start
breaking.
I've been on Linux for abt a year and I like everything abt it...
except the dependency hell
. It's really annoying to have to rebuild packages whenever system packages change. In general, how do most ppl manage these dependencies issues or are rebuilds regarded as a way of life in the Linux world?