[Numpy-discussion] 20.1.0 undefined symbol: PyArray_API

Mike Romberg romberg at fsl.noaa.gov
Fri Jul 20 17:02:20 CDT 2001

  I have written a python module in C which is implemented as a
loadable shared library.  My module uses Numeric array objects and
includes arrayobject.h.  With Numeric-19 this used to work fine.  Now
my module will not load because the symbol PyArray_API is not found.

  I located this fellow in the arrayobject header file:

/* C API address pointer */
#if defined(NO_IMPORT) || defined(NO_IMPORT_UFUNC)
extern void **PyUFunc_API;
void **PyUFunc_API;
static void **PyUFunc_API;

  So, it seems (at first glance) that this symbol is either static or
extern based on the NO_IMPORT macro.  My question is, can I just
define NO_IMPORT before including arrayobject.h or does Numeric python
need to be rebuilt so that this symbol gets exported?


Mike Romberg (romberg at fsl.noaa.gov)

More information about the Numpy-discussion mailing list