Important: Please read the Qt Code of Conduct -

QtCreator Analyze Menu Missing when launched as root

  • I am developing under 64 bit Linux, and as my application needs to run as root, I launch QtCreator as root. However, when QtCreator (up to v2.6) is launched as root on RedHat Linux, the entire Analyze Menu is missing, and therefore I am unable to access Valgrind.

    Anybody have ideas why or a solution?

  • Moderators

    Please do not run creator as root. It uses plugins and all kind of things and is most likely not save for root usage. You can always use a script starting your application using sudo or whatever.

  • How else would you recommend debugging an application within Qt Creator for an application which must have root privileges to execute (i.e. it opens files in /etc, generates log files to /var/log, opens up communications sockets, etc.). I can always do this in Eclipse, but the Qt Creator workflow is more convenient.

  • Moderators

    You could set up a remote linux box (Tools->Options->Devices) and configure it to connect to root@localhost.

    Afterwards you need to clone the kit (Tools->Options->Build & Run->Kits) you are using, replace the device type with "Generic remote linux" (don't remember the name) and the device with the one you just set up.

    Finally you need to add a that new kit to your project and you are done.

    PS: Make sure gdbserver is installed;-)

Log in to reply