Results 1 to 11 of 11

Thread: qt project release problem

  1. #1
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default qt project release problem

    Hi guys
    I am using windows 7. And I have a problem with release of qt project.
    The error says cannot find -lQtGui4. The project runs well in debug mode, the only problem that i have is in the release mode. please help

  2. #2
    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: qt project release problem

    Where is that error message coming from? Building the release version or at some point while trying to start a deployed release version?

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

    robotics (6th March 2012)

  4. #3
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: qt project release problem

    Building the release version..... I am not able to create .exe file from my project

  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: qt project release problem

    That file is part of Qt and should be present along with QtCore4 and friends, and their debug versions QtGui4d etc. that you were previously using.

    Have you cleaned the project, rerun qmake and tried again?

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

    robotics (6th March 2012)

  7. #5
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: qt project release problem

    can u please elaborate the process of qmake please....
    I tried it several times but came out with no luck every time.
    please help

  8. #6
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: qt project release problem

    finally I ran out of idea and reinstalled my qt.
    and I got a new problem again when i try to run my project in release mode.
    error message is as follows
    exited with code -1073741511
    please help


    Added after 1 2 minutes:


    solved problem:
    copied all the dll files from C:\Qt\2010.05\qt\bin to system 32 folder and all my problem flushed....
    also I you want a help from me do contact me
    surajready2go@gmail.com
    Last edited by robotics; 6th March 2012 at 17:27.

  9. #7
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    5,230
    Thanks
    302
    Thanked 864 Times in 851 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: qt project release problem

    Quote Originally Posted by robotics View Post
    solved problem:
    copied all the dll files from C:\Qt\2010.05\qt\bin to system 32 folder and all my problem flushed....
    That is absolutely the WRONG way to solve the problem. Reinstalling Qt, and copying files to the system32 folder is simply wrong. Instead of figuring out what was really wrong with your build process, you pulled out the biggest hammer you could find and beat it to death.

    The original problem with the build is that you probably did not have your Qt .pro file configured correctly, or perhaps you really didn't install Qt correctly the first time.
    The next problem (being able to run the exe once you built it) is because the Qt bin directory isn't in your $PATH environment variable.

    So even though it works now, the next time you update to a later version of Qt and suddenly none of your new projects will run correctly, remember how you messed up your system32 folder and think about the right way to develop and deploy Qt projects.

  10. #8
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: qt project release problem

    so what is the correct method when the problem says that some dll files are missing??

  11. #9
    Join Date
    Sep 2011
    Location
    Manchester
    Posts
    538
    Thanks
    3
    Thanked 106 Times in 103 Posts
    Qt products
    Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: qt project release problem

    Quote Originally Posted by d_stranz View Post
    the Qt bin directory isn't in your $PATH environment variable.
    That tells you all.
    Add your Qt bin directory to your environment PATH variable and you're good to go (on this box).
    If you want to deploy that app on other computer you will have to include all required libraries with your binary.
    Use Dependency Walker if you don't know what libraries you need.

    And delete the files you've copied to the system32 folder!!!

  12. #10
    Join Date
    May 2011
    Posts
    39
    Thanks
    15
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: qt project release problem

    can you explain me the reason that I should delete those files from system 32

  13. #11
    Join Date
    Sep 2011
    Location
    Manchester
    Posts
    538
    Thanks
    3
    Thanked 106 Times in 103 Posts
    Qt products
    Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: qt project release problem

    Because they should not be there in the first place.
    If they're in the system32 every app will pick up them first before looking at what's in other places.

    If you've copied qt 4.6.3 in there and then try to run app that depends on qt 4.8, for example, it may crash, it may missbehave, etc.
    basically - you should not copy anything to that folder without very good reason.
    and not deploying app properly or not using PATH variable is not a good reason.

    Edit:
    In case someone gets it VERY wrong - I ment to delete the Qt binary files copied to the system32 directory, not the entire content of the system32 directory!

  14. The following user says thank you to Spitfire for this useful post:

    robotics (10th March 2012)

Similar Threads

  1. Project file LIBS debug/release
    By bunjee in forum Qt Programming
    Replies: 5
    Last Post: 27th July 2015, 05:42
  2. How to release my project
    By Malek in forum Newbie
    Replies: 3
    Last Post: 31st August 2010, 12:00
  3. Replies: 1
    Last Post: 18th August 2010, 08:15
  4. Replies: 1
    Last Post: 15th August 2010, 12:12
  5. Replies: 3
    Last Post: 15th February 2010, 17:27

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.