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. Running qmake and nmake commands
Forum Updated to NodeBB v4.3 + New Features

Running qmake and nmake commands

Scheduled Pinned Locked Moved Installation and Deployment
14 Posts 2 Posters 7.1k 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.
  • S Offline
    S Offline
    samsam
    wrote on 22 Jun 2014, 07:07 last edited by
    #1

    In order to run a .bat file that has the commands-
    qmake.exe aa.pro -r -spec win32-msvc2013++ "CONFIG+=release"
    nmake
    Do i have to have Qt creator installed on my computer or its enough to have qt libraries and dlls copied (of msvc2013) and debugging tools for windows?

    1 Reply Last reply
    0
    • S Offline
      S Offline
      sierdzio
      Moderators
      wrote on 22 Jun 2014, 09:28 last edited by
      #2

      You do not need Qt Creator, it is "just" an IDE. qmake.exe is part of Qt libraries (located in qtbase/bin).

      (Z(:^

      1 Reply Last reply
      0
      • S Offline
        S Offline
        samsam
        wrote on 23 Jun 2014, 10:26 last edited by
        #3

        Thank you!

        I copied the libraries of msvc2013_64_opengl to be in the location:

        D:\Qt5.3.0\5.3\msvc2013_64_opengl.

        I set the environment variables to be:

        @QTDIR = D:\Qt5.3.0\5.3\msvc2013_64_opengl
        QMAKESPEC = win32-msvc2013
        PATH = %PATH%;%QTDIR%\bin
        @

        When I open the command line and run the command:
        qmake.exe aa.pro -r -spec win32-msvc2013++ "CONFIG+=release"

        I get the error:
        'qmake.exe' is not recognized as an internal or external command.

        How can I solve it?
        Is there anything else I need to do in order to run the qmake command?
        like- configure something, install Qt version...
        If so, how exactly should I do it?

        1 Reply Last reply
        0
        • S Offline
          S Offline
          sierdzio
          Moderators
          wrote on 23 Jun 2014, 10:30 last edited by
          #4

          If you decide to copy Qt libraries, you are going to have trouble. Those can be solved, but it will definitely be painful. It's usually better to compile Qt on your own, or install the Qt package in a new location. Qt lib move can be made with help of a qt.conf file. You can search for more info on that in the documentation.

          Now, qmake is missing from your path, because you set it up wrongly. qmake.exe resides in <qt dir>/qtbase/bin.

          (Z(:^

          1 Reply Last reply
          0
          • S Offline
            S Offline
            samsam
            wrote on 23 Jun 2014, 10:53 last edited by
            #5

            Where? I don't see it. Inside qt dir that is: D:\Qt5.3.0\5.3\msvc2013_64_opengl
            I see only: bin, imports, include, lib, mkspecs, phrasebooks, plugins, qml, translations.
            (Meanwhile I want to try with out compiling Qt by my own or installing Qt on the PC I moving my project to)

            1 Reply Last reply
            0
            • S Offline
              S Offline
              sierdzio
              Moderators
              wrote on 23 Jun 2014, 10:59 last edited by
              #6

              Well. Then, perhaps, just look around? Somewhere in your Qt installation folder, you will find a folder named qtbase, and it will contain a directory bin, and inside it, qmake.exe will be present. Ten just point PATH to there.

              I don't normally use Qt installers, so I don't know exact path inside the installed bundle. I know it for Qt built from source, and that is what I have provided.

              (Z(:^

              1 Reply Last reply
              0
              • S Offline
                S Offline
                samsam
                wrote on 23 Jun 2014, 11:09 last edited by
                #7

                Well. I searched around and there is no qtbase folder.

                1 Reply Last reply
                0
                • S Offline
                  S Offline
                  sierdzio
                  Moderators
                  wrote on 23 Jun 2014, 11:17 last edited by
                  #8

                  Have you checked whether qmake.exe is in "bin" folder? It has to be somewhere.

                  (Z(:^

                  1 Reply Last reply
                  0
                  • S Offline
                    S Offline
                    samsam
                    wrote on 23 Jun 2014, 11:20 last edited by
                    #9

                    Yes. as I wrote at the beginning qmake.exe is at the location I put in the path: D:\Qt5.3.0\5.3\msvc2013_64_opengl\bin.
                    but I still then get the error: ‘qmake.exe’ is not recognized as an internal or external command.

                    1 Reply Last reply
                    0
                    • S Offline
                      S Offline
                      sierdzio
                      Moderators
                      wrote on 23 Jun 2014, 11:25 last edited by
                      #10

                      Oh, you did, indeed. I have missed or misunderstood that part.

                      Try cd'ing into QTDIR/bin and see if you can launch qmake from there. Maybe it is enough to skip .exe from the call (so, run qmake -v instead of qmake.exe -v). It's been a while since I launched qmake on Windows manually. Linux tends to be simpler to use in that regard.

                      (Z(:^

                      1 Reply Last reply
                      0
                      • S Offline
                        S Offline
                        samsam
                        wrote on 23 Jun 2014, 13:00 last edited by
                        #11

                        OK. I did so. Now it works well. but how can I make it work with out cd'ing to D:\Qt5.3.0\5.3\msvc2013_64_opengl\bin.
                        ?

                        1 Reply Last reply
                        0
                        • S Offline
                          S Offline
                          sierdzio
                          Moderators
                          wrote on 23 Jun 2014, 13:01 last edited by
                          #12

                          You have already done that: by setting PATH (which on Windows is enclosed in percentage signs, of course) in the control panel.

                          (Z(:^

                          1 Reply Last reply
                          0
                          • S Offline
                            S Offline
                            samsam
                            wrote on 23 Jun 2014, 13:13 last edited by
                            #13

                            But if I am not launching qmake from D:\Qt5.3.0\5.3\msvc2013_64_opengl\bin I get the error: ‘qmake.exe’ is not recognized as an internal or external command.

                            1 Reply Last reply
                            0
                            • S Offline
                              S Offline
                              sierdzio
                              Moderators
                              wrote on 24 Jun 2014, 05:21 last edited by
                              #14

                              Make sure path is defined in your terminal by running this:
                              @
                              echo %path%
                              @

                              (Z(:^

                              1 Reply Last reply
                              0

                              1/14

                              22 Jun 2014, 07:07

                              • Login

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