Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. clang path wrong in build command being generated
Forum Updated to NodeBB v4.3 + New Features

clang path wrong in build command being generated

Scheduled Pinned Locked Moved Solved Installation and Deployment
5 Posts 3 Posters 1.0k 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.
  • G Offline
    G Offline
    gomgom
    wrote on last edited by
    #1

    Hi,
    I just did a clean install of QT after a few months away from my project: Windows 10, QT creator 4.9.1, Android ArmV7 5.12.4, JDK 1.8, Android SDK 23 (6.0 marshmallow).

    I am now trying to compile a project which was ok under 5.9. After a clean, running rebuild gives me this:

    16:33:37: Running steps for project CityZenMobileUser...
    16:33:37: Starting: "C:\Qt\5.12.4\android_armv7\bin\qmake.exe" C:\CityZen\cityzen-mobile\CityZenMobileUser.pro -spec android-clang "CONFIG+=debug" "CONFIG+=qml_debug"
    Project ERROR: Cannot run target compiler 'C:\Android\android-ndk-r10e/toolchains/llvm/prebuilt/windows/bin/clang++'. Output:
    ===================
    ===================
    Maybe you forgot to setup the environment?
    16:33:37: The process "C:\Qt\5.12.4\android_armv7\bin\qmake.exe" exited with code 3.
    Error while building/deploying project CityZenMobileUser (kit: Android for armeabi-v7a (Clang Qt 5.12.4 for Android ARMv7))
    When executing step "qmake"
    16:33:37: Elapsed time: 00:00.
    

    Which cannot work, as there is no 'C:\Android\android-ndk-r10e/toolchains/llvm' folder.
    The proper path is:
    C:\Android\android-ndk-r10e\toolchains\llvm-3.6\prebuilt\windows\bin\

    Under creator, in Tools/Options/Kits/Compilers/, all clang compilers point to the proper folder (llvm-3.6).
    I installed all Android related packages using the latest version of Android Studio.

    I don't really see who is generating this wrong path, any pointers on where to look?

    Thanks!

    G 1 Reply Last reply
    1
    • G gomgom

      Hi,
      I just did a clean install of QT after a few months away from my project: Windows 10, QT creator 4.9.1, Android ArmV7 5.12.4, JDK 1.8, Android SDK 23 (6.0 marshmallow).

      I am now trying to compile a project which was ok under 5.9. After a clean, running rebuild gives me this:

      16:33:37: Running steps for project CityZenMobileUser...
      16:33:37: Starting: "C:\Qt\5.12.4\android_armv7\bin\qmake.exe" C:\CityZen\cityzen-mobile\CityZenMobileUser.pro -spec android-clang "CONFIG+=debug" "CONFIG+=qml_debug"
      Project ERROR: Cannot run target compiler 'C:\Android\android-ndk-r10e/toolchains/llvm/prebuilt/windows/bin/clang++'. Output:
      ===================
      ===================
      Maybe you forgot to setup the environment?
      16:33:37: The process "C:\Qt\5.12.4\android_armv7\bin\qmake.exe" exited with code 3.
      Error while building/deploying project CityZenMobileUser (kit: Android for armeabi-v7a (Clang Qt 5.12.4 for Android ARMv7))
      When executing step "qmake"
      16:33:37: Elapsed time: 00:00.
      

      Which cannot work, as there is no 'C:\Android\android-ndk-r10e/toolchains/llvm' folder.
      The proper path is:
      C:\Android\android-ndk-r10e\toolchains\llvm-3.6\prebuilt\windows\bin\

      Under creator, in Tools/Options/Kits/Compilers/, all clang compilers point to the proper folder (llvm-3.6).
      I installed all Android related packages using the latest version of Android Studio.

      I don't really see who is generating this wrong path, any pointers on where to look?

      Thanks!

      G Offline
      G Offline
      gomgom
      wrote on last edited by
      #2

      OK, I've been stuck on this for a few days now, ready for another clean start. Can anyone point me to:

      • an up to date tutorial on how to install Qt for Andoid dev on windows (targetting a LTS release, if possible 5.12, or 5.9 if not possible)
      • or a table clearly spelling which version of SDK, JDK, NDK etc... is known to work with these versions of Qt

      I've never had much luck working from the official install instructions, there was always an important piece of the puzzle missing, or a bad link to 3rd party package etc... Am I targetting the wrong platform, would things be simpler (dependencies &co) if I was trying this in a Linux environment?

      Thanks in advance, any help appreciated :-)

      jsulmJ J.HilkJ 2 Replies Last reply
      0
      • G gomgom

        OK, I've been stuck on this for a few days now, ready for another clean start. Can anyone point me to:

        • an up to date tutorial on how to install Qt for Andoid dev on windows (targetting a LTS release, if possible 5.12, or 5.9 if not possible)
        • or a table clearly spelling which version of SDK, JDK, NDK etc... is known to work with these versions of Qt

        I've never had much luck working from the official install instructions, there was always an important piece of the puzzle missing, or a bad link to 3rd party package etc... Am I targetting the wrong platform, would things be simpler (dependencies &co) if I was trying this in a Linux environment?

        Thanks in advance, any help appreciated :-)

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

        @gomgom Did you check https://doc.qt.io/qt-5/android-getting-started.html ?
        It says for Qt 5.12 you can use latest NDK/SDK.

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

        1 Reply Last reply
        2
        • G gomgom

          OK, I've been stuck on this for a few days now, ready for another clean start. Can anyone point me to:

          • an up to date tutorial on how to install Qt for Andoid dev on windows (targetting a LTS release, if possible 5.12, or 5.9 if not possible)
          • or a table clearly spelling which version of SDK, JDK, NDK etc... is known to work with these versions of Qt

          I've never had much luck working from the official install instructions, there was always an important piece of the puzzle missing, or a bad link to 3rd party package etc... Am I targetting the wrong platform, would things be simpler (dependencies &co) if I was trying this in a Linux environment?

          Thanks in advance, any help appreciated :-)

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

          hi @gomgom

          since 5.12 your Target SDK for android has to be r18 or newer, since qt makes use of clang support and that was only added in r18

          So 5.12 or newer -> r18 or newer

          5.11 or older on the other hand won't work with r18 or newer for those you have to use an older sdk.

          Be careful, I remember an other user recently posting issues with 20c, So you might want to avoid that one.


          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
          3
          • G Offline
            G Offline
            gomgom
            wrote on last edited by
            #5

            Thanks for the answers. It took me a while to figure out that the JDK has to be rev 1.8. By then, I had also reverted the NDK to r10e which I thought was a safe bet (seemed to support clang, and I indeed saw some warnings concerning rev 20).

            For others, the following seems to work for me:
            JDK 1.8 (https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html)
            NDK r19c (https://developer.android.com/ndk/downloads/older_releases.html)
            SDK 23 (6.0 marshmallow, which I need to support...)
            QT creator 4.9.1, Android ArmV7 5.12.4

            I'm back on track, thanks for your help!

            1 Reply Last reply
            2

            • Login

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