Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to get active kit in source code?
QtWS25 Last Chance

How to get active kit in source code?

Scheduled Pinned Locked Moved Solved General and Desktop
7 Posts 3 Posters 1.6k 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.
  • kahlenbergK Offline
    kahlenbergK Offline
    kahlenberg
    wrote on last edited by
    #1

    Hi,
    I am making a project for ARM platform using cross-compiling on Linux. I have set two kits, one for Desktop (gcc) and one for ARM (arm-linux...). It works on both platform. I want to "know" which kit is currently active in source code.

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mostefa
      wrote on last edited by
      #2

      Hi @kahlenberg

      There is screen icon on the left menu in qt creator, you have to click in this icon to know which kit is used for know

      alt text

      1 Reply Last reply
      0
      • kahlenbergK Offline
        kahlenbergK Offline
        kahlenberg
        wrote on last edited by kahlenberg
        #3

        :) I know, but my question is how can I get this information in source code or during runtime?

        M 1 Reply Last reply
        0
        • kahlenbergK kahlenberg

          :) I know, but my question is how can I get this information in source code or during runtime?

          M Offline
          M Offline
          mostefa
          wrote on last edited by mostefa
          #4

          @kahlenberg said in How to get active kit in source code?:

          :) I know, but my question is how can I get this information in source code?

          Oh sorry

          you can use currentCpuArchitecture if you are using qt5

          http://doc.qt.io/qt-5/qsysinfo.html#currentCpuArchitecture

          1 Reply Last reply
          1
          • kahlenbergK Offline
            kahlenbergK Offline
            kahlenberg
            wrote on last edited by
            #5

            Ok, Thank you. It is not exactly what i am looking for but it is also useful.
            Thanks.

            M 1 Reply Last reply
            0
            • kahlenbergK kahlenberg

              Ok, Thank you. It is not exactly what i am looking for but it is also useful.
              Thanks.

              M Offline
              M Offline
              mostefa
              wrote on last edited by
              #6

              @kahlenberg said in How to get active kit in source code?:

              Ok, Thank you. It is not exactly what i am looking for but it is also useful.
              Thanks.

              You are looking for the exact name of your kit?

              As far as i know we can not get this information in source code,

              But who knows ...

              1 Reply Last reply
              0
              • SGaistS Offline
                SGaistS Offline
                SGaist
                Lifetime Qt Champion
                wrote on last edited by
                #7

                Hi,

                Why exactly do you need to know that in your sources ?

                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

                • Login

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