[Numpy-discussion] Cython question
Charles R Harris
Thu Feb 9 10:05:14 CST 2012
On Thu, Feb 9, 2012 at 8:35 AM, mark florisson <firstname.lastname@example.org>wrote:
> On 9 February 2012 15:29, Charles R Harris <email@example.com>
> > Hi All,
> > Does anyone know how to make Cython emit a C macro? I would like to be
> > to
> > #define NO_DEPRECATED_API
> > and can do so by including a header file or futzing with the generator
> > script, but I was wondering if there was an easy way to do it in Cython.
> > Chuck
> > _______________________________________________
> > NumPy-Discussion mailing list
> > NumPy-Discussion@scipy.org
> > http://mail.scipy.org/mailman/listinfo/numpy-discussion
> Best way is probably to include a C header file (cdef extern from
> "myheader.h": pass), or define the macro with the 'define_macros'
> argument to distutils' Extension. There are other tricks but they are
> more hacks than anything else.
The header file looks like the cleanest way to do this. I'll put one in the
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion