You are not logged in.
Pages: 1
I'm trying to learn Cython. I have just installed the necessary files from the repos.
[1] SOLVED: When I gcc the c file that is generated by cython, I get an error,
fatal error: Python.h: No file or directory
Compilation terminated.
What do I do? I find Python.h resides in /usr/include/Python2.7. How do I tell gcc this?
[2] Does anyone know any good tutorials for cython besides those on the official website?
Last edited by anirudh215 (2011-06-27 14:37:31)
Offline
note that Arch uses python3 by default. you might have to point it to python2 in order to get it working.
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Okay. That's resolved. I've edited the original post. Only above question [2] left.
Offline
I've edited the original post.
No. Don't do that !!
The replies in the thread look out of place and makes the thread look half-assed. Please do not edit your posts in that manner.
EDIT : Great now you edited and put back the 1st question -- making this reply look out of place.
Geez !! Anyway, moving along.
Last edited by Inxsible (2011-06-27 14:39:52)
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Haha. When I began to edit the first post, you hadn't posted as yet. When I was done, I saw your reply, and then told myself the same thing you did, BEFORE you did. ![]()
Offline
Whitie
Offline
note that Arch uses python3 by default. you might have to point it to python2 in order to get it working.
Cython can generate python 2 or 3 code, regardless of whether it's run on python 2 or 3.
@OP: If you're looking for an example, here's a Cython binding for my C raytracer I'm writing: http://gitorious.org/dimension/dimensio … ension.pyx
Offline
Thanks tavianator!
Offline
Pages: 1