-
127
pages
-
English
-
Documents
Description
Interfacing C/C++ and Python with SWIG
David M. Beazley
Department of Computer Science
University of Utah
Salt Lake City, Utah 84112
beazley@cs.utah.edu
1SWIG Tutorial 6th International Python Conference
Prerequisites
C/C++ programming
• You’ve written a C program.
• You’ve written a Makefile.
• You know how to use the compiler and linker.
Python programming
• You’ve heard of Python.
• You’ve hopefully written a few Python programs.
Optional, but useful
• Some knowledge of the Python C API.
• C++ programming experience.
Intended Audience
This tutorial is aimed at C/C++ application developers who are interested in using
Python as an interface (I am one of these developers).
2SWIG Tutorial 6th International Python Conference
Notes
C/C++ Programming
The good
• High performance.
• Low-level systems programming.
• Available everywhere and reasonably well standardized
The bad
• The compile/debug/nap development cycle.
• Difficulty of extending and modifying.
• Non-interactive.
The ugly
• Writing user-interfaces.
• Writing graphical user-interfaces (worse).
• High level programming (“claims” about C++ are questionable).
• Trying to glue different “components” together (i.e. reuse).
3SWIG Tutorial 6th International Python Conference
Notes
What Python Brings to C/C++
An interpreted high-level programming environment
• Flexibility.
• Interactivity.
• Scripting.
• Debugging.
• Testing
• Rapid prototyping.
Component gluing
• A common ...
-
Publié par
-
Langue
English