Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Unable to debug Android App (Windows + Qt Creator 12 + LLDB)

Unable to debug Android App (Windows + Qt Creator 12 + LLDB)

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
169 Posts 9 Posters 61.6k Views
  • 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.
  • JonBJ JonB

    @CodesInChaoss
    Ah, I did not know about that licence's terms.

    I'm not sure whether in "QT's internal segmentation faults" you mean Qt itself or Qt Creator. I would be worried about either, certainly if Qt code itself in your application is faulting, but I don't know what "workarounds" you need/have to live with for your situation.

    Be aware that even without paid support you can raise bugs, against either Qt or Creator, at https://bugreports.qt.io/. People there look at them and respond/fix, regardless of OP's license state. I think Creator is regularly undergoing new releases, I don't know how robust it is for Android stuff.

    C Offline
    C Offline
    CodesInChaoss
    wrote on last edited by
    #51

    @JonB

    yes yes yes dear friend I know... I've been raising bugs from a different account for years ... we've all been developing QT since then kicked us in the ass years ago and run away with source code.

    I know I can.

    Then I get to wait 1-2 years till fix-ups make their way into commercial license and another 2 years into open source.

    I know.

    C 1 Reply Last reply
    0
    • C CodesInChaoss

      @JonB

      yes yes yes dear friend I know... I've been raising bugs from a different account for years ... we've all been developing QT since then kicked us in the ass years ago and run away with source code.

      I know I can.

      Then I get to wait 1-2 years till fix-ups make their way into commercial license and another 2 years into open source.

      I know.

      C Offline
      C Offline
      CodesInChaoss
      wrote on last edited by
      #52

      As of now

      • we are manually overriding QT's Segmentation Fault events
      • overriding Sig33 signals (bionic hardware)

      Under the above conditions we are able to debug through QT Creator 12 and GDB with Qt 5.15.16 BUT

      • removal of any breakpoint causes the GDB connection to become corrupted.
      • no further debugging would be possible

      Anyway, we CAN live with that (hopefully).

      The most pressing issue is - how to force the mobile app to actually wait for QT Creator to fully attach?

      I don't know the details but it seems that QT Creator 12 attached through GDB, the app knows.. BUT... NO BREAKPOINTS WOULD FIRE FOR 2-3 minutes at all (creator would keep showing that it's still attaching during that time period).

      C 1 Reply Last reply
      0
      • C CodesInChaoss

        As of now

        • we are manually overriding QT's Segmentation Fault events
        • overriding Sig33 signals (bionic hardware)

        Under the above conditions we are able to debug through QT Creator 12 and GDB with Qt 5.15.16 BUT

        • removal of any breakpoint causes the GDB connection to become corrupted.
        • no further debugging would be possible

        Anyway, we CAN live with that (hopefully).

        The most pressing issue is - how to force the mobile app to actually wait for QT Creator to fully attach?

        I don't know the details but it seems that QT Creator 12 attached through GDB, the app knows.. BUT... NO BREAKPOINTS WOULD FIRE FOR 2-3 minutes at all (creator would keep showing that it's still attaching during that time period).

        C Offline
        C Offline
        CodesInChaoss
        wrote on last edited by
        #53

        We may add a Sleep for 5 minutes.. in the initial main() loop

        but come on folks.. that is not the way we are supposed to work... is it

        C 1 Reply Last reply
        0
        • C CodesInChaoss

          We may add a Sleep for 5 minutes.. in the initial main() loop

          but come on folks.. that is not the way we are supposed to work... is it

          C Offline
          C Offline
          CodesInChaoss
          wrote on last edited by
          #54
          I System.out: Debugger has connected
          I System.out: waiting for debugger to settle...
          I System.out: waiting for debugger to settle...
          I System.out: debugger detached?
          

          that's also present when debugging with GDB.

          C 1 Reply Last reply
          0
          • C CodesInChaoss
            I System.out: Debugger has connected
            I System.out: waiting for debugger to settle...
            I System.out: waiting for debugger to settle...
            I System.out: debugger detached?
            

            that's also present when debugging with GDB.

            C Offline
            C Offline
            CodesInChaoss
            wrote on last edited by
            #55
            Use the "info sharedlibrary" command to see the complete listing.
            Do you need "set solib-search-path" or "set sysroot"?The index cache directory name is empty, skipping store.
            The index cache directory name is empty, skipping store.
            The index cache directory name is empty, skipping store.
            Unable to find dynamic linker breakpoint function.
            GDB will be unable to debug shared library initializers
            and track explicitly loaded dynamic code.
            
            C 1 Reply Last reply
            0
            • C CodesInChaoss
              Use the "info sharedlibrary" command to see the complete listing.
              Do you need "set solib-search-path" or "set sysroot"?The index cache directory name is empty, skipping store.
              The index cache directory name is empty, skipping store.
              The index cache directory name is empty, skipping store.
              Unable to find dynamic linker breakpoint function.
              GDB will be unable to debug shared library initializers
              and track explicitly loaded dynamic code.
              
              C Offline
              C Offline
              CodesInChaoss
              wrote on last edited by CodesInChaoss
              #56

              AFTER disabling

              • wait for debugger in Android Developer Settings (on mobile)
                AND
              • after REMOVING the debugged application from the list of debugged applications ON ANDROID DEVICE

              we are able to get have breakpoints working WAY SOONER (!!!)
              now that i strange on the grounds of its own, is it not.....

              but STILL unable to have breakpoints at main() stage working at all.

              Yet again we are talking about QT Creator 12 + GDB + Qt 5.15.16 (LTS)

              so the pressing issues are

              • get to know how to break as soon as in main() - normal thing to be expected
              • what the heck are sig-faults in Qt related code?
              C 1 Reply Last reply
              0
              • C CodesInChaoss

                AFTER disabling

                • wait for debugger in Android Developer Settings (on mobile)
                  AND
                • after REMOVING the debugged application from the list of debugged applications ON ANDROID DEVICE

                we are able to get have breakpoints working WAY SOONER (!!!)
                now that i strange on the grounds of its own, is it not.....

                but STILL unable to have breakpoints at main() stage working at all.

                Yet again we are talking about QT Creator 12 + GDB + Qt 5.15.16 (LTS)

                so the pressing issues are

                • get to know how to break as soon as in main() - normal thing to be expected
                • what the heck are sig-faults in Qt related code?
                C Offline
                C Offline
                CodesInChaoss
                wrote on last edited by
                #57

                so seems like nobody (as usually) can assist around here even in questions regarding basic debugging.... this community is such a shame...

                JoeCFDJ TomZT 2 Replies Last reply
                0
                • C CodesInChaoss

                  so seems like nobody (as usually) can assist around here even in questions regarding basic debugging.... this community is such a shame...

                  JoeCFDJ Offline
                  JoeCFDJ Offline
                  JoeCFD
                  wrote on last edited by JoeCFD
                  #58

                  @CodesInChaoss Maybe try to do it on Linux and it could be easier. The executable is same.

                  C 1 Reply Last reply
                  0
                  • C CodesInChaoss

                    so seems like nobody (as usually) can assist around here even in questions regarding basic debugging.... this community is such a shame...

                    TomZT Offline
                    TomZT Offline
                    TomZ
                    wrote on last edited by TomZ
                    #59

                    @CodesInChaoss said in Unable to debug Android App (Windows + Qt Creator 12 + LLDB):

                    so seems like nobody (as usually) can assist around here even in questions regarding basic debugging.... this community is such a shame

                    A lot of lazy devs here ;-)

                    I'm especially interested in Qt because of its cross-platform ability. I do 90% of my android development in a native compile, with a window on my desktop. Have had maybe once or twice the wish to have a debugger for my remote Android device, but never found it important enough to install the tools for that. Qt Android tools are too freaking huge.

                    So, I'm lazy and debug on the native app on my desktop. Then do testing on the device, which rarely gives me issues I could not see on the desktop.

                    Not saying that what you want is wrong or anything like that. If QtCreator tells you that breakpoints should work, then they should work. And a paying customer should be able to demand attention from the Qt company.

                    I'm not a paying customer, no support for me.
                    Plenty of problems with the new Qt company of the last years, gerrit sucks. Jira even more so. As an open source programmer I have zero incentive to report bugs for the LTS releases since I'd wait at minimum a full year for a bugfix. And the quality is just really quite sad for Android. But it still is better than most alternatives I've tried. So here we are :-)

                    C 1 Reply Last reply
                    0
                    • TomZT TomZ

                      @CodesInChaoss said in Unable to debug Android App (Windows + Qt Creator 12 + LLDB):

                      so seems like nobody (as usually) can assist around here even in questions regarding basic debugging.... this community is such a shame

                      A lot of lazy devs here ;-)

                      I'm especially interested in Qt because of its cross-platform ability. I do 90% of my android development in a native compile, with a window on my desktop. Have had maybe once or twice the wish to have a debugger for my remote Android device, but never found it important enough to install the tools for that. Qt Android tools are too freaking huge.

                      So, I'm lazy and debug on the native app on my desktop. Then do testing on the device, which rarely gives me issues I could not see on the desktop.

                      Not saying that what you want is wrong or anything like that. If QtCreator tells you that breakpoints should work, then they should work. And a paying customer should be able to demand attention from the Qt company.

                      I'm not a paying customer, no support for me.
                      Plenty of problems with the new Qt company of the last years, gerrit sucks. Jira even more so. As an open source programmer I have zero incentive to report bugs for the LTS releases since I'd wait at minimum a full year for a bugfix. And the quality is just really quite sad for Android. But it still is better than most alternatives I've tried. So here we are :-)

                      C Offline
                      C Offline
                      CodesInChaoss
                      wrote on last edited by
                      #60

                      Article

                      ^------ what a F***** joke.... talked with a QT lady over phone today they ask for 3800 EURO a year (per seat) for a license with Technical Support

                      C 1 Reply Last reply
                      0
                      • C CodesInChaoss

                        Article

                        ^------ what a F***** joke.... talked with a QT lady over phone today they ask for 3800 EURO a year (per seat) for a license with Technical Support

                        C Offline
                        C Offline
                        CodesInChaoss
                        wrote on last edited by CodesInChaoss
                        #61

                        the funniest thing of all is we've got an immense code base already so if we do not solve the issues above (LLDB - unable to debug at all) and GDB crashing all the time with all the other crazy shit going on - we would be FORCED to pay the above in HOPES they manage to give us some helpful hand.

                        Go figure.

                        C 1 Reply Last reply
                        0
                        • C CodesInChaoss

                          the funniest thing of all is we've got an immense code base already so if we do not solve the issues above (LLDB - unable to debug at all) and GDB crashing all the time with all the other crazy shit going on - we would be FORCED to pay the above in HOPES they manage to give us some helpful hand.

                          Go figure.

                          C Offline
                          C Offline
                          CodesInChaoss
                          wrote on last edited by
                          #62

                          we're just too afraid they gonna say hey see - IT WORKS WITH A HELLO WORLD

                          C 1 Reply Last reply
                          0
                          • C CodesInChaoss

                            we're just too afraid they gonna say hey see - IT WORKS WITH A HELLO WORLD

                            C Offline
                            C Offline
                            CodesInChaoss
                            wrote on last edited by CodesInChaoss
                            #63

                            it all feels like there are some race condition issues or whatever...

                            it some times (on 3% of occasions) works PERFECTLY.

                            AFTER WE"VE INTRODUCE CUSTOM OVERRIDED TO SIG_FAULTS THROWN UPON US from QT.

                            as of now , as it is on current setup.

                            while on 97% of occasions it's UNUSABLE.

                            And that's a thing to worry about.

                            Creator dying every now and then... same for GDB... LLDB unusable.. breakpoints working on some occasions.. skipped other times...debugger kicking in late.....

                            it doesn't take a genius to notice that it's that's the case on QT Creator 12 with QT 5.15.16 on default settings and NDK/SDK installed by Creator itself, something is not right

                            C 1 Reply Last reply
                            0
                            • C CodesInChaoss

                              it all feels like there are some race condition issues or whatever...

                              it some times (on 3% of occasions) works PERFECTLY.

                              AFTER WE"VE INTRODUCE CUSTOM OVERRIDED TO SIG_FAULTS THROWN UPON US from QT.

                              as of now , as it is on current setup.

                              while on 97% of occasions it's UNUSABLE.

                              And that's a thing to worry about.

                              Creator dying every now and then... same for GDB... LLDB unusable.. breakpoints working on some occasions.. skipped other times...debugger kicking in late.....

                              it doesn't take a genius to notice that it's that's the case on QT Creator 12 with QT 5.15.16 on default settings and NDK/SDK installed by Creator itself, something is not right

                              C Offline
                              C Offline
                              CodesInChaoss
                              wrote on last edited by
                              #64

                              Go ahead and try setup QT Creator 12 and Android SDK on fresh Windows 11

                              Kits won't get created (..) openssl won't get downloaded. it's all messed up

                              C 1 Reply Last reply
                              0
                              • C CodesInChaoss

                                Go ahead and try setup QT Creator 12 and Android SDK on fresh Windows 11

                                Kits won't get created (..) openssl won't get downloaded. it's all messed up

                                C Offline
                                C Offline
                                CodesInChaoss
                                wrote on last edited by
                                #65

                                890fcd14-8969-4a70-bca0-fee02e2add0a-image.png @CodesInChaoss

                                one of many examples on fresh windows install through online installer Commercial edition

                                C 1 Reply Last reply
                                0
                                • C CodesInChaoss

                                  890fcd14-8969-4a70-bca0-fee02e2add0a-image.png @CodesInChaoss

                                  one of many examples on fresh windows install through online installer Commercial edition

                                  C Offline
                                  C Offline
                                  CodesInChaoss
                                  wrote on last edited by
                                  #66

                                  dc118e86-fa94-4206-b6b5-6555b18ff0f8-image.png @CodesInChaoss

                                  1 Reply Last reply
                                  0
                                  • C CodesInChaoss

                                    0fb31d8f-f5aa-4aa4-b5be-ec2c92d26c8a-image.png @CodesInChaoss

                                    Why all my KIts' settings get WIPED OUT after the crash?

                                    JoeCFDJ Offline
                                    JoeCFDJ Offline
                                    JoeCFD
                                    wrote on last edited by
                                    #67

                                    @CodesInChaoss did you click apply button after resetting.

                                    C 1 Reply Last reply
                                    0
                                    • JoeCFDJ JoeCFD

                                      @CodesInChaoss did you click apply button after resetting.

                                      C Offline
                                      C Offline
                                      CodesInChaoss
                                      wrote on last edited by
                                      #68

                                      @JoeCFD yes as of now, we've deployed like 3 VMs already , we're diving into crazy things such as updating maveen, gradle, checking any binary dependancies, diving deep into the internals of GDB..... it does NOT work.

                                      take a look at what official Android site says about debugging with GDB
                                      53285794-2421-43ee-9b3c-2d5b67065587-image.png

                                      C 1 Reply Last reply
                                      0
                                      • C CodesInChaoss

                                        @JoeCFD yes as of now, we've deployed like 3 VMs already , we're diving into crazy things such as updating maveen, gradle, checking any binary dependancies, diving deep into the internals of GDB..... it does NOT work.

                                        take a look at what official Android site says about debugging with GDB
                                        53285794-2421-43ee-9b3c-2d5b67065587-image.png

                                        C Offline
                                        C Offline
                                        CodesInChaoss
                                        wrote on last edited by CodesInChaoss
                                        #69

                                        Let me emphasize - all was fine with QT 5.15.12 and OLD Creator 10 community edition over GDB.

                                        C 1 Reply Last reply
                                        0
                                        • C CodesInChaoss

                                          Let me emphasize - all was fine with QT 5.15.12 and OLD Creator 10 community edition over GDB.

                                          C Offline
                                          C Offline
                                          CodesInChaoss
                                          wrote on last edited by
                                          #70

                                          17246980-0d1c-429c-8378-0d3a5d35c6b8-image.png @CodesInChaoss

                                          All the time while playing around with settings, while editing and saving QT Creator 12 would deploy new kits..... forgetting some settings... like the yellow triangle next to each is about missing compiler settings.. and of course.. it was set

                                          C 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