Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Crash ON RPI3 On Startup



  • I have a pi3 and QT 5.12.3 and my application crashes on my pi(but runs fine on my x86 box). The crash happens when it tries to create the very first widget. I'm using eglfs. I cross compiled QT on another host. The application is built on the same host against the same compiled QT.

    BT:

    Thread 1 "SMAH_generic" received signal SIGSEGV, Segmentation fault.
    0x7646eab8 in QOpenGLContext::handle() const () from /usr/local/qt5/lib/libQt5Gui.so.5
    (gdb) bt
    #0  0x7646eab8 in QOpenGLContext::handle() const () from /usr/local/qt5/lib/libQt5Gui.so.5
    #1  0x756d07c0 in QEglFSIntegration::createPlatformOpenGLContext(QOpenGLContext*) const () from /usr/local/qt5/plugins/platforms/../../lib/libQt5EglFSDeviceIntegration.so.5
    #2  0x76472bf0 in QOpenGLContext::create() () from /usr/local/qt5/lib/libQt5Gui.so.5
    #3  0x756ca8fc in QEglFSWindow::create() () from /usr/local/qt5/plugins/platforms/../../lib/libQt5EglFSDeviceIntegration.so.5
    #4  0x756d0238 in QEglFSIntegration::createPlatformWindow(QWindow*) const () from /usr/local/qt5/plugins/platforms/../../lib/libQt5EglFSDeviceIntegration.so.5
    #5  0x7643ab5c in QWindowPrivate::create(bool, unsigned int) () from /usr/local/qt5/lib/libQt5Gui.so.5
    #6  0x76964024 in QWidgetPrivate::create_sys(unsigned int, bool, bool) () from /usr/local/qt5/lib/libQt5Widgets.so.5
    #7  0x76963740 in QWidget::create(unsigned int, bool, bool) () from /usr/local/qt5/lib/libQt5Widgets.so.5
    #8  0x7696edb0 in QWidgetPrivate::setVisible(bool) () from /usr/local/qt5/lib/libQt5Widgets.so.5
    #9  0x0001986c in main (argc=1, argv=0x7efff724) at ../src/main.cpp:291
    

    From main.cpp

    MainWindow mainWindow;
    ...
    mainWindow.show(); // <-- this is line 291
    

    mainwindow.h:

    #ifndef MAINWINDOW_H
    #define MAINWINDOW_H
    
    #include <QWidget>
    #include <QStackedLayout>
    #include <QMap>
    #include <QTimer>
    #include <QPainter>
    
    #include "zone.h"
    
    #include "widgets/w_zonechooser.h"
    #include "widgets/w_topheader.h"
    #include "widgets/w_systemsettings.h"
    #include "widgets/w_zonecontainer.h"
    #include "widgets/w_screensaver.h"
    
    class MainWindow : public QWidget
    {
        Q_OBJECT
    public:
        explicit MainWindow(QWidget *parent = nullptr);
        void paintEvent(QPaintEvent *pe);
        QWidget *topWidget;
        QStackedLayout *contentLayout;
    
    private:
        TopHeaderWidget *hcheader;
        QStackedLayout *mainWidgetLayout;
        ScreenSaverWidget *screensaverHolder;
        QTimer *idleTimer;
    
    protected:
    
    signals:
        void zoneChanged(Zone);
        void requestingNetworkOut(QString command, QJsonObject jsonPayload, QString responseTo);
    
    public slots:
        void showZoneChooser();
        void showSystemWidget();
        void addPreset(Preset preset);
        void hideSaver();
        void showSaver();
        void resetIdle(QEvent *ev);
    };
    
    #endif // MAINWINDOW_H
    

    Here is my qt config.summary: https://pastebin.com/hWSzDvFH


Log in to reply