Skip to content

Commit

Permalink
Add support for Python 3.2:
Browse files Browse the repository at this point in the history
- Move ``_pickle.c`` -> ``_pickle_33.c``.

- Clone Python 3.2.3's ``_pickle.c`` -> ``_pickle_32.c`` and apply the
  same patch.

- Choose between them at build time based on ``sys.version_info``.

- Disable some tests of 3.3-only features.
  • Loading branch information
tseaver committed Mar 2, 2013
1 parent 3b18fa5 commit 3404fc8
Show file tree
Hide file tree
Showing 7 changed files with 6,491 additions and 4 deletions.
11 changes: 11 additions & 0 deletions CHANGES.txt
Expand Up @@ -4,6 +4,17 @@ CHANGES
0.1.0 (unreleased)
------------------

- Add support for Python 3.2:

- Move ``_pickle.c`` -> ``_pickle_33.c``.

- Clone Python 3.2.3's ``_pickle.c`` -> ``_pickle_32.c`` and apply the
same patch.

- Choose between them at build time based on ``sys.version_info``.

- Disable some tests of 3.3-only features.

- Initial release of Python 3.3's pickle with the patches of Python Issue
6784[1] applied.

Expand Down
8 changes: 7 additions & 1 deletion setup.py
Expand Up @@ -23,6 +23,11 @@
+ '\n\n' +
open(os.path.join(here, 'CHANGES.txt')).read())

if sys.version_info[:2] == (3, 2):
EXT = 'src/zodbpickle/_pickle_32.c'
else:
EXT = 'src/zodbpickle/_pickle_33.c'

setup(
name='zodbpickle',
version='0.1.0',
Expand All @@ -38,6 +43,7 @@
'License :: OSI Approved :: Python Software Foundation License',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: Implementation :: CPython',
'Framework :: ZODB',
Expand All @@ -51,7 +57,7 @@
package_dir = {'':'src'},
ext_modules = [
Extension(name='zodbpickle._pickle',
sources=['src/zodbpickle/_pickle.c'])
sources=[EXT])
],
extras_require = {
'test': (),
Expand Down

0 comments on commit 3404fc8

Please sign in to comment.