Results 1 to 10 of 10

Thread: Getting Started

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Re: Getting Started

    Thanks for the speedy reply.

    I've read those articles and tried to build a simple, single file application but I am getting the following error:

    Qt Code:
    1. mingw32-make: *** No rule to make target `test.pro', needed by `Makefile'. Stop.
    To copy to clipboard, switch view to plain text mode 

    What am I doing wrong? I've Googled but nothing really helpful.

    Cheers

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Getting Started

    How does your .pro file look like and what how did you invoke qmake?

  3. #3

    Default Re: Getting Started

    Edit It just occured to me to look inside my makefile and see if the path were inside the makefile. It seems as though the makefile is just referencing the test.pro and NOT including the path. Ise the environment variables for the MinGW and Qt binaries, do I just add my project path to environment variables as well? I would need to keep the path in the qmake command thought, correct?

    This is the contents of my project file:

    Qt Code:
    1. CONFIG += qt
    2. SOURCES += main.cpp
    To copy to clipboard, switch view to plain text mode 

    I copied it verbatim essentially from the tutorials...

    I invoked qmake with this command:

    Qt Code:
    1. qmake.exe -o c:\test\Makefile c:\test\test.pro
    To copy to clipboard, switch view to plain text mode 
    Last edited by Hockey; 29th November 2007 at 21:13.

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Getting Started

    Everything OK so far. How did you invoke make?

  5. #5

    Default Re: Getting Started

    Qt Code:
    1. make --makefile=c:\test\Makefile
    To copy to clipboard, switch view to plain text mode 

    I've tried several switches but no luck...

  6. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Getting Started

    Does it work if you invoke:
    Qt Code:
    1. cd c:\test\
    2. make
    To copy to clipboard, switch view to plain text mode 
    ?

  7. #7

    Default Re: Getting Started

    Zing!!!

    That did the trick. Although it compiled as release not debug. Does this mean I have too add my project path to environment variables?

  8. #8
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Getting Started

    Quote Originally Posted by Hockey View Post
    That did the trick. Although it compiled as release not debug.
    Most likely it's because you don't have the debug version of Qt libraries. Look for "Build Qt libraries in debug mode" or something similar in the Start menu.

    Quote Originally Posted by Hockey View Post
    Does this mean I have too add my project path to environment variables?
    No, I've just reproduced your problem on my system. It seems that qmake generates Makefiles which expect that the .pro file is in the current directory. So you just have to make sure that your project's directory is the current one.

Similar Threads

  1. Replies: 2
    Last Post: 30th March 2007, 08:10
  2. Replies: 10
    Last Post: 20th March 2007, 22:19
  3. How do I get started?
    By neigaard in forum Newbie
    Replies: 2
    Last Post: 12th March 2007, 08:42
  4. Replies: 10
    Last Post: 7th April 2006, 18:23

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
  •  
Qt is a trademark of The Qt Company.