On Tue, 12 Feb 2019 22:54:05 +0100
Charlene Wendling <juliana...@posteo.jp> wrote:

> I'm a bit out of topic here, but all x11/qt5 binaries seem to segfault
> at runtime with ports-gcc-4.9 on macppc - it just worked fine with
> ports-gcc-8.2.

Did you build qtbase with llvm?  I did:

ghostborough$ make -C /usr/ports/x11/qt5/qtbase show=CHOSEN_COMPILER
ports-clang

My qt5 programs also SIGSEGV at startup; I use ports-gcc-8.2 but
didn't disable ports-clang in x11/qt5/qt5.port.mk.

I believe that clang and gcc have incompatible calling conventions
for xcb_intern_atom() in /usr/X11R6/include/xcb/xproto.h.  This
function returns an xcb_intern_atom_cookie_t (a 4-byte struct with
one field, an unsigned int), but clang and gcc don't agree how to
pass the struct.  I might report a bug to llvm.

I used egdb (from devel/gdb) and ltrace to show that qt5 crashes in
libQt5XcbQpa QXcbConnection::initializeAllAtoms().  It gets garbage
instead of a cookie from xcb_intern_atom(), then passes the garbage
to xcb_intern_atom_reply() which returns NULL.  The SIGSEGV is from
dereferencing the NULL.

-- 
George Koehler <kern...@gmail.com>

Reply via email to