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. Android: getting build errors (first time)
Forum Updated to NodeBB v4.3 + New Features

Android: getting build errors (first time)

Scheduled Pinned Locked Moved Solved Mobile and Embedded
5 Posts 3 Posters 407 Views 1 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.
  • M Offline
    M Offline
    mzimmers
    wrote on 1 Dec 2022, 18:42 last edited by mzimmers 12 Apr 2022, 17:12
    #1

    NOTE: I changed the title of this post because I was asking the wrong question.

    Hi all -

    Brand new to Android, both as a user and programmer...this ought to be interesting.

    I have just been given a Galaxy Tab A, and asked to download a Qt app to it. From my reading, it appears I first need to add something called a "System Image" to my Qt configuration. From what I can see, the correct System Image depends on the architecture of the processor in my tablet. My device has a Cortex-A53, which uses the Armv8-A architecture.

    So, do I correctly infer that I should select "Google APIs ARM 64 v8a" as my system image?

    sdk.PNG

    EDIT:

    After a bit more reading, now I'm not sure that I want a system image after all. So, let me ask this:

    How do I download my Qt application to my Android device?

    Thanks...

    J 1 Reply Last reply 2 Dec 2022, 08:52
    0
    • M mzimmers
      1 Dec 2022, 18:42

      NOTE: I changed the title of this post because I was asking the wrong question.

      Hi all -

      Brand new to Android, both as a user and programmer...this ought to be interesting.

      I have just been given a Galaxy Tab A, and asked to download a Qt app to it. From my reading, it appears I first need to add something called a "System Image" to my Qt configuration. From what I can see, the correct System Image depends on the architecture of the processor in my tablet. My device has a Cortex-A53, which uses the Armv8-A architecture.

      So, do I correctly infer that I should select "Google APIs ARM 64 v8a" as my system image?

      sdk.PNG

      EDIT:

      After a bit more reading, now I'm not sure that I want a system image after all. So, let me ask this:

      How do I download my Qt application to my Android device?

      Thanks...

      J Online
      J Online
      J.Hilk
      Moderators
      wrote on 2 Dec 2022, 08:52 last edited by J.Hilk 12 Feb 2022, 08:53
      #2

      @mzimmers said in Android: how to determine which System Image to use?:

      How do I download my Qt application to my Android device?

      make sure your sdk, jdk and ndk is set up correctly:
      19b403a3-d8f5-4051-9fbf-9526f8575544-image.png

      • enable development options on your android device. In those settings enable usb debugging
      • connect your device to your pc, in the popup that follows, allow file transfer
      • select the android kit in qt creator
      • hit build and run, a popup will appear with a list of all detected android devices, select your target
      • let the compile and deploy magic happen
      • enjoy

      Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


      Q: What's that?
      A: It's blue light.
      Q: What does it do?
      A: It turns blue.

      M 1 Reply Last reply 3 Dec 2022, 21:29
      1
      • J Offline
        J Offline
        JoeCFD
        wrote on 2 Dec 2022, 14:47 last edited by
        #3

        google apis intel x86 atom_64 system image is for emulator which is better created in android studio.
        arm 64 v8a system image is for emulator as well, but on arm structure. I installed both.

        1 Reply Last reply
        1
        • J J.Hilk
          2 Dec 2022, 08:52

          @mzimmers said in Android: how to determine which System Image to use?:

          How do I download my Qt application to my Android device?

          make sure your sdk, jdk and ndk is set up correctly:
          19b403a3-d8f5-4051-9fbf-9526f8575544-image.png

          • enable development options on your android device. In those settings enable usb debugging
          • connect your device to your pc, in the popup that follows, allow file transfer
          • select the android kit in qt creator
          • hit build and run, a popup will appear with a list of all detected android devices, select your target
          • let the compile and deploy magic happen
          • enjoy
          M Offline
          M Offline
          mzimmers
          wrote on 3 Dec 2022, 21:29 last edited by
          #4

          @J-Hilk thanks for the detailed steps! My setup didn't work quite the way you outlined -- I didn't get a popup of Android devices, but my device does appear in Creator (so I could select it in my kit). My build is giving me lots of unhelpful error messages:
          build.PNG
          While it isn't explicitly mentioned in the getting started page, one of the Android examples mentions the need to put paths to Perl and my C++ compiler into my PATH environment variable. I haven't done that yet; could this be contributing to these errors?

          Thanks...

          1 Reply Last reply
          0
          • M Offline
            M Offline
            mzimmers
            wrote on 5 Dec 2022, 00:23 last edited by
            #5

            Well, I managed to get it fixed. It needed two things:

            1. I had to comment out a subdirectory in this part of the CMakeLists.txt file:
            set_property(TARGET appaccelbubble APPEND PROPERTY
                  QT_ANDROID_PACKAGE_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}#/android
            )
            
            1. I changed my NDK from 23.1.whatever to 25.1.whatever, based on an old thread here.

            I can see this development exercise is going to be an adventure -- sure are a lot of moving parts to Android development.

            Thanks to all who looked...

            1 Reply Last reply
            1

            1/5

            1 Dec 2022, 18:42

            • Login

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