Version: 0.1 (using KDE 4.6.0) OS: Linux After compiling Tupi (Non KDE - Qt application) in a clean way, if you try to execute it then you only get a message from console: "Segmentation fault". The source code of Tupi is available from: http://www.gitorious.org/tupi Note: The application runs perfect from any Window Manager. Only fails on KDE. Initially I thought the bug was in the application's code, but after make some debug, it seems to be something related to KDE libs. (gdb) bt #0 0x00007ffff2cb9833 in memcpy () from /lib64/libc.so.6 #1 0x00007ffff3f2eb18 in QByteArray::realloc(int) () from /usr/lib64/libQtCore.so.4 #2 0x00007ffff3f2fa9f in QByteArray::append(char) () from /usr/lib64/libQtCore.so.4 #3 0x00007fffe919654d in ?? () from /usr/lib64/libkdecore.so.5 #4 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #5 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #6 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #7 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #8 0x00007fffe910cd25 in KConfigGroup::readEntry(char const*, QVariant const&) const () from /usr/lib64/libkdecore.so.5 #9 0x00007fffe91bf7c3 in bool KConfigGroup::readCheck<bool>(char const*, bool const&) const () from /usr/lib64/libkdecore.so.5 #10 0x00007fffe911d074 in KDebug::registerArea(QByteArray const&, bool) () from /usr/lib64/libkdecore.so.5 #11 0x00007fffe5dc8f24 in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #12 0x00007fffe5db3ee2 in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #13 0x00007fffe5dc1cce in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #14 0x00007ffff4b2039e in QStyleFactory::create(QString const&) () from /usr/lib64/libQtGui.so.4 #15 0x00007ffff4838e67 in QApplication::style() () from /usr/lib64/libQtGui.so.4 #16 0x00007ffff48a8009 in ?? () from /usr/lib64/libQtGui.so.4 #17 0x00007ffff48ae2b8 in ?? () from /usr/lib64/libQtGui.so.4 #18 0x00007ffff4839e35 in QApplicationPrivate::construct(_XDisplay*, unsigned long, unsigned long) () from /usr/lib64/libQtGui.so.4 #19 0x00007ffff483a721 in QApplication::QApplication(int&, char**, int) () from /usr/lib64/libQtGui.so.4 #20 0x00007ffff613eb0b in KApplication::KApplication(int&, char**) () from /usr/local/tupi/lib/libtupifwgui.so.1 #21 0x000000000044846e in ?? () #22 0x00000000004377f5 in ?? () #23 0x00007ffff2c56bfd in __libc_start_main () from /lib64/libc.so.6 Reproducible: Always Steps to Reproduce: - Compile the source code of Tupi following this manual: http://www.maefloresta.com/portal/opensuse - Try to run the binary Actual Results: - The application never starts up. Only a message appears from console: "Segmentation fault" Expected Results: - The application should start normally Tests are done from OpenSuse 11.04 x86_64 and KDE 4.6.0
The problem is probably because you name your "class KApplication" but it isn't the KDE KApplication class. Can you check if renaming helps? Oxygen probably decides by class name if the application is a full KDE application.
(In reply to comment #1) > The problem is probably because you name your "class KApplication" but it isn't > the KDE KApplication class. Can you check if renaming helps? Oxygen probably > decides by class name if the application is a full KDE application. I renamed two classes of my code to avoid the possible problem: KApplication -> TApplication KDebug -> TDebug Now, I have mostly the same error: (gdb) bt #0 0x00007ffff2cb9833 in memcpy () from /lib64/libc.so.6 #1 0x00007ffff3f2eb18 in QByteArray::realloc(int) () from /usr/lib64/libQtCore.so.4 #2 0x00007ffff3f2fa9f in QByteArray::append(char) () from /usr/lib64/libQtCore.so.4 #3 0x00007fffe919654d in ?? () from /usr/lib64/libkdecore.so.5 #4 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #5 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #6 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #7 0x00007fffe919684c in ?? () from /usr/lib64/libkdecore.so.5 #8 0x00007fffe910cd25 in KConfigGroup::readEntry(char const*, QVariant const&) const () from /usr/lib64/libkdecore.so.5 #9 0x00007fffe91bf7c3 in bool KConfigGroup::readCheck<bool>(char const*, bool const&) const () from /usr/lib64/libkdecore.so.5 #10 0x00007fffe911d074 in KDebug::registerArea(QByteArray const&, bool) () from /usr/lib64/libkdecore.so.5 #11 0x00007fffe5dc8f24 in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #12 0x00007fffe5db3ee2 in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #13 0x00007fffe5dc1cce in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #14 0x00007ffff4b2039e in QStyleFactory::create(QString const&) () from /usr/lib64/libQtGui.so.4 #15 0x00007ffff4838e67 in QApplication::style() () from /usr/lib64/libQtGui.so.4 #16 0x00007ffff48a8009 in ?? () from /usr/lib64/libQtGui.so.4 #17 0x00007ffff48ae2b8 in ?? () from /usr/lib64/libQtGui.so.4 #18 0x00007ffff4839e35 in QApplicationPrivate::construct(_XDisplay*, unsigned long, unsigned long) () from /usr/lib64/libQtGui.so.4 #19 0x00007ffff483a721 in QApplication::QApplication(int&, char**, int) () from /usr/lib64/libQtGui.so.4 #20 0x00007ffff613eabb in TApplication::TApplication(int&, char**) () from /usr/local/tupi/lib/libtupifwgui.so.1 #21 0x00000000004480ce in ?? () #22 0x00000000004376b1 in ?? () #23 0x00007ffff2c56bfd in __libc_start_main () from /lib64/libc.so.6 Any other suggestion? Thanks
Could you install the debug symbols for kdelibs and kdebase-workspace? If possible, create a minimal application that reproduces the crash (looking at the backtrace, any application that calls the QApplication constructor should crash...) Btw, I could not compile tupi, error message is: ktprojectmanager.cpp: In member function ‘virtual void KTProjectManager::handleLocalRequest(const KTProjectRequest*)’: ktprojectmanager.cpp:331:86: error: taking address of temporary
> Btw, I could not compile tupi, error message is: > > ktprojectmanager.cpp: In member function ‘virtual void > KTProjectManager::handleLocalRequest(const KTProjectRequest*)’: > ktprojectmanager.cpp:331:86: error: taking address of temporary Latest version of gcc doesn't allow some kind of old instructions that I'm still using (variable addressing stuff). I have to update some few lines (pending work) to avoid this annoying error. Now, the good news... I found out the problem! Unfortunately I was using reserved names for my classes like: KConfig, KGlobal, KAction, and so on. I renamed all the suspicious classes, compiled the whole code again and taaa daaa: http://www.maefloresta.com/gallery2/main.php?g2_itemId=363 Now Tupi runs from KDE! Thanks for the hints :)