= Software library
A <software library> is reusable code exposed through an interface for other <computer programs> to call. It can supply operations such as <sorting>, text decoding or solving a <linear system>. Clients depend on the interface and its behavioral contract rather than having to copy the implementation.
A compiled <software library> can be linked into a <computer program> or supplied as a shared component loaded for execution. CMake distinguishes static, shared and other library targets in a build description.<cmake-buildsystem in the CMake documentation>[Binary Targets, Static Libraries and Shared Libraries]{ref} For example, two applications can call the same numerical routine with different <arrays>. Reusing the implementation saves duplication, while both callers must still satisfy its dimension, precision and error-handling requirements. A <software package> is a distribution unit and can contain several <software libraries>.
Back to article page