python-cython C++ support patch

Marco Atzeri marco.atzeri@gmail.com
Sun Jan 31 04:43:06 GMT 2021


On 31.01.2021 04:53, Masamichi Hosoda wrote:

> python38-cython-0.29.21-3 works fine with following test code.
> 
> ```hello.pyx
> print('Hello World!')
> ```
> 
> ```setup.py
> from distutils.core import setup
> from Cython.Build import cythonize
> 
> setup(
>      ext_modules=cythonize(
>          "hello.pyx",
>          language="c++",
>      )
> )
> ```
> 
> ```test.py
> import hello
> ```
> 
> Here's the result by python38-cython-0.29.21-2 (failed).
> 
> ```
> $ python setup.py build_ext --inplace
> [...snip...]
> $ python test.py
> Traceback (most recent call last):
>    File "test.py", line 1, in <module>
>      import hello
> ImportError: dynamic module does not define module export function (PyInit_hello)
> ```
> 
> Here's the result by python38-cython-0.29.21-3 (succeeded).
> 
> ```
> $ python setup.py build_ext --inplace
> [...snip...]
> $ python test.py
> Hello World!
> ```
> 
> Thanks.

Thanks to you

I still think that the change you proposed should go upstream.

Have you tested your example on a NOT cygwin system ?

Regards
Marco




More information about the Cygwin mailing list