Personal tools
You are here: Home log python csv from python2.3 for python2.2
Document Actions

csv from python2.3 for python2.2

how to get the csv of 2.3 to work in 2.2

csv is a separate module in 2.2, but becomes a built-in module for 2.3. But csv of 2.2 missed lots of functions i.e. reader, writer..., almost totally different from 2.3.

Luckily _csv.c from python 2.3 is backward compatible to python2.2.

  • get python2.3 source code from python.org
  • get _csv.c and csv.py by 'find ./ -name csv' within python2.3 source code directory
  • 'gcc -O2 -fPIC -I/usr/include/python2.2 -c ./Modules/_csv.c -o _csv.o'
  • 'gcc -O2 -shared -fPIC _csv.o -o _csv.so'
  • copy _csv.so and csv.py to a directory exported in PYTHONPATH
« November 2009 »
Su Mo Tu We Th Fr Sa
1234567
89101112 1314
1516171819 20 21
22232425262728
2930
 

Powered by Plone CMS, the Open Source Content Management System

This site conforms to the following standards: