Package: pyrex
Severity: normal

Pyrex produces C code which does not compile with gcc-4.0.

As an example you can try to build the Debian 'dbus' package
with gcc-4.0. The build log for 'dbus' looks as follows:

 cc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I../dbus -I/usr/include/glib-2.0 
-I/usr/lib/glib-2.0/include -I/usr/include/python2.3 
-DDBUS_API_SUBJECT_TO_CHANGE=1 -g -Wall -O2 -Wchar-subscripts 
-Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith 
-Wcast-align -Wfloat-equal -Wsign-compare -MT dbus_bindings.lo -MD -MP -MF 
.deps/dbus_bindings.Tpo -c dbus_bindings.c  -fPIC -DPIC -o .libs/dbus_bindings.o
dbus_bindings.c: In function 
'__pyx_f_13dbus_bindings_cunregister_function_handler':
dbus_bindings.c:310: error: invalid lvalue in assignment
dbus_bindings.c:354: error: invalid lvalue in assignment
dbus_bindings.c: In function 
'__pyx_f_13dbus_bindings_cmessage_function_handler':
dbus_bindings.c:404: error: invalid lvalue in assignment
dbus_bindings.c:405: error: invalid lvalue in assignment
dbus_bindings.c:455: error: invalid lvalue in assignment
dbus_bindings.c:468: error: invalid lvalue in assignment

The relevant part of the code created by pyrex is

((PyObject*)__pyx_v_conn) = Py_None; Py_INCREF(((PyObject*)__pyx_v_conn));

The (PyObject*) type cast on the left hand side is not allowed by
the C Standard and consequently rejected by gcc-4.0.

Regards
Andreas Jochens


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to