C++ 在make-won'期间执行的命令;不能在命令提示下工作

C++ 在make-won'期间执行的命令;不能在命令提示下工作,c++,qt,C++,Qt,无法发布图片,因此以下是编译源代码时的QT输出,例如: 14:04:57: Starting: "C:\Qt\Tools\mingw491_32\bin\mingw32-make.exe" C:/Qt/Tools/mingw491_32/bin/mingw32-make -f Makefile.Debug mingw32-make[1]: Entering directory 'C:/Users/daniel/SkyDrive/Files/Development/C++/ETH I/CUBLI

无法发布图片,因此以下是编译源代码时的QT输出,例如:

14:04:57: Starting: "C:\Qt\Tools\mingw491_32\bin\mingw32-make.exe" 
C:/Qt/Tools/mingw491_32/bin/mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory 'C:/Users/daniel/SkyDrive/Files/Development/C++/ETH I/CUBLI Choreographer/build-CUBLIchoreographer-Desktop_Qt_5_4_1_MinGW_32bit-Debug'
g++ -c -pipe -fno-keep-inline-dllexport -g -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_SERIALPORT_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN -I'../CUBLIchoreographer' -I'.' -I'C:/Qt/5.4/mingw491_32/include' -I'C:/Qt/5.4/mingw491_32/include/QtWidgets' -I'C:/Qt/5.4/mingw491_32/include/QtGui' -I'C:/Qt/5.4/mingw491_32/include/QtSerialPort' -I'C:/Qt/5.4/mingw491_32/include/QtCore' -I'debug' -I'.' -I'C:/Qt/5.4/mingw491_32/mkspecs/win32-g++'  -o debug/mainwindow.o ../CUBLIchoreographer/mainwindow.cpp
../CUBLIchoreographer/mainwindow.cpp: In member function 'int MainWindow::addTimeline()':
../CUBLIchoreographer/mainwindow.cpp:34:1: warning: no return statement in function returning non-void [-Wreturn-type]
 }
 ^
上述操作是成功的,但将相关命令复制粘贴到cmd时,结果如下:

    Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.

C:\Users\daniel>workbench C++

C:\Users\daniel\SkyDrive\Files\Development\C++>cd "ETH I"

C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I>cd "CUBLI Choreographer"

C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I\CUBLI Choreographer>cd build-CUBLIchoreographer-Desktop_Qt_5_4_1_MinGW_32bit-Debug

C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I\CUBLI Choreographer\build-CUBLIchoreographer-Desktop_Qt_5_4_1_MinGW_32bit-Debug>g++ -c -pipe -fno-ke
ep-inline-dllexport -g -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_SERIALPORT_LIB -DQT_CORE_LIB -DQT_NEEDS_Q
MAIN -I'../CUBLIchoreographer' -I'.' -I'C:/Qt/5.4/mingw491_32/include' -I'C:/Qt/5.4/mingw491_32/include/QtWidgets' -I'C:/Qt/5.4/mingw491_32/include/QtGui
' -I'C:/Qt/5.4/mingw491_32/include/QtSerialPort' -I'C:/Qt/5.4/mingw491_32/include/QtCore' -I'debug' -I'.' -I'C:/Qt/5.4/mingw491_32/mkspecs/win32-g++'  -o
 debug/mainwindow.o ../CUBLIchoreographer/mainwindow.cpp
In file included from ../CUBLIchoreographer/mainwindow.cpp:1:0:
../CUBLIchoreographer/mainwindow.h:4:23: fatal error: QMainWindow: No such file or directory
 #include <QMainWindow>
                       ^
compilation terminated.
Microsoft Windows[版本6.3.9600]
(c) 2013年微软公司。版权所有。
C:\Upple \丹尼尔> Workbench C++
C:\Users\daniel\SkyDrive\Files\Development\C++>cd“ETH I”
C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I>cd“CUBLI Choreographer”
C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I\CUBLI Choreographer>cd build-CUBLIchoreographer-Desktop\u Qt\u 5\u 4\u 1\u MinGW\u 32bit-Debug
C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I\CUBLI Choreographer\build-CUBLIchoreographer-Desktop\u Qt\u 5\u 4\u 1\u MinGW\u 32bit-Debug>g++-C-pipe-fno-ke
ep inline dllexport-g-frti-Wall-Wextra-fexceptions-mthreads-DUNICODE-DQT_WIDGETS_LIB-DQT_GUI_LIB-DQT_SERIALPORT_LIB-DQT_CORE_LIB-DQT_NEEDS
MAIN-I'../CUBLIchoreographer'-I'-I'C:/Qt/5.4/mingw491_32/include'-I'C:/Qt/5.4/mingw491_32/include/qtwidget'-I'C:/Qt/5.4/mingw491_32/include/QtGui
“-I'C:/Qt/5.4/mingw491_32/include/QtSerialPort'-I'C:/Qt/5.4/mingw491_32/include/QtCore'-I'debug'-I.”-I'C:/Qt/5.4/mingw491_32/mkspecs/win32-g++”
调试/mainwindow.o../CUBLIchoreographer/mainwindow.cpp
在../CUBLIchoreographer/mainwindow.cpp:1:0中包含的文件中:
../CUBLIchoreographer/mainwindow.h:4:23:致命错误:QMainWindow:没有这样的文件或目录
#包括
^
编译终止。
(我已经检查过了,QMainWindow类出现在includes中的'C:/Qt/5.4/mingw491_32/include/qtwidts'中)

我觉得这样问很傻,提前谢谢你


注意:我面临这个问题,因为我需要知道vim中的YouCompleteMe插件需要哪些编译标志。复制上述命令时,QMainWindow类同样无法识别。

您看到的回显到终端的命令很可能是从另一个目录运行的。感谢您让我再次检查,如果我错了,请更正我,这不是“进入目录'C:/Users/daniel/SkyDrive/Files/Development/C++/ETH I/CUBLI Choreographer/build-CUBLIchoreographer-Desktop_Qt_5_4_1_MinGW_32bit-Debug'和“C:\Users\daniel\SkyDrive\Files\Development\C++\ETH I\CUBLI Choreographer\build-CUBLIchoreographer-Desktop\u Qt\u 5\u 4\u 1\u MinGW\u 32bit-Debug>”等效?此外,include错误使用绝对路径
。/CUBLIchoreographer/mainwindow引用。h
是相对路径。