Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-28132

qtcreator cannot load plugins, segfault in QmlProjectPlugin

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Not Evaluated
    • None
    • Qt Creator 8.0.1
    • Building Qt Creator
    • None
    • NixOS Linux
    • Linux/X11

    Description

      im trying to build qtcreator 8.0.1 on NixOS Linux

      the challenge with NixOS Linux: most files are in the /nix/store prefix, not in the /usr prefix, so maybe i need to patch some file paths in qtcreator

      when i start qtcreator, many plugins fail to load

      finally, the QmlProjectManager plugin causes a segfault

      how can i get debug output from qtcreator plugins? i tried

      QT_LOGGING_RULES='*.debug=true' qtcreator
      QT_LOGGING_RULES='default.debug=true' qtcreator
      

      only *.debug=true increases the debug level, but i dont see debug output from plugins

      i added some debug prints to qt-creator-opensource-src-8.0.1/src/libs/extensionsystem/pluginmanager.cpp

          Utils::reverseForeach(queue, [this](PluginSpec *spec) {
              loadPlugin(spec, PluginSpec::Running);
              if (spec->state() == PluginSpec::Running) {
                  delayedInitializeQueue.push(spec);
              } else {
                  // Plugin initialization failed, so cleanup after it
                  qDebug() << "PluginManagerPrivate::loadPlugins spec" << spec << spec->name() << spec->version() << "spec->d->kill()";
                  spec->d->kill();
              }
          });
      

      here are the plugins that fail to load:

      PluginManagerPrivate::loadPlugins spec 0x15bb620 "Welcome" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x15ab540 "WebAssembly" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x15adae0 "Valgrind" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1563a70 "UpdateInfo" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x153f570 "Todo" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1588d10 "TaskList" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1604950 "Subversion" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x159c6b0 "StudioWelcome" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x159cc70 "SilverSearcher" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x15a0fb0 "SerialTerminal" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1591a00 "ScxmlEditor" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1522870 "Qnx" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x15433a0 "QmlProfiler" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x156d020 "QmlDesigner" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1533e90 "QmlPreview" "8.0.1" spec->d->kill()
      PluginManagerPrivate::loadPlugins spec 0x1583090 "QmlProjectManager" "8.0.1" spec->d->kill()
      Segmentation fault (core dumped)
      

      stack trace of QmlProjectPlugin

      note: the destructor is called twice

      Thread 1 ".qtcreator-wrap" received signal SIGSEGV, Segmentation fault.
      
      (gdb) bt
      
      #0  0x00007fffdb011cbc in QmlProjectManager::Internal::QmlProjectPlugin::~QmlProjectPlugin() ()
         from /nix/store/d8kw12yjdl3kk141ij76k6rs0kfyrjdd-qtcreator-8.0.1/lib/qtcreator/plugins/libQmlProjectManager.so
      
      #1  0x00007fffdb011dd9 in QmlProjectManager::Internal::QmlProjectPlugin::~QmlProjectPlugin() ()
         from /nix/store/d8kw12yjdl3kk141ij76k6rs0kfyrjdd-qtcreator-8.0.1/lib/qtcreator/plugins/libQmlProjectManager.so
      
      #2  0x00007ffff7f94206 in ExtensionSystem::Internal::PluginSpecPrivate::kill() ()
         from /nix/store/d8kw12yjdl3kk141ij76k6rs0kfyrjdd-qtcreator-8.0.1/bin/../lib/qtcreator/libExtensionSystem.so.8
      
      #3  0x00007ffff7f87876 in ExtensionSystem::Internal::PluginManagerPrivate::loadPlugins() ()
         from /nix/store/d8kw12yjdl3kk141ij76k6rs0kfyrjdd-qtcreator-8.0.1/bin/../lib/qtcreator/libExtensionSystem.so.8
      
      #4  0x000000000040d080 in main ()
      

      Attachments

        Activity

          People

            con Eike Ziller
            milahu milan hauth
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: