dos1 / kamerka

Take photos using your webcam and shiny animated QML interface (KF5 app)
http://dos1.github.com/kamerka
GNU General Public License v2.0
20 stars 10 forks source link

KF5/Qt5 version segfaults due to QImageBlitz forcing dependency on Qt4 (libQtGui.so.4) #27

Open akien-mga opened 7 years ago

akien-mga commented 7 years ago

I just updated Mageia's kamerka package to the current master branch, to get the KF5 port.

On my machine, it segfaults on launch:

Program received signal SIGSEGV, Segmentation fault.
0x00007fffee80fef4 in _GLOBAL__sub_I_qprinterinfo.cpp () from /lib64/libQtGui.so.4
(gdb) bt
#0  0x00007fffee80fef4 in _GLOBAL__sub_I_qprinterinfo.cpp () at /lib64/libQtGui.so.4
#1  0x00007ffff7dec0ca in call_init.part () at /lib64/ld-linux-x86-64.so.2
#2  0x00007ffff7dec1db in _dl_init () at /lib64/ld-linux-x86-64.so.2
#3  0x00007ffff7dddc8a in _dl_start_user () at /lib64/ld-linux-x86-64.so.2
#4  0x0000000000000001 in  ()
#5  0x00007fffffffdf59 in  ()
#6  0x0000000000000000 in  ()

This looks exactly like a segfault I used to have with a libvlc/Qt based app: https://github.com/MBach/Miam-Player/issues/9 It was eventually solved via https://bugs.mageia.org/show_bug.cgi?id=15311.

Here vlc does not seem involved, so I guess the culprit is qimageblitz:

$ urpmq --requires lib64qimageblitz4 libQtCore.so.4()(64bit) libQtGui.so.4()(64bit) libc.so.6()(64bit) libc.so.6(GLIBC_2.14)(64bit) libc.so.6(GLIBC_2.2.5)(64bit) libc.so.6(GLIBC_2.4)(64bit) libm.so.6()(64bit) libm.so.6(GLIBC_2.2.5)(64bit) libstdc++.so.6()(64bit) libstdc++.so.6(GLIBCXX_3.4)(64bit)

AFAIK QImageBlitz has no new upstream release since 0.0.6, which still uses Qt4. This triggers conflicting dependencies on Qt4 and Qt5, which Qt does not handle properly, thus leading to a happy crash.

Also reported on Mageia's bugzilla: https://bugs.mageia.org/show_bug.cgi?id=20129

dos1 commented 7 years ago

Yeah, that's the reason why the Qt5 port (#26) is not released yet - QImageBlitz can be compiled with both Qt4 and Qt5, but there's no new release, so it's not packaged anywhere and it cannot easily coexist in both versions at the same time. Guess I'll have to either incorporate QImageBlitz code into Kamerka's tree or use something else.

akien-mga commented 7 years ago

I found a patch to make it possible to coinstall the Qt4 and Qt5 versions of QImageBlitz [0]. I'll see if I can apply it to Mageia's package and thus package both flavours.

[0] https://www.mail-archive.com/kde-core-devel@kde.org/msg20689.html

akien-mga commented 7 years ago

So I've packaged the Qt5 version of QImageBlitz for my distro and Kamerka now works fine. But that's indeed not the right solution for you, as it will be hard to get distros or interesting developers to get ahold of the old never released Qt5 port of QImageBlitz in KDE's SVN.