Important: Please read the Qt Code of Conduct -

Deploy and start app at Raspberry Startup

  • Hi there,

    I'm actually develloping an app on my raspberry Pi 3 I need this app to start on Rasp startup, I did not find any solutions that worked for me do you have any clue , or is there anything to do in QT t oset this up .

    By the way I'm running rasbian.

  • Lifetime Qt Champion

    There is nothing in Qt you must do extra as compared to any other .exe you want to run at startup

    However, I trust u can run the app on the pi and its just the issue of running it at startup ?

  • I can run the app by using the RUN button in Qt I never tried to launch by using .exe cause I don't know how to do this, I mean I already looked at deplying an application but I'm not able to start from .exe is there any command that I should run ?

    If I can handle that , I could launch my app by using the .exe at startup.

  • Lifetime Qt Champion

    First you should be able to run the app outside Creator.
    I assume PI OS acts like any other linux.
    So you need a deployment folder with the Qt run times files. DLL/so files
    section Linux GCC 32-bit and 64-bit compilers:

    Pay huge attention to what dlls/so files u copy. DO NOT mix debug and release.

    If the OS is not like a linux then i have no clue on how to deploy to it. :)

  • Debian works like a linux system so no problem from here.

    In the tuto you send me I don't understand how to know which dll are needed ?

  • Lifetime Qt Champion

    You can use ldd on your exe to see which is needed.
    Also there is a tool

    Also the tut does list the barebone needed.
    to run.

  • Alright I'll have a look on that, many thanks .

  • Hi again , I'm not able to run linuxdeployqt so I managed to use ldd command to find the libraries that are needed.

    Can't understand anything at what should I do , in the tutorial you send in the deployment folder there only is the .exe and a file named platforms. But when I'm using the deployment oon QT creator , I get a folder with all .o/.h/.cpp files that contains my program. I certainly forgot domething to do but don't know what.

    At least when running the ldd command I got :

    pi@dex:~/Desktop/Deployment $ sudo ldd SmartDevice_QT_V13 (0x7edd0000)
    	/usr/lib/arm-linux-gnueabihf/ (0x76f61000) => /usr/local/Qxt/lib/ (0x76ed8000) => /usr/local/Qxt/lib/ (0x76e18000) => not found => /usr/lib/arm-linux-gnueabihf/ (0x7539f000) => /usr/lib/arm-linux-gnueabihf/ (0x75359000) => /usr/lib/arm-linux-gnueabihf/ (0x74fb3000) => /usr/lib/arm-linux-gnueabihf/ (0x74f69000) => /usr/lib/arm-linux-gnueabihf/ (0x74678000) => /usr/lib/arm-linux-gnueabihf/ (0x7454a000) => /usr/lib/arm-linux-gnueabihf/ (0x742a9000) => /lib/arm-linux-gnueabihf/ (0x74280000) => /usr/lib/arm-linux-gnueabihf/ (0x741a4000) => /lib/arm-linux-gnueabihf/ (0x74129000) => /lib/arm-linux-gnueabihf/ (0x740fc000) => /lib/arm-linux-gnueabihf/ (0x73fbb000) => /lib/arm-linux-gnueabihf/ (0x73f93000) => /usr/lib/arm-linux-gnueabihf/ (0x73f82000) => /usr/lib/arm-linux-gnueabihf/ (0x73f2d000) => /lib/arm-linux-gnueabihf/ (0x73efd000) => /usr/lib/arm-linux-gnueabihf/ (0x73ee2000) => /usr/lib/arm-linux-gnueabihf/ (0x73eae000) => /usr/lib/arm-linux-gnueabihf/ (0x73e5f000) => /usr/lib/arm-linux-gnueabihf/ (0x73e08000) => /usr/lib/arm-linux-gnueabihf/ (0x73da0000) => /usr/lib/arm-linux-gnueabihf/ (0x73c9c000) => /usr/lib/arm-linux-gnueabihf/ (0x73c41000) => /lib/arm-linux-gnueabihf/ (0x73b3e000) => /usr/lib/arm-linux-gnueabihf/ (0x73a84000) => /usr/lib/arm-linux-gnueabihf/ (0x73a42000) => /usr/lib/arm-linux-gnueabihf/ (0x7392c000)
    	/lib/ (0x54ad2000) => /usr/lib/arm-linux-gnueabihf/ (0x73906000) => /usr/lib/arm-linux-gnueabihf/ (0x7386e000) => /usr/lib/arm-linux-gnueabihf/ (0x7385f000) => /usr/lib/arm-linux-gnueabihf/ (0x73841000) => /usr/lib/arm-linux-gnueabihf/ (0x73822000) => /lib/arm-linux-gnueabihf/ (0x7380e000) => /lib/arm-linux-gnueabihf/ (0x737f7000) => /usr/lib/arm-linux-gnueabihf/ (0x73777000) => /usr/lib/arm-linux-gnueabihf/ (0x73732000) => /usr/lib/arm-linux-gnueabihf/ (0x7371d000) => /usr/lib/arm-linux-gnueabihf/ (0x7370d000) => /lib/arm-linux-gnueabihf/ (0x7369a000) => /lib/arm-linux-gnueabihf/ (0x73668000) => /usr/lib/arm-linux-gnueabihf/ (0x73649000) => /usr/lib/arm-linux-gnueabihf/ (0x735f2000) => /usr/lib/arm-linux-gnueabihf/ (0x735e7000) => /lib/arm-linux-gnueabihf/ (0x735d3000) => /usr/lib/arm-linux-gnueabihf/ (0x735c7000)

    That's all my libraries that are needed to run my app I assume but I don't know where to put this ? with all the files in my deployment folder ?

  • Lifetime Qt Champion


    • I assume but I don't know where to put this ?

    in a folder on the board. Then try to run your exe from that folder.
    a deployment folder is nothing more than
    a folder with Qt SO files and the exe.

  • Alright thank you I made a new installation of Qt and get the 5.7 version instead of the 4.8 so I'll try that when the change is effective.

    See you !

  • Lifetime Qt Champion

    ok :)
    Hopefully it just runs now.

  • Hope so too ! :)

Log in to reply