[Numpy-discussion] Python 3 porting
Mon Feb 15 13:19:54 CST 2010
ma, 2010-02-15 kello 21:07 +0200, Stéfan van der Walt kirjoitti:
> After your latest changes, numpy builds on OSX, although importing is
> still broken:
> from . import multiarray
> ImportError: dlopen(/Users/stefan/lib/python3.1/site-packages/numpy/core/multiarray.so,
> 2): Symbol not found: __numpymemoryview_init
> Referenced from:
> Expected in: flat namespace
> in /Users/stefan/lib/python3.1/site-packages/numpy/core/multiarray.so
Oh crap, nothing seems to work for anyone else ;)
> Have you seen this before? Looks like something isn't linked
> properly, but I'm not sure where memoryview would be defined. Is this
> part of the new PEP implementation?
Yep, it's a part of that, but it's only necessary on Python 2.6. The
Memoryview object is a part of Python proper starting from Python 2.7.
It was a huge convenience for the implementation to be able to keep
track of buffers via refcounting, so I backported that bit.
On Python 3.1, the numpymemoryview_init is a stub function that does
nothing. I guess this is another single-file compilation issue -- the
new file should be included in multiarraymodule_onefile.c. Should be
More information about the NumPy-Discussion