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. CMake error 'The CXX compiler identification is unknown' for Android developing only
Forum Updated to NodeBB v4.3 + New Features

CMake error 'The CXX compiler identification is unknown' for Android developing only

Scheduled Pinned Locked Moved Solved Mobile and Embedded
2 Posts 1 Posters 41 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.
  • G Offline
    G Offline
    glafauci61
    wrote last edited by
    #1

    Hi to all,
    I installed QT 6.9.1 on kubuntu linux. I try to compile a demo app, exactly 'calqlatr'.
    First I tried to compile as a desktop app. All OK.

    Then I tried to compile for Android, choosing the x86_64 kit. As I set the kit in the 'Projects' tab, I received the following message:

    Screenshot_20250807_101125.png

    So, I went to 'General messages' and I read this:

    [cmake] Running /home/glafauci61/Programmi/QT6/QT/Tools/CMake/bin/cmake -S /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr -B /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug in /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug.
    [cmake] -- Android: Selected unified Clang toolchain
    [cmake] -- The CXX compiler identification is unknown
    [cmake] -- Detecting CXX compiler ABI info
    [cmake] -- Detecting CXX compiler ABI info - failed
    [cmake] -- Check for working CXX compiler: /home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++
    [cmake] -- Check for working CXX compiler: /home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++ - broken
    [cmake] CMake Error at /home/glafauci61/Programmi/QT6/QT/Tools/CMake/share/cmake-3.30/Modules/CMakeTestCXXCompiler.cmake:73 (message):
    [cmake]   The C++ compiler
    [cmake]
    [cmake]     "/home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++"
    [cmake]
    [cmake]   is not able to compile a simple test program.
    [cmake]
    [cmake]   It fails with the following output:
    [cmake]
    [cmake]     Change Dir: '/home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug/CMakeFiles/CMakeScratch/TryCompile-PfFPuk'
    [cmake]
    [cmake]     Run Build Command(s): /home/glafauci61/Programmi/QT6/QT/Tools/Ninja/ninja -v cmTC_a24ef
    [cmake]     [1/2] /home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++   -DQT_QML_DEBUG -o CMakeFiles/cmTC_a24ef.dir/testCXXCompiler.cxx.o -c /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug/CMakeFiles/CMakeScratch/TryCompile-PfFPuk/testCXXCompiler.cxx
    [cmake]     FAILED: CMakeFiles/cmTC_a24ef.dir/testCXXCompiler.cxx.o
    [cmake]     /home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++   -DQT_QML_DEBUG -o CMakeFiles/cmTC_a24ef.dir/testCXXCompiler.cxx.o -c /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug/CMakeFiles/CMakeScratch/TryCompile-PfFPuk/testCXXCompiler.cxx
    [cmake]     /home/glafauci61/Programmi/QT6/SDK-commandLineTools/cmdline-tools/ndk/android-ndk-r28/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++: 1: clang: not found
    [cmake]     ninja: build stopped: subcommand failed.
    [cmake]
    [cmake]
    [cmake]
    [cmake]
    [cmake]
    [cmake]   CMake will not be able to correctly generate this project.
    [cmake] Call Stack (most recent call first):
    [cmake]   CMakeLists.txt:5 (project)
    [cmake]
    [cmake]
    [cmake] -- Configuring incomplete, errors occurred!
    [cmake]
    [cmake] The command "/home/glafauci61/Programmi/QT6/QT/Tools/CMake/bin/cmake -S /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr -B /home/glafauci61/Programmi/QT6/QT/Examples/Qt-6.9.1/demos/calqlatr/build/Android_Qt_6_9_1_Clang_x86_64-Debug" terminated with exit code 1.
    [cmake]
    [cmake] Elapsed time: 00:00.
    
    

    Surprised, I went back to Desktop kit and retried: the compilation is OK, and the app runs perfectly.

    I tried to use other android kits, but all of them fails with the same output.

    Anyone can help me?

    1 Reply Last reply
    0
    • G Offline
      G Offline
      glafauci61
      wrote last edited by
      #2

      Hello, I solved the problem uninstalling all QT suite and reinstalling it.
      Everything is fine.

      Bye

      1 Reply Last reply
      0
      • G glafauci61 has marked this topic as solved

      • Login

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