A static library, also known as an archive, is one intended to be statically linked. Originally, only static libraries existed. Static linking must be performed when any modules are recompiled. (From the Wikipedia article on libraries (computing).)
When did operating systems transition from static libraries to dynamic libraries? Particularly interested in Unix and MS-DOS / Windows.
When using a GCC front-end with the
libfoo.a are searched for. If only one of these are in the search path it will select that, but if it finds both in the same search directory, it will prefer
libfoo.so. Was this always the case, or was there a time when
libfoo.a would have been the default if both were present?
Most modern operating systems can have shared library files of the same format as the executable files. This offers two main advantages: first, it requires making only one loader for both of them, rather than two (having the single loader is considered well worth its added complexity). Secondly, it allows the executables also to be used as shared libraries, if they have a symbol table. Typical combined executable and shared library formats are ELF and Mach-O (both in Unix) and PE (Windows). (From the Wikipedia article on libraries (computing).)
Was the change from static libraries to combined executable and shared libraries for Unix and Windows always like this, or was there a time when shared libraries were distinct from executables?