Results 1 to 10 of 10

Thread: Qt Creator Plain C++ Project won't run/debug...

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #6
    Join Date
    Sep 2009
    Location
    Surrey, BC, Canada
    Posts
    110
    Thanks
    1
    Thanked 2 Times in 1 Post
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Qt Creator Plain C++ Project won't run/debug...

    Hi, Thank you for your help Chris.

    Quote Originally Posted by ChrisW67 View Post
    Which terminal program are you using. Konsole, for example, causes issue for me but the default "xterm -e" works fine.
    When I run my application, "GNOME Terminal 3.4.1.1" jumped out automatically.

    You will not be able to adequately debug this program unless you build it in debug mode by using "qmake CONFIG+=debug" manually or form an IDE that does the equivalent for you.
    1) Yes, I'm running it, instead of debugging it.
    2) Even debugging it with CONFIG += debug, namely
    Qt Code:
    1. TEMPLATE = app
    2. CONFIG += console debug
    3. CONFIG -= qt
    4.  
    5. SOURCES += main.cpp
    To copy to clipboard, switch view to plain text mode 
    the terminal still hangs....


    Added after 45 minutes:


    Hi, amleto:

    Thanks for your reply. But, unfortunately, here on my computer, it doesn't work.

    Environment:
    Qt Code:
    1. $ lsb_release -a
    2. No LSB modules are available.
    3. Distributor ID: Ubuntu
    4. Description: Ubuntu 12.04 LTS
    5. Release: 12.04
    6. Codename: precise
    7.  
    8. $ uname -a
    9. Linux XXXXXXXXX 3.2.0-27-generic-pae #43-Ubuntu SMP Fri Jul 6 15:06:05 UTC 2012 i686 athlon i386 GNU/Linux
    To copy to clipboard, switch view to plain text mode 


    .pro file
    Qt Code:
    1. TARGET = noqt
    2. CONFIG += console
    3. CONFIG -= app_bundle
    4.  
    5. CONFIG -= qt
    6.  
    7. TEMPLATE = app
    8.  
    9. SOURCES += main.cpp
    To copy to clipboard, switch view to plain text mode 

    main.cpp file
    Qt Code:
    1. #include <iostream>
    2.  
    3. using namespace std;
    4.  
    5. int main()
    6. {
    7. cout << "Hello World!" << endl;
    8. return 0;
    9. }
    To copy to clipboard, switch view to plain text mode 


    I'm guessing it might have something to do with the OS, namely, current Ubuntu.


    Thanks anyway.


    Best Regards
    Pei


    Quote Originally Posted by amleto View Post
    Last edited by jiapei100; 23rd July 2012 at 23:21.
    Welcome to Vision Open
    http://www.visionopen.com

Similar Threads

  1. Project file LIBS debug/release
    By bunjee in forum Qt Programming
    Replies: 5
    Last Post: 27th July 2015, 05:42
  2. Debug Qt project via Visual Studio
    By Ali Reza in forum Newbie
    Replies: 1
    Last Post: 16th June 2012, 17:11
  3. Qt Creator Can't debug the program with OpenCV in Qt Creator
    By nimingzhe2008 in forum Qt Tools
    Replies: 6
    Last Post: 15th June 2012, 15:04
  4. Replies: 8
    Last Post: 26th March 2011, 12:11
  5. Replies: 4
    Last Post: 8th August 2010, 22:00

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.