Linking a shared library to another shared library

Just as you link modules into an application, you can create dependencies between shared libraries by linking them together. For example:

xlc -qmkshrobj -o mylib.so myfile.o -Ldirectory -Rdirectory -lfoo