Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Not compatible with cython 0.13. "bool" type identifier #5

Closed
jason-ni opened this Issue Aug 4, 2011 · 3 comments

Comments

Projects
None yet
2 participants

jason-ni commented Aug 4, 2011

running build
running build_py
running build_ext
cythoning _py4s.pyx to _py4s.c

Error compiling Cython file:

...
cdef class _Cursor:
cdef py4s.fsp_link *_link
cdef py4s.fs_query_state *_qs
cdef py4s.fs_query *_qr
cdef char *_query
cdef bool _transaction

^

_py4s.pyx:107:9: 'bool' is not a type identifier
building '_py4s' extension
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DHAVE_LAQRS=1 -DHAVE_RASQAL_WORLD=1 -Isrc -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/include/rasqal -I/usr/local/include/raptor2 -I/usr/local/include/python2.7 -c _py4s.c -o build/temp.linux-ia64-2.7/_py4s.o -std=gnu99
_py4s.c:1:2: error: #error Do not use this file, it is the result of a failed Cython compilation.
error: command 'gcc' failed with exit status 1

Need adding a line "from cpython cimport bool" in _py4s.pyx.
See http://wiki.cython.org/FAQ#HowdoIdeclareanobjectoftypebool.3F

jason-ni commented Aug 4, 2011

Also have the same trouble described in #4. Not solved yet...

This may be a very late reply, but I guess the way is to add the line:
from libcpp cimport bool

@jason-ni jason-ni closed this Jul 11, 2012

Need adding a line "from cpython cimport bool" in _py4s.pyx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment