cb46869c1e
The cElementTree module is a C implementation of the ElementTree API, optimized for fast parsing and low memory use. On typical documents, cElementTree is 15-20 times faster than the Python version of ElementTree, and uses 2-5 times less memory. On modern hardware, that means that documents in the 50-100 megabyte range can be manipulated in memory, and that documents in the 0-1 megabyte range load in zero time (0.0 seconds). This allows you to drastically simplify many kinds of XML applications.
24 lines
569 B
Python
24 lines
569 B
Python
# $NetBSD: setup.py,v 1.1.1.1 2010/04/11 12:41:45 obache Exp $
|
|
|
|
import distutils
|
|
from distutils.core import setup, Extension
|
|
|
|
expatprefix = '@EXPATPREFIX@'
|
|
expatincl = expatprefix + '/include'
|
|
expatlib = expatprefix + '/lib'
|
|
expatrtprefix = '@EXPATPREFIX@'
|
|
expatrtlib = expatrtprefix + '/lib'
|
|
|
|
setup(
|
|
ext_modules = [
|
|
Extension(
|
|
'_elementtree',
|
|
['Modules/_elementtree.c'],
|
|
define_macros=[('USE_EXPAT', None)],
|
|
include_dirs=[expatincl],
|
|
library_dirs=[expatlib],
|
|
runtime_library_dirs=[expatrtlib],
|
|
libraries=['expat']
|
|
)
|
|
]
|
|
)
|