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 SDK installation is missing necessary packages.
Forum Updated to NodeBB v4.3 + New Features

Android SDK installation is missing necessary packages.

Scheduled Pinned Locked Moved Solved Mobile and Embedded
14 Posts 9 Posters 4.4k Views 3 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.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #2

    Hi and welcome to devnet,

    What exactly did you install ?
    How did you install 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
    • K Offline
      K Offline
      KlausF
      wrote on last edited by
      #3

      Hi, I have installed Qt Creator and Android Studio using their installation wizards and not changing any of the suggested installation folders. Both applications work.
      What it boils down to is shown in the screenshot, under Creator -> Tools -> Options -> Devices -> Android I get the red cross for "Platform SDK installed". When I select "yes" for downloading the missing packages nothing happens. All the available Android flavors are present in the /home/user1/Android/Sdk/platforms/ folder.
      As you can see in the screenshot now I'm using /usr/lib64/jvm/java-11-openjdk-11, but I have tried the downgrade to the previously suggested java version and it did not help.
      I'm new to Qt and I hope I do not miss something obvious.
      Thank you.
      0_1566111458166_Screenshot_2019-08-18_08-40-20.jpeg

      T J.HilkJ 2 Replies Last reply
      0
      • K KlausF

        Hi, I have installed Qt Creator and Android Studio using their installation wizards and not changing any of the suggested installation folders. Both applications work.
        What it boils down to is shown in the screenshot, under Creator -> Tools -> Options -> Devices -> Android I get the red cross for "Platform SDK installed". When I select "yes" for downloading the missing packages nothing happens. All the available Android flavors are present in the /home/user1/Android/Sdk/platforms/ folder.
        As you can see in the screenshot now I'm using /usr/lib64/jvm/java-11-openjdk-11, but I have tried the downgrade to the previously suggested java version and it did not help.
        I'm new to Qt and I hope I do not miss something obvious.
        Thank you.
        0_1566111458166_Screenshot_2019-08-18_08-40-20.jpeg

        T Offline
        T Offline
        Tom_H
        wrote on last edited by
        #4

        @klausf Don't use Qt Creator to manage the Android SDK. Use Android Studio. My suggestion:

        • Uninstall everything
        • Install Android Studio
        • Use Android Studio to install the Android SDK (and NDK)
        • Install Qt

        The Qt installation will detect the Android SDK. That's the way I do it. Good luck.

        1 Reply Last reply
        0
        • K Offline
          K Offline
          KlausF
          wrote on last edited by
          #5

          Hi, Tom_H, thanks for your suggestion. Indeed, my sequence of installation was Creator first and Android studio second.
          So I followed your advice and installed Android Studio along with the SDKs first, and after that I've installed Qt Creator. Unfortunately to no avail, please see screenshot.
          0_1566202536462_Screenshot_2019-08-19_10-03-50.jpeg

          1 Reply Last reply
          0
          • T Offline
            T Offline
            Tom_H
            wrote on last edited by
            #6

            @klausf Silly question: did you install the Android platform for Qt?

            screenshot

            1 Reply Last reply
            0
            • K KlausF

              Hi, I have installed Qt Creator and Android Studio using their installation wizards and not changing any of the suggested installation folders. Both applications work.
              What it boils down to is shown in the screenshot, under Creator -> Tools -> Options -> Devices -> Android I get the red cross for "Platform SDK installed". When I select "yes" for downloading the missing packages nothing happens. All the available Android flavors are present in the /home/user1/Android/Sdk/platforms/ folder.
              As you can see in the screenshot now I'm using /usr/lib64/jvm/java-11-openjdk-11, but I have tried the downgrade to the previously suggested java version and it did not help.
              I'm new to Qt and I hope I do not miss something obvious.
              Thank you.
              0_1566111458166_Screenshot_2019-08-18_08-40-20.jpeg

              J.HilkJ Offline
              J.HilkJ Offline
              J.Hilk
              Moderators
              wrote on last edited by
              #7

              hi @klausf
              in my past I had only issues with android studio as the source tor the android kits.
              It messes with path's & linkings.

              That's why I switch to the command line tools a long while ago. Much less heavy on the HD too!

              You get those rather simply by clicking on the download icon (green arrow pointing down) in the android settings of QtC

              0_1566277889628_22219cc5-6ba4-4e58-b764-d33589b96279-image.png


              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.

              1 Reply Last reply
              0
              • K Offline
                K Offline
                KlausF
                wrote on last edited by
                #8

                Hi, Tom_H, I sure did install those, please see screenshot.
                0_1566289227718_Screenshot_2019-08-20_10-18-11.png
                J.Hilk, I have tried this, too. The click on the little green arrow takes me to the Android Developer page where I can choose to install Android Studio or just the Android command line tools only ( under MacOS this might be different ).
                Anyway, with the installation of Android Studio I get everything needed in its correct place/folder and I get everything ticked off in green.
                Except for the red cross at "Platform SDK installed" although those SDKs are right there in the selected folder ( /home/user1/Android/Sdk ).
                0_1566290418863_Screenshot_2019-08-20_10-39-33.png
                Would you please let me know whats inside your folder for the Android SDK location ( in your screenshot: what's inside "Android SDK location: /Library/Android" ) ? Thank you.

                1 Reply Last reply
                0
                • I Offline
                  I Offline
                  Ibrahim
                  wrote on last edited by Ibrahim
                  #9

                  As far as I know Android SDK needs JDK 8. It is not working with JDK 11.
                  Edit: There is JDK 8 in Android Studio path. Example : android-studio/jre

                  1 Reply Last reply
                  0
                  • K Offline
                    K Offline
                    KlausF
                    wrote on last edited by
                    #10

                    Hello,
                    after another install from scratch everything's fine now. This subject can be closed.
                    Thanks.

                    Pablo J. RoginaP 1 Reply Last reply
                    0
                    • K KlausF

                      Hello,
                      after another install from scratch everything's fine now. This subject can be closed.
                      Thanks.

                      Pablo J. RoginaP Offline
                      Pablo J. RoginaP Offline
                      Pablo J. Rogina
                      wrote on last edited by
                      #11

                      @klausf said in Android SDK installation is missing necessary packages.:

                      This subject can be closed

                      You need to mark your post as solved! Thanks.

                      Upvote the answer(s) that helped you solve the issue
                      Use "Topic Tools" button to mark your post as Solved
                      Add screenshots via postimage.org
                      Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                      1 Reply Last reply
                      0
                      • H Offline
                        H Offline
                        Hai Long Tran
                        wrote on last edited by
                        #12

                        i have the same problems with a big red X on "Platform SDK installed" line, and a truncated version of this error msg when i try to install missing packages. (using windows 10)
                        i found out that the error msg is because qt creator was trying to run sdkmanager to install the missing package.
                        tried to run it myself in cmd, getting this error which is due to removal of support in jdk for java.se.ee after jdk11+
                        downgraded to jdk 8 and it works now.
                        in case it helps anyone else stumbling on this same problem

                        D:\SDK\Android\sdk\tools\bin>sdkmanager.bat
                        Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema
                                at com.android.repository.api.SchemaModule$SchemaModuleVersion.<init>(SchemaModule.java:156)
                                at com.android.repository.api.SchemaModule.<init>(SchemaModule.java:75)
                                at com.android.sdklib.repository.AndroidSdkHandler.<clinit>(AndroidSdkHandler.java:81)
                                at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:73)
                                at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48)
                        Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlSchema
                                at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:602)
                                at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
                                at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
                                ... 5 more
                        
                        QtProgrammerJoshQ 1 Reply Last reply
                        1
                        • H Hai Long Tran

                          i have the same problems with a big red X on "Platform SDK installed" line, and a truncated version of this error msg when i try to install missing packages. (using windows 10)
                          i found out that the error msg is because qt creator was trying to run sdkmanager to install the missing package.
                          tried to run it myself in cmd, getting this error which is due to removal of support in jdk for java.se.ee after jdk11+
                          downgraded to jdk 8 and it works now.
                          in case it helps anyone else stumbling on this same problem

                          D:\SDK\Android\sdk\tools\bin>sdkmanager.bat
                          Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema
                                  at com.android.repository.api.SchemaModule$SchemaModuleVersion.<init>(SchemaModule.java:156)
                                  at com.android.repository.api.SchemaModule.<init>(SchemaModule.java:75)
                                  at com.android.sdklib.repository.AndroidSdkHandler.<clinit>(AndroidSdkHandler.java:81)
                                  at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:73)
                                  at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48)
                          Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlSchema
                                  at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:602)
                                  at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
                                  at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
                                  ... 5 more
                          
                          QtProgrammerJoshQ Offline
                          QtProgrammerJoshQ Offline
                          QtProgrammerJosh
                          wrote on last edited by
                          #13

                          @Hai-Long-Tran, this absolutely worked for me. Kubuntu 18.04 LTS

                          1 Reply Last reply
                          0
                          • D Offline
                            D Offline
                            dhwanipatil
                            Banned
                            wrote on last edited by dhwanipatil
                            #14
                            This post is deleted!
                            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