Important: Please read the Qt Code of Conduct -

Qt Creator: "no input files" gcc error

  • Hello,

    I have a Qt project I have been working on in Qt creator for a little while now with no issues. However, for some reason I now get the error "no input files" every time I try to compile the project. I have tried cleaning the project, deleting the entire output folder structure, restarting Qt creator, and looking through the compiler output and the .pro file to see what the problem could possibly be but I am stumped. The odd thing is, I haven't done anything out of the ordinary (edit, save, etc... files) to the project. Here is my full compiler output:

    13:57:16: Running steps for project EngineersTerminal...
    13:57:16: Configuration unchanged, skipping qmake step.
    13:57:16: Starting: "C:\Qt\Tools\mingw530_32\bin\mingw32-make.exe" -j8
    C:/Qt/Tools/mingw530_32/bin/mingw32-make -f Makefile.Debug
    mingw32-make[1]: Entering directory 'C:/Users/H321355/Local-Documents/Qt/build-EngineersTerminal-Desktop_Qt_5_11_2_MinGW_32bit-Debug'
    gcc -c -fno-keep-inline-dllexport -g -Wall -W -Wextra -DUNICODE -D_UNICODE -DWIN32 -DMINGW_HAS_SECURE_API=1 -DQT_DEPRECATED_WARNINGS -DQT_QML_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_SERIALPORT_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN -I..\EngineersTerminal -I. -I..\EngineersTerminal\frame -IC:\Qt\5.11.2\mingw53_32\include -IC:\Qt\5.11.2\mingw53_32\include\QtWidgets -IC:\Qt\5.11.2\mingw53_32\include\QtGui -IC:\Qt\5.11.2\mingw53_32\include\QtANGLE -IC:\Qt\5.11.2\mingw53_32\include\QtSerialPort -IC:\Qt\5.11.2\mingw53_32\include\QtQml -IC:\Qt\5.11.2\mingw53_32\include\QtNetwork -IC:\Qt\5.11.2\mingw53_32\include\QtCore -Idebug -I. -IC:\Qt\5.11.2\mingw53_32\mkspecs\win32-g++  -o debug\.o \
    gcc: fatal error: no input files
    compilation terminated.
    Makefile.Debug:4884: recipe for target 'debug/.o' failed
    mingw32-make[1]: Leaving directory 'C:/Users/H321355/Local-Documents/Qt/build-EngineersTerminal-Desktop_Qt_5_11_2_MinGW_32bit-Debug'
    mingw32-make[1]: *** [debug/.o] Error 1
    Makefile:36: recipe for target 'debug' failed
    mingw32-make: *** [debug] Error 2
    13:57:19: The process "C:\Qt\Tools\mingw530_32\bin\mingw32-make.exe" exited with code 2.
    Error while building/deploying project EngineersTerminal (kit: Desktop Qt 5.11.2 MinGW 32bit)
    When executing step "Make"
    13:57:19: Elapsed time: 00:03.

    And this is my .pro file:

    # Project created by QtCreator 2019-07-17T09:18:23
    QT       += core gui serialport qml
    greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
    TARGET = EngineersTerminal
    TEMPLATE = app
    # The following define makes your compiler emit warnings if you use
    # any feature of Qt which has been marked as deprecated (the exact warnings
    # depend on your compiler). Please consult the documentation of the
    # deprecated API in order to know how to port your code away from it.
    # You can also make your code fail to compile if you use deprecated APIs.
    # In order to do so, uncomment the following line.
    # You can also select to disable deprecated APIs only up to a certain version of Qt.
    #DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0
    CONFIG += c++11
    #This .pri includes headers and sources for a sub-section of the project's code
    SOURCES += \
        aboutdialog.cpp \
        byteviewwidget.cpp \
        classifiedbyte.cpp \
        colorbuttonwidget.cpp \
        framelabelwidget.cpp \
        hextexteditwidget.cpp \
        labelformattingwidget.cpp \
        main.cpp \
        mainwindow.cpp \
        optionsdialog.cpp \
        sendwidget.cpp \
        terminalbyte.cpp \
        terminalbytelabel.cpp \
        terminalbytelabelmodel.cpp \
        terminalbytemodel.cpp \
        jsbytearraywrapper.cpp \ \
    HEADERS += \
        aboutdialog.h \
        byteviewwidget.h \
        classifiedbyte.h \
        colorbuttonwidget.h \
        framelabelwidget.h \
        hextexteditwidget.h \
        labelformattingwidget.h \
        mainwindow.h \
        optionsdialog.h \
        sendwidget.h \
        terminalbyte.h \
        terminalbytelabel.h \
        terminalbytelabelmodel.h \
        terminalbytemodel.h \
        jsbytearraywrapper.h \ \
    FORMS += \
            aboutdialog.ui \
            framelabelwidget.ui \
            labelformattingwidget.ui \
            mainwindow.ui \
            optionsdialog.ui \
    # Default rules for deployment.
    qnx: target.path = /tmp/$${TARGET}/bin
    else: unix:!android: target.path = /opt/$${TARGET}/bin
    !isEmpty(target.path): INSTALLS += target
    RESOURCES += \

    Any ideas would be greatly appreciated.


  • Lifetime Qt Champion


    In your SOURCES and HEADERS listings, you have two lines with two backslashes separated by a space. Clean that and try again.

  • Perfect!

    I hadn't noticed that and have no clue how it happened.

    Thank you for your help. Simple solutions are always the best.

Log in to reply