The Interix Software Development Kit (SDK) supports shared (or dynamically linked) libraries. Dynamic linking is supported through standard calls, such as dlopen(). Dynamically linked applications and shared libraries can only be created using gcc(1) and the other GNU compiler tools. However, cc(1) and c89(1) will still produce statically linked binaries.
New dynamic shared libraries, such as libc.so and libm.so, are in /usr/lib. Libraries, such as libX11.so and libXt.so, are in /usr/X11R5/lib.
The Interix SDK also includes a command called liblock(1), which locks a library to prevent linking from using a library. If any process attempts to link using a locked library, the ld(1) command reports a fatal error. There is no tool provided to unlock a library that has been locked using liblock. The locking is not invulnerable and should not be regarded as a high-security option.
The synopsis is:
liblock lib.so
You can use the Interix SDK to create real, UNIX-style .so libraries. Although similar to Windows dynamic-link libraries (DLLs), they are not the same in implementation or semantics.
With the Interix SDK, you can also create Position Independent Code (PIC); however, this is not encouraged. Although PIC code is faster at run-time, the benefits gained are small compared to the high degree of its complexity.
This section covers: