Libraries, Shared Libraries, and Dynamic Loading, January 21, 2002 19
[email protected]
Wrapper Code and Shared Libraries
Decoupled libraries
• In applications, it is often useful to decouple scripting wrappers and libraries
• This can be done using shared libraries as before
• Allows program libraries to be used independently of the Python interface
• Python is incorporated as an optional enhancement
• Allows libraries to be used in other settings (CORBA, COM, Tcl, Perl, etc.).
Critical point
• The shared library libvis.so is the component
• Python wrappers are just wrappers (i.e., not the component).
python
vismodule.so
libvis.so
import
ld ... -lvis
a.out
Stand-alone non-Python application
wrappers
library