diff options
author | Gaëtan de Menten <gdementen@gmail.com> | 2010-02-13 22:53:39 +0000 |
---|---|---|
committer | Gaëtan de Menten <gdementen@gmail.com> | 2010-02-13 22:53:39 +0000 |
commit | 165609a190665f5453417c9c935a834714c7f5a5 (patch) | |
tree | 90d3d0da3f233cf6fc211f367eea0dba661b098e /setup.py | |
parent | f2974ef3993e02646a2dfade5feb74afb78f370f (diff) | |
download | sqlalchemy-165609a190665f5453417c9c935a834714c7f5a5.tar.gz |
- Added an optional C extension to speed up the sql layer by
reimplementing the highest impact functions.
The actual speedups will depend heavily on your DBAPI and
the mix of datatypes used in your tables, and can vary from
a 50% improvement to more than 200%. It also provides a modest
(~20%) indirect improvement to ORM speed for large queries.
Note that it is *not* built/installed by default.
See README for installation instructions.
- The most common result processors conversion function were
moved to the new "processors" module. Dialect authors are
encouraged to use those functions whenever they correspond
to their needs instead of implementing custom ones.
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -15,9 +15,11 @@ if sys.version_info >= (3, 0): ) try: - from setuptools import setup + from setuptools import setup, Extension except ImportError: - from distutils.core import setup + from distutils.core import setup, Extension + +BUILD_CEXTENSIONS = False def find_packages(dir_): packages = [] @@ -46,6 +48,12 @@ setup(name = "SQLAlchemy", license = "MIT License", tests_require = ['nose >= 0.10'], test_suite = "nose.collector", + ext_modules = (BUILD_CEXTENSIONS and + [Extension('sqlalchemy.cprocessors', + sources=['lib/sqlalchemy/cextension/processors.c']), + Extension('sqlalchemy.cresultproxy', + sources=['lib/sqlalchemy/cextension/resultproxy.c']) + ]), entry_points = { 'nose.plugins.0.10': [ 'sqlalchemy = sqlalchemy.test.noseplugin:NoseSQLAlchemy', |