Results 1 to 8 of 8

Thread: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

  1. #1
    Join Date
    Jun 2012
    Posts
    5
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Question Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Hello Guys,
    I am sorry if this has been asked before but I could not find an answer to my question.
    Hence I have to ask it by making this thread.

    I downloaded QT SDK v1.1.2 Offline Installer for Windows 7 64-bit (.exe) quite a while ago but couldn't learn QT at that time.I started learning it a bit now,hence installed the QT SDK v1.1.2 on my C: Drive.
    But I made a application called "Hello World" from the tutorials available and hence created a .cpp and a .pro file to compile it.
    So now tried to compile it(I don't know if QT SDK has a compiler or not as I haven't installed any compiler like Visual C etc.) in Command Prompt of Windows and as I use qmake to compile the Command Prompt shows "'qmake' is not recognized as an internal or external command,
    operable program or batch file." error.
    Now I started searching through the Internet for setting the Environment Variable Paths for qmake but everywhere I found different paths for adding but those paths were not available on my drive!(Don't have qt/bin folder etc.) I am attaching a Screenshot of my QtSDK folder in C: Drive.
    So please someone reply me with the solution to compile the applications from command prompt. Thanxx and sorry for my super newbie questions. :P

    My QTSDK Folder

  2. #2
    Join Date
    May 2010
    Location
    Romania
    Posts
    1,021
    Thanks
    62
    Thanked 260 Times in 246 Posts
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    You can manually add the path to qmake into environment variables path or you can use the shortcut from StartMenu/Qt SDK/Desktop/Qt 4.x.x for Desktop (MinGW) - this one sets the paths to qmake (and it should also set the path to qt libraries)

  3. The following user says thank you to Zlatomir for this useful post:

    F3AR (4th June 2012)

  4. #3
    Join Date
    Jun 2012
    Posts
    5
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Quote Originally Posted by Zlatomir View Post
    You can manually add the path to qmake into environment variables path or you can use the shortcut from StartMenu/Qt SDK/Desktop/Qt 4.x.x for Desktop (MinGW) - this one sets the paths to qmake (and it should also set the path to qt libraries)
    mate thanxx for the reply +1... it solved the qmake problem but after running
    qmake -project
    qmake
    the nmake and make command are showing that "not recognized as an internal or external command" error.
    Please help..
    Last edited by F3AR; 4th June 2012 at 07:30.

  5. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    You are using the bundled MingW tools. The make command is mingw32-make

  6. The following user says thank you to ChrisW67 for this useful post:

    F3AR (4th June 2012)

  7. #5
    Join Date
    Jun 2012
    Posts
    5
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Thanxx mate after that I got
    Qt Code:
    1. mingw32-make -f Makefile.Debug
    2. mingw32-make[1]: Entering directory `C:/Users/Pranoy/Desktop/New folder'
    3. g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -
    4. DQT_DLL -DQT_GUI_LIB -DQT_CORE_LIB -DQT_HAVE_MMX -DQT_HAVE_3DNOW -DQT_HAVE_SSE -
    5. DQT_HAVE_MMXEXT -DQT_HAVE_SSE2 -DQT_THREAD_SUPPORT -DQT_NEEDS_QMAIN -I"..\..\..\
    6. ..\QtSDK\Desktop\Qt\4.7.3\mingw\include\QtCore" -I"..\..\..\..\QtSDK\Desktop\Qt\
    7. 4.7.3\mingw\include\QtGui" -I"..\..\..\..\QtSDK\Desktop\Qt\4.7.3\mingw\include"
    8. -I"." -I"..\..\..\..\QtSDK\Desktop\Qt\4.7.3\mingw\include\ActiveQt" -I"debug" -I
    9. "..\..\..\..\QtSDK\Desktop\Qt\4.7.3\mingw\mkspecs\default" -o debug\project.o pr
    10. oject.cpp
    11. g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-rel
    12. oc -mthreads -Wl -Wl,-subsystem,windows -o "debug\New folder.exe" debug/project.
    13. o -L"c:\QtSDK\Desktop\Qt\4.7.3\mingw\lib" -lmingw32 -lqtmaind -lQtGuid4 -lQtCor
    14. ed4 -LC:\OpenSSL-Win32_full\lib
    15. g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-rel
    16. oc -mthreads -Wl -Wl,-subsystem,windows -o "debug\New folder.exe" debug/project.
    17. o -L"c:\QtSDK\Desktop\Qt\4.7.3\mingw\lib" -lmingw32 -lqtmaind -lQtGuid4 -lQtCor
    18. ed4 -LC:\OpenSSL-Win32_full\lib
    19. mingw32-make[1]: Leaving directory `C:/Users/Pranoy/Desktop/New folder'
    To copy to clipboard, switch view to plain text mode 
    after that nothing happen... what I have to do next to run the application?
    Last edited by F3AR; 4th June 2012 at 07:42.

  8. #6
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Run "debug\New Folder.exe"


    Are you avoiding the Qt Creator IDE that ships in the Qt SDK for a reason?

  9. The following user says thank you to ChrisW67 for this useful post:

    F3AR (4th June 2012)

  10. #7
    Join Date
    Jun 2012
    Posts
    5
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Quote Originally Posted by ChrisW67 View Post
    Run "debug\New Folder.exe"


    Are you avoiding the Qt Creator IDE that ships in the Qt SDK for a reason?
    I am unable to create project from qt creator properly... there are too make options there..
    Actually I am learning QT to develop applications for symbian devices... and I cant get perfect info that what is to be learned to develop those...
    I know C and fairly C++ but I have never developed any application...
    Can you list the languages which I have to learn for the purpose...?
    I saw QML also... but I dont know will that help me in making applications...

  11. #8
    Join Date
    Jun 2012
    Posts
    5
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Default Re: Unable to Compile Application (Qt SDK v1.1.2) from Command Prompt - Windows 7

    Hello.. Can anyone reply??

Similar Threads

  1. Replies: 7
    Last Post: 20th October 2012, 14:44
  2. Replies: 3
    Last Post: 9th March 2011, 13:52
  3. Changing the directory of the command prompt
    By Rakula in forum General Programming
    Replies: 3
    Last Post: 21st October 2010, 16:40
  4. Qt Command Prompt and Recompiling
    By vbman213 in forum Newbie
    Replies: 1
    Last Post: 6th February 2010, 10:49
  5. Possible to return to command prompt immediately?
    By Pembar in forum Qt Programming
    Replies: 8
    Last Post: 29th June 2009, 22:11

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.