Hi Jean-Christophe (2016.07.02_11:15:36_-0700) > I don’t think it has anything to do with gcc/glibc.
I agree. I suggest doing a build with a debug python interpreter, then you get a very helpful error message: $ LC_ALL=C.UTF-8 xvfb-run -a --server-args="-screen 0 1024x768x24" python3-dbg -m pytest ==================================== test session starts ==================================== platform linux -- Python 3.5.2+, pytest-3.0.2, py-1.4.31, pluggy-0.3.1 rootdir: /build/cairocffi-op2T2E/cairocffi-0.7.2, inifile: collected 44 items cairocffi/test_cairo.py ...................................... cairocffi/test_pixbuf.py .... cairocffi/test_xcb.py FF ========================================= FAILURES ========================================== ______________________________________ test_xcb_pixmap ______________________________________ xcb_conn = <xcffib.Connection object at 0x7f997f5672c8> def test_xcb_pixmap(xcb_conn): width = 10 height = 10 # create a new window wid = create_window(xcb_conn, width, height) # create the pixmap used to draw with cairo pixmap = create_pixmap(xcb_conn, wid, width, height) # create graphics context to copy pixmap on window gc = create_gc(xcb_conn) # create XCB surface on pixmap root_visual = find_root_visual(xcb_conn) > surface = XCBSurface(xcb_conn, pixmap, root_visual, width, height) cairocffi/test_xcb.py:128: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <cairocffi.xcb.XCBSurface object at 0x7f997f56bf60> conn = <xcffib.Connection object at 0x7f997f5672c8>, drawable = 2097153 visual = <xcffib.xproto.VISUALTYPE object at 0x7f997f56b398>, width = 10, height = 10 def __init__(self, conn, drawable, visual, width, height): c_visual = visualtype_to_c_struct(visual) p = cairo.cairo_xcb_surface_create( > conn._conn, drawable, c_visual, width, height) E TypeError: initializer for ctype 'xcb_connection_t *' appears indeed to be 'xcb_connection_t *', but the types are different (check that you are not e.g. mixing up different ffi instances) cairocffi/xcb.py:38: TypeError ______________________________________ test_xcb_window ______________________________________ xcb_conn = <xcffib.Connection object at 0x7f99858430c0> @pytest.mark.xfail(cairo_version() < 11200, reason="Cairo version too low") def test_xcb_window(xcb_conn): width = 10 height = 10 # create a new window used to draw with cairo wid = create_window(xcb_conn, width, height) # map the window and wait for it to appear xcb_conn.core.MapWindow(wid) xcb_conn.flush() start = time.time() while time.time() < start + 10: event = xcb_conn.wait_for_event() if isinstance(event, xcffib.xproto.ExposeEvent): break else: pytest.fail("Never received ExposeEvent") # create XCB surface on window root_visual = find_root_visual(xcb_conn) > surface = XCBSurface(xcb_conn, wid, root_visual, width, height) cairocffi/test_xcb.py:192: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <cairocffi.xcb.XCBSurface object at 0x7f997f56ec88> conn = <xcffib.Connection object at 0x7f99858430c0>, drawable = 2097152 visual = <xcffib.xproto.VISUALTYPE object at 0x7f998583d948>, width = 10, height = 10 def __init__(self, conn, drawable, visual, width, height): c_visual = visualtype_to_c_struct(visual) p = cairo.cairo_xcb_surface_create( > conn._conn, drawable, c_visual, width, height) E TypeError: initializer for ctype 'xcb_connection_t *' appears indeed to be 'xcb_connection_t *', but the types are different (check that you are not e.g. mixing up different ffi instances) cairocffi/xcb.py:38: TypeError ============================ 2 failed, 42 passed in 0.87 seconds ============================ -- Stefano Rivera http://tumbleweed.org.za/ +1 415 683 3272