Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cython 0.22 does not compile master #2805

Closed
matham opened this issue Dec 30, 2014 · 9 comments
Closed

Cython 0.22 does not compile master #2805

matham opened this issue Dec 30, 2014 · 9 comments
Labels
Priority: High Should be fixed ASAP
Milestone

Comments

@matham
Copy link
Member

matham commented Dec 30, 2014

Using cython dev from github:

e:\MinGW\bin\gcc.exe -shared -s build\temp.win32-2.7\Release\kivy\graphics\trans
formation.o build\temp.win32-2.7\Release\kivy\graphics\transformation.def -Le:\P
ython27\libs -Le:\Python27\PCbuild -lopengl32 -lglew32 -lpython27 -lmsvcr90 -o G
:\Python\dev2\kivy\kivy\graphics\transformation.pyd -lm
cythoning kivy\graphics/vbo.pyx to kivy\graphics\vbo.c

 Error compiling Cython file:
 ------------------------------------------------------------
 ...
     cpdef release(self)
     cpdef get_pixel_color(self, int wx, int wy)

     cdef void create_fbo(self)
     cdef void delete_fbo(self)
     cdef void apply(self)
                   ^
 ------------------------------------------------------------

 kivy\graphics\fbo.pxd:27:19: Signature not compatible with previous declaration


 Error compiling Cython file:
 ------------------------------------------------------------
 ...
     cdef void push_states(self, list names) except *
     cdef void pop_state(self, str name) except *
     cdef void pop_states(self, list names) except *
     cdef void enter(self) except *
     cdef void leave(self) except *
     cdef void apply(self) except *
                   ^
 ------------------------------------------------------------

 kivy\graphics\instructions.pxd:123:19: Previous declaration is here
building 'kivy.graphics.vbo' extension
e:\MinGW\bin\gcc.exe -mdll -O -Wall -Ie:\Python27\include -Ie:\Python27\PC -c ki
vy\graphics\vbo.c -o build\temp.win32-2.7\Release\kivy\graphics\vbo.o
kivy\graphics\vbo.c:1:2: error: #error Do not use this file, it is the result of
 a failed Cython compilation.
 #error Do not use this file, it is the result of a failed Cython compilation.
  ^
 error: command 'e:\\MinGW\\bin\\gcc.exe' failed with exit status 1
make: *** [force] Error 1

I think they most have become stricter about keeping function prototypes consistent.

@matham matham added Status: Needs-analysis Issue needs to be analyzed if it's real Status: Confirmed Confirmed as real issue labels Dec 30, 2014
@matham matham added this to the 1.9.0 milestone Dec 30, 2014
@matham matham removed the Status: Confirmed Confirmed as real issue label Dec 30, 2014
@matham
Copy link
Member Author

matham commented Dec 30, 2014

Upon typing them with except * I get:

cythoning kivy\graphics/fbo.pyx to kivy\graphics\fbo.c
building 'kivy.graphics.fbo' extension
e:\MinGW\bin\gcc.exe -mdll -O -Wall -Ie:\Python27\include -Ie:\Python27\PC -c ki
vy\graphics\fbo.c -o build\temp.win32-2.7\Release\kivy\graphics\fbo.o
In file included from kivy\graphics\fbo.c:237:0:
kivy\graphics\gl_redirect.h: In function 'glew_dynamic_binding':
kivy\graphics\gl_redirect.h:71:33: warning: pointer targets in initialization di
ffer in signedness [-Wpointer-sign]
     const char *gl_extensions = glGetString(GL_EXTENSIONS);
                                 ^
kivy\graphics\fbo.c: In function '__pyx_f_4kivy_8graphics_3fbo_3Fbo_apply':
kivy\graphics\fbo.c:4554:5: warning: implicit declaration of function '__pyx_f_4
kivy_8graphics_12instructions_13RenderContext_apply' [-Wimplicit-function-declar
ation]
     __pyx_f_4kivy_8graphics_12instructions_13RenderContext_apply(((struct __pyx
_obj_4kivy_8graphics_12instructions_RenderContext *)__pyx_v_self)); if (unlikely
(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 329; __pyx_clin
eno = __LINE__; goto __pyx_L1_error;}
     ^
kivy\graphics\fbo.c: In function '__Pyx_RaiseTooManyValuesError':
kivy\graphics\fbo.c:7397:18: warning: unknown conversion type character 'z' in f
ormat [-Wformat=]
                  "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T
"d)", expected);
                  ^
kivy\graphics\fbo.c:7397:18: warning: too many arguments for format [-Wformat-ex
tra-args]
kivy\graphics\fbo.c: In function '__Pyx_RaiseNeedMoreValuesError':
kivy\graphics\fbo.c:7403:18: warning: unknown conversion type character 'z' in f
ormat [-Wformat=]
                  index, (index == 1) ? "" : "s");
                  ^
kivy\graphics\fbo.c:7403:18: warning: format '%s' expects argument of type 'char
 *', but argument 3 has type 'Py_ssize_t' [-Wformat=]
kivy\graphics\fbo.c:7403:18: warning: too many arguments for format [-Wformat-ex
tra-args]
kivy\graphics\fbo.c: In function '__Pyx_RaiseArgtupleInvalid':
kivy\graphics\fbo.c:7741:18: warning: unknown conversion type character 'z' in f
ormat [-Wformat=]
                  (num_expected == 1) ? "" : "s", num_found);
                  ^
kivy\graphics\fbo.c:7741:18: warning: format '%s' expects argument of type 'char
 *', but argument 5 has type 'Py_ssize_t' [-Wformat=]
kivy\graphics\fbo.c:7741:18: warning: unknown conversion type character 'z' in f
ormat [-Wformat=]
kivy\graphics\fbo.c:7741:18: warning: too many arguments for format [-Wformat-ex
tra-args]
writing build\temp.win32-2.7\Release\kivy\graphics\fbo.def
e:\MinGW\bin\gcc.exe -shared -s build\temp.win32-2.7\Release\kivy\graphics\fbo.o
 build\temp.win32-2.7\Release\kivy\graphics\fbo.def -Le:\Python27\libs -Le:\Pyth
on27\PCbuild -lopengl32 -lglew32 -lpython27 -lmsvcr90 -o G:\Python\dev2\kivy\kiv
y\graphics\fbo.pyd -lm
build\temp.win32-2.7\Release\kivy\graphics\fbo.o:fbo.c:(.text+0x5a9): undefined
reference to `__pyx_f_4kivy_8graphics_12instructions_13RenderContext_apply'
collect2.exe: error: ld returned 1 exit status
 error: command 'e:\\MinGW\\bin\\gcc.exe' failed with exit status 1
make: *** [force] Error 1

Which I don't understand. Maybe it's a bug with cython?

@tito
Copy link
Member

tito commented Dec 31, 2014

You can fix the declaration if needed, or report to Cython dev itself. Opening an issue here is not entirely relevant as Cython in dev is not stable :)

@tito tito closed this as completed Dec 31, 2014
@matham matham changed the title Cython dev does not compile master Cython 0.22 does not compile master Feb 19, 2015
@matham
Copy link
Member Author

matham commented Feb 19, 2015

Reopening because this is now a issue with cython 0.22 on pip.

@matham matham reopened this Feb 19, 2015
@matham matham added the Priority: High Should be fixed ASAP label Feb 19, 2015
@matham matham removed the Status: Needs-analysis Issue needs to be analyzed if it's real label Feb 19, 2015
@matham
Copy link
Member Author

matham commented Feb 19, 2015

Here's the cython bug report of this issue: https://groups.google.com/forum/#!topic/cython-users/r3dQSfOKMjI

@kived kived added the Status: Has PR There's a PR available for the issue label Feb 22, 2015
@kived
Copy link
Contributor

kived commented Feb 22, 2015

@matham, adding except * works on Linux. Could you check if my PR works for you on Windows? If it doesn't, there might be something specific to Windows we can fix to make it work with 0.22.

@kived kived removed the Status: Has PR There's a PR available for the issue label Feb 28, 2015
@kived
Copy link
Contributor

kived commented Feb 28, 2015

Closing because we now refuse to build, with a helpful error message, on Cython 0.22 (and 0.22.alpha0, 0.22.beta0).

@kived kived closed this as completed Feb 28, 2015
@tleeuwenburg
Copy link

Unfortunately, this is still affecting the macports version, which tries to use the latest cython, which is 0.22_0. From a developer perspective, I get it, but from a user perspective this is a big pain. I've commented on the cython bug also. I think Kivy is an excluded option for me until this is fixed.

@donpdonp
Copy link

donpdonp commented Jul 5, 2015

I ran into the cython 0.22 build problem on ubuntu 15.04. quick fix is

$ pip install -I cython==0.21

@Kovak
Copy link
Contributor

Kovak commented Jul 5, 2015

master should compile on cython .22 now, if you are using the last stable release you will need to use cython .21 I believe

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: High Should be fixed ASAP
Projects
None yet
Development

No branches or pull requests

6 participants