Source: python-cffi
Version: 0.8.6-1
Severity: important
Hi,
python-cffi FTBFS on mips64el with a segfault in the testsuite:
> testing/test_verify.py
> ..........s.............s.........................................................s.................................................s
> testing/test_verify2.py
> ..........s.............s.........................................................s.................................................s
> testing/test_version.py .....
> Segmentation fault
> E: pybuild pybuild:256: test: plugin custom failed with: exit code=139:
> python2.7 -m pytest c/ testing/
I did a bit of debugging which tracked it down to a segfault within
function in the libffi mips backend, caused by the test
test_opaque_integer_as_function_result in test_verify.py
It looked like CFFI told libffi that the return type of the function was
a structure of size 2 but with no elements - that seems illegal to me.
I worked around it using the attached patch which disables the test on
mips64 systems. I'm not entirely sure this is the "right" thing to do
though since it does look like there's a bug here.
Thanks,
James
--- a/testing/test_verify.py
+++ b/testing/test_verify.py
@@ -1162,6 +1162,8 @@ def test_opaque_integer_as_function_resu
import platform
if platform.machine().startswith('sparc'):
py.test.skip('Breaks horribly on sparc (SIGILL + corrupted stack)')
+ elif platform.machine() == 'mips64' and sys.maxsize > 2**32:
+ py.test.skip('Segfaults on mips64el')
# XXX bad abuse of "struct { ...; }". It only works a bit by chance
# anyway. XXX think about something better :-(
ffi = FFI()
_______________________________________________
Python-modules-team mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/python-modules-team