My cython module builds fine, but when I try to import it I get the following error:
ImportError: ./pyflite.so: undefined symbol: basic_ff_register
here's my setup.py.
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
ext_modules = [Extension("pyflite",
["pyflite.pyx"],
extra_objects=[
"/usr/local/lib/libflite.a",
"/usr/local/lib/libflite_cmulex.a",
"/usr/local/lib/libflite_usenglish.a",
"/usr/local/lib/libflite_cmu_us_slt.a"])]
setup(
name = 'pyflite',
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules
)
as you can see, since the libs are static, I had to add them to extra_objects
rather than libraries
Here's what's puzzling me:
nm -o --defined-only /usr/local/lib/*.a | grep 'basic_ff_register'
/usr/local/lib/libflite.a:cst_ffeatures.o:00000000000017a0 T basic_ff_register
doesn't that mean that that the function is in libflite.a
which I'm linking with?
Any help would be appreciated,
-Scott