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. manually build debug from cmd or terminal consoles..
QtWS25 Last Chance

manually build debug from cmd or terminal consoles..

Scheduled Pinned Locked Moved Solved General and Desktop
5 Posts 4 Posters 427 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.
  • U Offline
    U Offline
    U7Development
    wrote on last edited by
    #1

    Hi, i'm giving a try to write my project using a very simple with no syntax neither intellisense helpers ide as vim or nano (or even notepad), what are the steps to build just the same as i did on Qt Creator?

    This is what i do:

    1. go to project source folder
    2. execute : qmake
    3. execute : make
    4. what's next?.

    Thanks

    1 Reply Last reply
    1
    • Chris KawaC Online
      Chris KawaC Online
      Chris Kawa
      Lifetime Qt Champion
      wrote on last edited by
      #2

      That should be it. Make will run the compiler and linker and you should have an executable ready to run, so...
      4. run the app

      1 Reply Last reply
      2
      • U Offline
        U Offline
        U7Development
        wrote on last edited by U7Development
        #3

        alright thanks!..
        just curious about make process.. it taking so much time...

        the output is :

        C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
        C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
        C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
        C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
        ..
        ..
        repeating all this all the time.. right now it alive for 15 minutes..
        

        LATER:
        it has finished building!.. but i got some errors on compilation,

        #include <QSqlDatabase>   fatal error: No such file or directory
        

        the same happens with QDialog and other files...
        may I need to reconfigure some paths?..

        I'm using Windows 10 - X64

        MORE LATER:
        I managed to compile it, needed to add project filename to step 2.
        Thanks!

        Pablo J. RoginaP 1 Reply Last reply
        2
        • U U7Development

          alright thanks!..
          just curious about make process.. it taking so much time...

          the output is :

          C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
          C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
          C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
          C:\Qt\5.15.2\mingw81_32\bin\qmake -o Makefile S_Elearning.pro
          ..
          ..
          repeating all this all the time.. right now it alive for 15 minutes..
          

          LATER:
          it has finished building!.. but i got some errors on compilation,

          #include <QSqlDatabase>   fatal error: No such file or directory
          

          the same happens with QDialog and other files...
          may I need to reconfigure some paths?..

          I'm using Windows 10 - X64

          MORE LATER:
          I managed to compile it, needed to add project filename to step 2.
          Thanks!

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

          @U7Development said in manually build debug from cmd or terminal consoles..:

          I managed to compile it,

          if your issue is solved please don't forget to mark your post as such!

          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
          1
          • KH-219DesignK Offline
            KH-219DesignK Offline
            KH-219Design
            wrote on last edited by
            #5

            @U7Development I also recently undertook an effort to compile a qmake project without an IDE (i.e. without Visual Studio and without Qt Creator).

            As you probably know, this is more than just a matter of any personal taste (or personal distaste) for any particular IDE. Rather, a scripted and repeatable build is essential for continuous integration!

            Congratulations on getting it working with mingw.

            In my case, I used the MSVC toolchain (in place of mingw). For anyone else in the MSVC situation, I think one extra step is needed in order to succeed at building in a terminal window. The step is to call vcvars64.bat to select the MSVC toolchain.

            From a cmd.exe window, vcvars64.bat can be used to select the MSVC toolchain.  From thereafter, calling qmake using the full path to the 'msvc2019_64' (or similar) edition of qmake is the key to building with the right "kit". (Qt Creator IDE terminology speaks in terms of "kits".)

            Since Windows development has historically been far less command-line oriented than Linux (or even Mac) development, I just want to give this forum thread even more love and continue to "sprinkle the news around" that a command-line MSVC build is possible. My applause to @U7Development for the same!

            www.219design.com
            Software | Electrical | Mechanical | Product Design

            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