A console window appears after deployment

  • Hi,

    after I have successfully build an installer (WiX Toolset v3.8) for my Qt application (Qt Creator 3.1.1), there is a console window opening together with the MainWindow when I start my application. All the log messages from within the application (the ones that are usually caught by Qt Creator in the bottom window) are reported there. This window is not opening when I start the application from the IDE nor when I start it manually from the build directory (debug or release). Build and Deployment both happens on Windows 7 systems.

    Here is an extract from my project file:

    Project file

    QT += testlib widgets serialport webkitwidgets network
    CONFIG += c++11
    TARGET = ServiceApplication
    TEMPLATE = app
    SOURCES += \
        main.cpp \
    HEADERS += \
        mainwindow.h \
    FORMS += \
        mainwindow.ui \
    RESOURCES += \
    LIBS += -L$$PWD/../senn_msg_api/ -lsennheiser_msg_api
    LIBS += -LD:/DataVCS2/wennebostel_service/RtxEaiPortServer/ -lRtxProdTest
    LIBS += -LD:/DataVCS2/wennebostel_service/RtxEaiPortServer/ -lRepsClient
    INCLUDEPATH += $$PWD/../senn_msg_api/
    INCLUDEPATH += D:/DataVCS2/wennebostel_service/RtxEaiPortServer/
    DEPENDPATH += $$PWD/../senn_msg_api/
    DEPENDPATH += D:/DataVCS2/wennebostel_service/RtxEaiPortServer/

    Any idea what I am missing here?


  • Lifetime Qt Champion


    I'd say the testlib is responsible. You should not use it in production code. It's only meant for testing

  • @SGaist Does that mean that I have to exclude each and every qDebug call by preprocessor if's related to a DEBUG definition? Or would it be enough to install this specific detour function and send everything to NIL when it's not in debugging mode?


  • Lifetime Qt Champion

    No, it means that you should not use the QTest module in your application

Log in to reply