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. No longer able to compile QML application for Android
Forum Updated to NodeBB v4.3 + New Features

No longer able to compile QML application for Android

Scheduled Pinned Locked Moved Solved Mobile and Embedded
7 Posts 3 Posters 2.3k 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.
  • C Offline
    C Offline
    Celal
    wrote on last edited by
    #1

    Hello,

    I am using Qt 5.8 and Qt Creator 4.2 and I am not able to run QML application on Android device on both windows 7 and Ubuntu 16.04.
    I read on the internet that new Android API break a lot of things. Does Qt solve this problem yet?

    I could not find the previous working version of Android SDK. So I am not to able compile. Do you have any suggestions?

    Thanks in advance.

    jsulmJ 1 Reply Last reply
    0
    • C Celal

      Hello,

      I am using Qt 5.8 and Qt Creator 4.2 and I am not able to run QML application on Android device on both windows 7 and Ubuntu 16.04.
      I read on the internet that new Android API break a lot of things. Does Qt solve this problem yet?

      I could not find the previous working version of Android SDK. So I am not to able compile. Do you have any suggestions?

      Thanks in advance.

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

      @Celal What does not work?

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

      C 1 Reply Last reply
      0
      • jsulmJ jsulm

        @Celal What does not work?

        C Offline
        C Offline
        Celal
        wrote on last edited by Celal
        #3

        @jsulm

        Qt Creator is not able to generate the .apk and installs on Android device.

        Here is the my Qt Creator setting
        alt text

        Here is the output when I try to run QML application.

        11:28:16: The process "/usr/bin/make" exited normally.
        11:28:16: Starting: "/usr/bin/make" INSTALL_ROOT=/home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build install
        install -m 755 -p libuntitled1.so /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/libs/armeabi-v7a/libuntitled1.so
        11:28:16: The process "/usr/bin/make" exited normally.
        11:28:16: Starting: "/opt/Qt/5.8/android_armv7/bin/androiddeployqt" --input /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-libuntitled1.so-deployment-settings.json --output /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build --deployment bundled --android-platform android-23 --jdk /usr/lib/jvm/java-8-openjdk-amd64 --ant ant
        Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Material.impl
        Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.impl
        Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Universal.impl
        sh: 1: ant: not found
        Building the android package failed!
          -- For more information, run this command with --verbose.
        Generating Android Package
          Input file: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-libuntitled1.so-deployment-settings.json
          Output directory: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/
          Application binary: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/libuntitled1.so
          Android build platform: android-23
          Install to device: No
        11:28:16: The process "/opt/Qt/5.8/android_armv7/bin/androiddeployqt" exited with code 14.
        Error while building/deploying project untitled1 (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.8.0))
        When executing step "Build Android APK"
        
        

        I also have a problem when creating a simulation device, it does not allow me to so. Here is the screen shot for that

        alt text

        In this dialog, I am not able to set Target API.

        A 1 Reply Last reply
        0
        • C Celal

          @jsulm

          Qt Creator is not able to generate the .apk and installs on Android device.

          Here is the my Qt Creator setting
          alt text

          Here is the output when I try to run QML application.

          11:28:16: The process "/usr/bin/make" exited normally.
          11:28:16: Starting: "/usr/bin/make" INSTALL_ROOT=/home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build install
          install -m 755 -p libuntitled1.so /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/libs/armeabi-v7a/libuntitled1.so
          11:28:16: The process "/usr/bin/make" exited normally.
          11:28:16: Starting: "/opt/Qt/5.8/android_armv7/bin/androiddeployqt" --input /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-libuntitled1.so-deployment-settings.json --output /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build --deployment bundled --android-platform android-23 --jdk /usr/lib/jvm/java-8-openjdk-amd64 --ant ant
          Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Material.impl
          Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.impl
          Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Universal.impl
          sh: 1: ant: not found
          Building the android package failed!
            -- For more information, run this command with --verbose.
          Generating Android Package
            Input file: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-libuntitled1.so-deployment-settings.json
            Output directory: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/
            Application binary: /home/cs1323/workspace/build-untitled1-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/libuntitled1.so
            Android build platform: android-23
            Install to device: No
          11:28:16: The process "/opt/Qt/5.8/android_armv7/bin/androiddeployqt" exited with code 14.
          Error while building/deploying project untitled1 (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.8.0))
          When executing step "Build Android APK"
          
          

          I also have a problem when creating a simulation device, it does not allow me to so. Here is the screen shot for that

          alt text

          In this dialog, I am not able to set Target API.

          A Offline
          A Offline
          ambershark
          wrote on last edited by
          #4

          @Celal said in No longer able to compile QML application for Android:

          sh: 1: ant: not found

          There's your problem. It's trying to use ant to build and can't find it on your system. Has nothing to do with Qt at all. Install ant using your distribution's package manager and you should be good to go.

          My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

          C 1 Reply Last reply
          0
          • A ambershark

            @Celal said in No longer able to compile QML application for Android:

            sh: 1: ant: not found

            There's your problem. It's trying to use ant to build and can't find it on your system. Has nothing to do with Qt at all. Install ant using your distribution's package manager and you should be good to go.

            C Offline
            C Offline
            Celal
            wrote on last edited by
            #5

            @ambershark

            I fixed the ant and still have the problem with creating the android packages. This is happening when I use Qt 5.8.

            Anyway, the good news is I am able to compile and create android package with Qt 5.9, I am using grandle instead of ant and everything working great.

            So, I am still not able to create a virtual device but I can deploy the application on my android device.

            I will close this problem since I have no idea what is the problem.

            Thank you so much for your time.

            Celal

            A 1 Reply Last reply
            0
            • C Celal

              @ambershark

              I fixed the ant and still have the problem with creating the android packages. This is happening when I use Qt 5.8.

              Anyway, the good news is I am able to compile and create android package with Qt 5.9, I am using grandle instead of ant and everything working great.

              So, I am still not able to create a virtual device but I can deploy the application on my android device.

              I will close this problem since I have no idea what is the problem.

              Thank you so much for your time.

              Celal

              A Offline
              A Offline
              ambershark
              wrote on last edited by
              #6

              @Celal Glad you got it working. That is weird. It could be a 5.8 bug but I know others have deployed with 5.8 just fine.

              Maybe something with your configuration. Either way it sounds like you figured it out so no worries. I hate not knowing why something broke though. :)

              My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

              C 1 Reply Last reply
              0
              • A ambershark

                @Celal Glad you got it working. That is weird. It could be a 5.8 bug but I know others have deployed with 5.8 just fine.

                Maybe something with your configuration. Either way it sounds like you figured it out so no worries. I hate not knowing why something broke though. :)

                C Offline
                C Offline
                Celal
                wrote on last edited by Celal
                #7

                @ambershark

                Thank you. I feel you, I hate it too. But you know I, know something wrong with 5.8 configurations. Because I have tried many different kinds of things so somehow I messed up the conf. Anyway, my plan is to try same things on fresh install Linux machine and see if I am still not able to compile with 5.8.

                These days, I do not have time to do so. When I try it I will post here, hopefully, I will not forget.

                1 Reply Last reply
                1

                • Login

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