Untitled2main.cpp: No such file or directory



  • I have install @QT5.0.1@ with @mingw32@ on windows.when i created a project and run it and every thing was perfect. next time when i was opened QT @Qreator@ and want to run my program it has following error:

    @:-1: error: error: ..untitled2main.cpp: No such file or directory@
    this is .pro flie
    @
    QT += core gui

    greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

    TARGET = untitled1
    TEMPLATE = app

    SOURCES += main.cpp
    mainwindow.cpp
    contentcontrol.cpp

    HEADERS += mainwindow.h
    contentcontrol.h

    FORMS += mainwindow.ui
    contentcontrol.ui
    @
    this is compile output:
    @
    22:17:17: Running steps for project untitled1...
    22:17:17: Configuration unchanged, skipping qmake step.
    22:17:17: Starting: "C:\Qt\Qt5.0.1\Tools\MinGW\bin\mingw32-make.exe"
    C:/Qt/Qt5.0.1/Tools/MinGW/bin/mingw32-make -f Makefile.Debug
    mingw32-make[1]: Entering directory 'C:/Users/(Mahdi)/Documents/QT/untitled1-build-Desktop_Qt_5_0_1_MinGW_32bit-Debug'
    g++ -c -pipe -fno-keep-inline-dllexport -g -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_OPENGL_ES_2 -DQT_OPENGL_ES_2_ANGLE -DQT_NEEDS_QMAIN -I..\untitled1 -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtWidgets" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtGui" -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\include\QtCore" -I"debug" -I"." -I"." -I"..........\Qt\Qt5.0.1\5.0.1\mingw47_32\mkspecs\win32-g++" -o debug\main.o ..\untitled1\main.cpp
    g++.exe: error: ..untitled1main.cpp: No such file or directory
    g++.exe: fatal error: no input files
    compilation terminated.
    Makefile.Debug:477: recipe for target 'debug/main.o' failed
    mingw32-make[1]: *** [debug/main.o] Error 1
    mingw32-make[1]: Leaving directory 'C:/Users/(Mahdi)/Documents/QT/untitled1-build-Desktop_Qt_5_0_1_MinGW_32bit-Debug'
    makefile:34: recipe for target 'debug' failed
    mingw32-make: *** [debug] Error 2
    22:17:18: The process "C:\Qt\Qt5.0.1\Tools\MinGW\bin\mingw32-make.exe" exited with code 2.
    Error while building/deploying project untitled1 (kit: Desktop Qt 5.0.1 MinGW 32bit)
    When executing step 'Make'
    @
    from build menu i clicked on @qmake@ and it has no error. what is problem?



  • i solve that with adding values to environment variables

    path:
    C:\Qt\Qt5.0.1\5.0.1\mingw47_32\bin;C:\Qt\Qt5.0.1\Tools\MinGW\bin
    QTDIR:
    C:\Qt\Qt5.0.1\5.0.1\mingw47_32


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.