...cmdclass = {}if use_cython:SRC = 'foo.pyx'cmdclass['build_ext'] = build_extelse:SRC = 'foo.cpp'...ext = Extension('plow.client.plow',[SRC],language="c++",libraries=[...],extra_compile_args=cflags,extra_link_args=ldflags,define_macros=[...])...setup(...ext_modules = [ext],cmdclass=cmdclass,...)
Thanks for the reply!
It would be the apple python 2.7.x that ships with 10.8
Cython is doing the right thing in terms of cythonizing the file, but without delving into the source I had assumed the custom Extension class that is being used from cython was doing something wrong. I figured it was ignoring that language=c++ flag and returning the wrong output source type to be compiled?
The reason it works with the workaround is that I don't let the cython Extension handle the conversion. I just explicitly tell it to use the pregenerated .cpp source. At that point the right gcc command is used.
You are correct that when it fails under the normal cythonizing approach, it does not get to the linker step with g++. That is because it failed at the first gcc compile of the cythonized source file, which it thinks should be a .c file and not .cpp
--
---
You received this message because you are subscribed to a topic in the Google Groups "cython-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/cython-users/6TPt_q9DS5I/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to cython-users...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.