I am clearly missing something very obvious but why does this happily compile:
%cython cdef extern from "mpfr.h": ctypedef void* mpfr_t[1] cdef int mpfr_init(mpfr_t) cdef int mpfr_clear(mpfr_t) def testmpfr(double x): cdef mpfr_t input mpfr_init(input) mpfr_clear(input) But this doesn't: %cython cdef extern from "mpfr.h": ctypedef void* mpfr_t[1] cdef extern from "mpc.h": ctypedef void* mpc_t ctypedef struct __mpc_struct: mpfr_t re mpfr_t im ctypedef __mpc_struct* mpc_t void mpc_init (mpc_t) void mpc_clear (mpc_t) def testmpc(): cdef mpc_t input mpc_init(input) mpc_clear(input) This is the error message: Traceback (click to the left of this block for traceback) ... ImportError: /home/martin/.sage//temp/Office/7219//spyx// _home_martin__sage_sage_note\ book_sagenb_home_admin_24_code_sage73_spyx/ _home_martin__sage_sage_noteb\ ook_sagenb_home_admin_24_code_sage73_spyx_0.so: undefined symbol: mpc_clear The optional package mpc is installed and the MPComplex module works fine. -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org