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

Qt Deploy Symbolic Link to Remote Target

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Not Evaluated
    • Resolution: Won't Do
    • Affects Version/s: Qt Creator 4.13.2
    • Fix Version/s: None
    • Component/s: Remote Linux
    • Labels:
      None
    • Environment:
      Fedora 29
    • Platform/s:
      Linux/Yocto

      Description

      Hi,

      I'm trying to deploy a symbolic link to my remote device.

      I configured my .PRO as follows:

      rc5File.path = /etc/rc5.d
      rc5File.extra = ls # Used to force folder creation in the build process
      INSTALLS += rc5File
      
      initFile.path = /etc/init.d
      initFile.files += qt
      initFile.extra = cd $(INSTALL_ROOT)$$rc5File.path && ln -sf ../init.d/$$initFile.files S50$$initFile.files
      INSTALLS += initFile
      

      But when I deploy to the IDE the symbolic link is not sent to the target device.
      There is no error in the compilation process and neither in the deployment process.

      The interesting thing is that, when I perform a "make install" with INSTALL_ROOT configured for a tmp directory that I created in my build folder, the symbolic link is created correctly in the target folder.

      Is there an extra step I should take or can this only be done by the "Run custom remote command" in the project tab?

      I use root access on my device and even write other files in the /etc directory.

      I ran the command you suggested, but the installer.log file for some reason I don't know is not created, either on my machine or on the device.

      But as I mentioned before, when I perform a "make install" on my machine with INSTALL_ROOT configured for a tmp directory that I created in my build folder, the symbolic link is created correctly in the target folder.

      I believed that all the content generated within this folder would be the content that the deployment process would send to the device, but this situation seems to show that it is not quite like that.

      08:22:48: The process "/usr/bin/make" exited normally.
      08:22:48: The remote file system has 12338 megabytes of free space, going ahead.
      08:22:48: Deploy step finished.
      08:22:48: Trying to kill "/opt/MyProject/bin/MyProject" on remote device...
      08:22:49: Remote application killed.
      08:22:49: Deploy step finished.
      08:22:49: 13 file(s) need to be uploaded.
      
      08:22:49: sftp> -mkdir /
      08:22:49: sftp> -mkdir /etc
      08:22:49: sftp> -mkdir /scripts
      08:22:49: sftp> -mkdir /opt
      08:22:49: sftp> -mkdir /etc/init.d
      08:22:49: sftp> -mkdir /etc/udev
      08:22:49: sftp> -mkdir /etc/network
      08:22:49: sftp> -mkdir /opt/MyProject
      08:22:49: sftp> -mkdir /etc/udev/rules.d
      08:22:49: sftp> -mkdir /opt/MyProject/bin
      08:22:49: sftp> -mkdir /opt/MyProject/bin/lang
      08:22:49: sftp> -mkdir /opt/MyProject/bin/Hashes
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/build/qt /etc/init.d/qt
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/build/autonet.rules /etc/udev/rules.d/autonet.rules
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/build/interfaces /etc/network/interfaces
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/scripts/touchscreen_env.sh /scripts/touchscreen_env.sh
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/lang/en_US.qm /opt/MyProject/bin/lang/en_US.qm
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/lang/es_ES.qm /opt/MyProject/bin/lang/es_ES.qm
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/lang/pt_BR.qm /opt/MyProject/bin/lang/pt_BR.qm
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/build/.commit /opt/MyProject/bin/.commit
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/Hashes/en_US.qm.sha /opt/MyProject/bin/Hashes/en_US.qm.sha
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/Hashes/es_ES.qm.sha /opt/MyProject/bin/Hashes/es_ES.qm.sha
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/Hashes/MyProject.sha /opt/MyProject/bin/Hashes/MyProject.sha
      08:22:49: sftp> put /home/matheus.r/Projetos/Qt/MyProject/src/Hashes/pt_BR.qm.sha /opt/MyProject/bin/Hashes/pt_BR.qm.sha
      08:22:49: sftp> put /home/matheus.r/Projetos/Build/build-MyProject-POKY_1_6_1-Release/MyProject /opt/MyProject/bin/MyProject
      
      08:22:50: All files successfully deployed.
      08:22:50: Deploy step finished.
      08:22:50: Elapsed time: 00:04.
      

      When I add the "Run custom remote command" in the Project tab, after the deployment process the commands that I want to be executed, occur successfully.

      I would like the same process to be performed via .PRO settings.

       

      09:23:52: All files successfully deployed.
      09:23:52: Deploy step finished.
      09:23:52: Starting remote command "cd /etc/rc5.d/ && ln -sf /etc/init.d/qt S50qt"...
      09:23:52: Remote command finished successfully.
      09:23:52: Deploy step finished.
      09:23:52: Elapsed time: 00:04.
      

      On my build folder:

      -rwxrwxr-x 1 matheus.r matheus.r 1707 out 16 16:05 qt
      lrwxrwxrwx 1 matheus.r matheus.r 14 out 17 09:00 S50qt -> /etc/init.d/qt
      

      If on .PRO:

      rc5d.path = /etc/rc5.d
      rc5d.files += S50qt
      INSTALLS += rc5d
      

      But...

      09:52:17: The process "/usr/bin/make" exited normally.
      09:52:17: The remote file system has 12338 megabytes of free space, going ahead.
      09:52:17: Deploy step finished.
      09:52:17: Trying to kill "/opt/MyProject/bin/MyProject" on remote device...
      09:52:18: Remote application killed.
      09:52:18: Deploy step finished.
      09:52:18: 14 file(s) need to be uploaded.
      09:52:18: Local file "/home/matheus.r/Projetos/Build/build-MyProject-POKY_1_6_1-Release/S50qt" does not exist.
      09:52:18: Deploy step failed.
      Error while building/deploying project MyProject (kit: POKY 1.6.1)
      When executing step "Upload files via SFTP"
      09:52:18: Elapsed time: 00:11.

       

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            kandeler Christian Kandeler
            Reporter:
            matheus.r Matheus da Silva Ribeiro
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes