I was building a new version of Spice within an LXC container, mostly for experimentation. However, one strange thing that I encountered was that make install
installed libspice-server.so.1.9.0
into /usr/lib
. The result was a nasty segfault when using the QXL driver because of the fact that libspice-server.so.1.8.0
from the repositories was located in /usr/lib/x86_64-linux-gnu
, which has a higher precedence in ldconfig
. So, it was dynamically linking the older version of the library with the newer code -- no good.
Anyway, this got me thinking: Other than ldconfig
ordering (which I don't think has anything to do with it) is there a functional or philosophical difference between placing a library in /usr/lib
versus placing a library in /usr/lib/{x86_64,i386}-linux-gnu
?
I understand the need for separate /usr/lib/i386-linux-gnu
and /usr/lib/x86_64-linux-gnu
directories due to Debian not utilizing the /usr/lib
/usr/lib32
hierarchy used by some other distros. But, do libraries that are directly in /usr/lib
have some special significance, or it simply for backwards compatibility, perhaps?
/usr/lib
directly belongs to*:amd64
packages (natives packages, I have 64bit installation), I have checked only few, and none has*:i386
package (foreign arch) with same name. So those libraries only exist in native architecture no need to move them into ARCH specific folder. I didn't verify Debian policy yet, that's why I wrote this as a comment till I find a reference. – user.dz Jan 16 '17 at 08:13