Executive Summary

Executive Summary

"Don't keep doing what doesn't work" -- Anonymous

"Keep it simple stupid" -- Anonymous

SWIG is an interface compiler that connects programs written in C, C++, and Objective-C with scripting languages including Perl, Python, and Tcl/Tk. It works by taking the declarations commonly found in C/C++ header files and using them to generate the glue code (wrappers) that scripting languages need to access the underlying C/C++ code.

John Ousterhout has written an excellent paper that describes the benefits of scripting languages. SWIG makes it even easier to use scripting languages by automating the process of connecting scripting languages to C/C++ code.

SWIG is used in a number of ways:

SWIG is sometimes compared to other scripting language extension building tools and compilers for interface definition languages (IDL) such as CORBA IDL. However, SWIG has a number of distinguishing features.

A number of papers and tutorials describing SWIG are available. You can also view a simple tutorial to see an example of SWIG in action.

Find out who is using SWIG and what they said about it (from the March, 1998 user survey).