I m 利用海合会从一组C++源文档中建立共同物体档案。 所有关于建筑设计的示意图(.so
的档案都显示在后编印的编号。 例如:
gcc -shared -Wl,-soname,libmean.so.1 -o libmean.so.1.0.1 calc_mean.o
这将产生<代码>。
Additionally, if I browse the /usr/lib
directory on my local machine, I see that many of the .so
files have version numbers at the end.
However, when I compile a shared object file and place it in /usr/lib
, the linker is unable to find it if I put a version number at the end. If I remove the version number, it works fine. I really don t care about putting a version number or not, I just don t understand why this seems to be a common convention, and yet this causes the shared library to not work with the linker. So, what s going on here? Why is there a convention to place the version number at the end of an .so
file name?