This howto explains how to use the dlopen API from C++ and how it can be used to load classes dynamically.
HTML Docbook Source