Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. my cross compiler has error.tslib install but has error
Forum Updated to NodeBB v4.3 + New Features

my cross compiler has error.tslib install but has error

Scheduled Pinned Locked Moved Solved Qt Creator and other tools
47 Posts 3 Posters 19.0k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • MhM93M MhM93

    I do not install qt creator to see debug mood in my pc, and also this program is run on nanopc-t2 when I wrote this command it returns :

    root@NanoPC-T2:/# strace ./helloqt
    execve("./helloqt", ["./helloqt"], [/* 20 vars */]) = 0
    brk(NULL)                               = 0x21000
    uname({sysname="Linux", nodename="NanoPC-T2", ...}) = 0
    access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or directory)
    mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb6f67000
    access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
    --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0x4} ---
    +++ killed by SIGSEGV +++
    Segmentation fault
    

    Also why do you start it twice:
    with silly reason. I just test what happen to run command with & and without it. :)

    jsulmJ Offline
    jsulmJ Offline
    jsulm
    Lifetime Qt Champion
    wrote on last edited by
    #34

    @MhM93 See here: http://stackoverflow.com/questions/1656891/problems-with-multiple-qapplications

    https://forum.qt.io/topic/113070/qt-code-of-conduct

    1 Reply Last reply
    0
    • MhM93M Offline
      MhM93M Offline
      MhM93
      wrote on last edited by
      #35

      thanks for reply. but i just play one application.
      oot@NanoPC-T2:/# rm helloqt
      root@NanoPC-T2:/# tftp 192.168.101.4
      tftp> get helloqt
      Received 11692 bytes in 0.5 seconds
      tftp> quit
      root@NanoPC-T2:/# chmod +x helloqt
      root@NanoPC-T2:/# ./helloqt -qws
      Segmentation fault
      root@NanoPC-T2:/# file ./helloqt
      ./helloqt: ERROR: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3 error reading (Invalid argument)
      root@NanoPC-T2:/#

      H.Ghassami

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #36

        Again, run it through the debugger.

        By the way, what is the exact architecture of your device ?
        What Linux distribution are you running on it ?

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • MhM93M Offline
          MhM93M Offline
          MhM93
          wrote on last edited by MhM93
          #37

          thanks for reply,
          I should install debugger on my host or on my target?
          this is my device:

          root@NanoPC-T2:/# uname -a
          Linux NanoPC-T2 3.4.39-s5p4418 #1 SMP PREEMPT Wed Mar 1 13:21:10 HKT 2017 armv7l armv7l armv7l GNU/Linux
          

          when I run gdb on my device (nanopc-t2):

          root@NanoPC-T2:/# gdb -q helloqt
          "/helloqt": not in executable format: File truncated
          

          and also when I run this:

          root@NanoPC-T2:/# sudo readelf -a ./helloqt | grep NEEDED
          readelf: Error: Reading 0x618 bytes extends past end of file for section headers
          readelf: Error: Section headers are not available!
           0x00000001 (NEEDED)
          

          Is that mean my header is wrong?
          this is my code:

          #include <QApplication>
          #include <QPushButton>
          int main(int argc, char **argv)
          {
                  QApplication app (argc, argv);
                  QPushButton button ("Hello world !");
                  button.show();
                  return app.exec();
          }
          

          H.Ghassami

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #38

            Looks like there is a problem with your file. How are you copying it over to your device ?

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0
            • MhM93M Offline
              MhM93M Offline
              MhM93
              wrote on last edited by MhM93
              #39

              *I copy it by tftp. First I copy it from ubuntu vmware to windows then wrote this command to copy it to my device:

              tftp 192.168.101.4
              tftp>get helloqt
              //after transfering.....
              tftp>quit
              

              first run this command

              . setqt4env
              

              and after that run this command, I make my file runable with this command:

              chmod +x helloqt
              

              then I run it with this command but that error show to me:

              ./helloqt -qws
              

              ................................................................................................................................................................................
              FINALLY RUN MY APP ON ME DEVICE BUT MAKE A LOT OF QUESTION FOR ME:
              .............................................................................................................................................................................
              I set my ssh to deploy the qt (from vmware ubuntu to my nanopc) also set this to .pro file:

              #-------------------------------------------------
              #
              # Project created by QtCreator 2017-05-13T01:48:28
              #
              #-------------------------------------------------
              
              QT       += core gui
              
              greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
              
              target.path = ~/helloqt
              INSTALLS += target
              
              TARGET =
              TEMPLATE = app
              
              
              SOURCES += main.cpp\
                     mainwindow.cpp
              
              HEADERS  += mainwindow.h
              
              FORMS    += mainwindow.ui
              

              and set -qws in argument and suddenly see the project run on my device BUT the touch is not worked
              when I copy the file to my device as I said above* the app is can not run. what is the different from my code runable and qt runable app?

              H.Ghassami

              1 Reply Last reply
              0
              • SGaistS Offline
                SGaistS Offline
                SGaist
                Lifetime Qt Champion
                wrote on last edited by
                #40

                Why don't you upload it directly to your device ?
                Using e.g. scp ?

                Interested in AI ? www.idiap.ch
                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                1 Reply Last reply
                0
                • MhM93M Offline
                  MhM93M Offline
                  MhM93
                  wrote on last edited by
                  #41

                  sorry , but what is SCP?
                  I don't know other way to transferring my app to my device

                  H.Ghassami

                  jsulmJ 1 Reply Last reply
                  0
                  • MhM93M MhM93

                    sorry , but what is SCP?
                    I don't know other way to transferring my app to my device

                    jsulmJ Offline
                    jsulmJ Offline
                    jsulm
                    Lifetime Qt Champion
                    wrote on last edited by jsulm
                    #42

                    @MhM93 Why don't you use Google?
                    First match there for "scp" is: https://en.wikipedia.org/wiki/Secure_copy

                    https://forum.qt.io/topic/113070/qt-code-of-conduct

                    1 Reply Last reply
                    0
                    • MhM93M Offline
                      MhM93M Offline
                      MhM93
                      wrote on last edited by
                      #43

                      sorry At first I searched it, but I found this:

                      SCP Foundation
                      From Wikipedia, the free encyclopedia
                      SCP Foundation SCP Foundation (emblem).svg
                      The logo of the SCP Foundation
                      Available in English[a]
                      Slogan(s) Secure, Contain, Protect
                      Website www.scp-wiki.net
                      Alexa rank 15,140 (Apr 2017)[3]
                      Registration Required[b]
                      Launched July 19th, 2008[4]
                      Current status Active
                      Content license
                      CC Attribution / Share-Alike 3.0 The SCP Foundation is a fictional organization that is the subject of a web-based collaborative writing project. (SCP stands for "Special Containment Procedures", though it also refers to the organization's slogan of "Secure, Contain, Protect".) The stories generated by the project describe the exploits of the Foundation, supposedly responsible for containing individuals, entities, locations, and objects that violate natural law (referred to as SCPs). The main written works on the SCP Foundation website are articles written in the style of structured internal documentation about the contained SCPs.

                      and I confused what is SCP, sorry for silly ask, excuse me,thanks for secure copy @jsulm and @SGaist
                      thanks for all help
                      thanks a lot with best wishes for you

                      H.Ghassami

                      1 Reply Last reply
                      0
                      • MhM93M Offline
                        MhM93M Offline
                        MhM93
                        wrote on last edited by
                        #44

                        BEST CONFIGURE:

                        sudo ac_cv_func_malloc_0_nonnull=yes ./configure CC=/opt/FriendlyARM/toolchain/4.9.3/bin/arm-none-linux-gnueabihf-gcc CXX=/opt/FriendlyARM/toolchain/4.9.3/bin/arm-none-linux-gnueabihf-g++ --host=arm-none-linux-gnueabihf target=arm-none-linux-gnueabihf --enable-static=yes --enable-shared=yes -prefix=/home/tslib
                        

                        H.Ghassami

                        1 Reply Last reply
                        0
                        • SGaistS Offline
                          SGaistS Offline
                          SGaist
                          Lifetime Qt Champion
                          wrote on last edited by
                          #45

                          Why sudo ? There's no reason to configure nor compile as root.

                          Interested in AI ? www.idiap.ch
                          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                          1 Reply Last reply
                          0
                          • MhM93M Offline
                            MhM93M Offline
                            MhM93
                            wrote on last edited by
                            #46

                            I dont know why but when I omit the sudo command it shows me error to open some files.

                            H.Ghassami

                            1 Reply Last reply
                            0
                            • SGaistS Offline
                              SGaistS Offline
                              SGaist
                              Lifetime Qt Champion
                              wrote on last edited by
                              #47

                              What files ? Where are they ?

                              Usually that's the kind of thing that start to happen when ones tries to solve a problem using sudo "because it works" rather than find the cause of the original problem which generally leads the snake biting its tail because the first use of sudo makes one or more files only owned by root and its group and thus not accessible etc.

                              Interested in AI ? www.idiap.ch
                              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                              1 Reply Last reply
                              0

                              • Login

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • Users
                              • Groups
                              • Search
                              • Get Qt Extensions
                              • Unsolved