Contents

Extending Python with C or code
Introduction
A Simple Example
Intermezzo: Errors and Exceptions
Back to the Example
The Module's Method Table and Initialization Function
Compilation and Linkage
Calling Python Functions From C
Format Strings for PyArg_ParseTuple()
The Py_BuildValue() Function
Reference Counts
Introduction
Reference Counting in Python
Ownership Rules
Thin Ice
NULL Pointers
Writing Extensions in

Embedding Python in another application
Embedding Python in

Dynamic Loading
Configuring and Building the Interpreter for Dynamic Loading
Shared Libraries
SGI IRIX 4 Dynamic Loading
GNU Dynamic Loading
Building a Dynamically Loadable Module
Shared Libraries
SGI IRIX 4 Dynamic Loading
GNU Dynamic Loading