For faster navigation, this Iframe is preloading the Wikiwand page for soname.

soname

This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed.Find sources: "Soname" – news · newspapers · books · scholar · JSTOR (July 2014) (Learn how and when to remove this message)

In Unix and Unix-like operating systems, a soname is a field of data in a shared object file.[1] The soname is a string, which is used as a "logical name" describing the functionality of the object. Typically, that name is equal to the filename of the library, or to a prefix thereof, e.g. libc.so.6.

Name

[edit]

The soname is often used to provide version backwards-compatibility information.[2] For instance, if versions 1.0 through 1.9 of the shared library "libx" provide identical interfaces, they would all have the same soname, e.g. "libx.so.1". If the system only includes version 1.3 of that shared object, with filename "libx.so.1.3", the soname field of the shared object tells the system that it can be used to fill the dependency for a binary which was originally compiled using version 1.2.[3]

If the application binary interface of a library changes in a backward-incompatible way, the soname would be "bumped" or incremented, e.g. from "libx.so.1" to "libx.so.2".

The GNU linker uses the -hname or -soname=name command-line options to specify the library name field. Internally, the linker will create a DT_SONAME field and populate it with name.

Given any shared object file, one can use the following command to get the information from within the library file using objdump:

$ objdump -p libx.so.1.3 | grep SONAME
  SONAME     libx.so.1

See also

[edit]

References

[edit]
  1. ^ Wheeler, David (2003-04-11). "Program Library HOWTO". tldp.org. Retrieved 2021-01-04.
  2. ^ Staerk, Thorsten (2011-03-25). "Library-related Commands and Files: soname". LinuxQuestions.org. Retrieved 2018-02-07.
  3. ^ Bansal, Ashish (2001-04-01). "Shared objects for the object disoriented: How to write dynamically loadable libraries". IBM DeveloperWorks. Retrieved 2018-02-07.
{{bottomLinkPreText}} {{bottomLinkText}}
soname
Listen to this article

This browser is not supported by Wikiwand :(
Wikiwand requires a browser with modern capabilities in order to provide you with the best reading experience.
Please download and use one of the following browsers:

This article was just edited, click to reload
This article has been deleted on Wikipedia (Why?)

Back to homepage

Please click Add in the dialog above
Please click Allow in the top-left corner,
then click Install Now in the dialog
Please click Open in the download dialog,
then click Install
Please click the "Downloads" icon in the Safari toolbar, open the first download in the list,
then click Install
{{::$root.activation.text}}

Install Wikiwand

Install on Chrome Install on Firefox
Don't forget to rate us

Tell your friends about Wikiwand!

Gmail Facebook Twitter Link

Enjoying Wikiwand?

Tell your friends and spread the love:
Share on Gmail Share on Facebook Share on Twitter Share on Buffer

Our magic isn't perfect

You can help our automatic cover photo selection by reporting an unsuitable photo.

This photo is visually disturbing This photo is not a good choice

Thank you for helping!


Your input will affect cover photo selection, along with input from other users.

X

Get ready for Wikiwand 2.0 🎉! the new version arrives on September 1st! Don't want to wait?