VC2008 转换Qt pro工程失败
下载一个Qt项目,号称是用VS2008编译,可是里面只有源码和一个.pro文件。
我打开VS2008——>Qt——》Open Qt project files
错误信息如下
--- (Import): Generating new project of MatchGame.pro file
--- (qmake) : Using: c:\qt\4.8.4\bin\qmake
--- (qmake) : Working Directory: G:\MatchGame
--- (qmake) : Arguments: -tp vc "MatchGame.pro" -o "MatchGame.vcproj" QMAKE_INCDIR_QT=$(QTDIR)\include QMAKE_LIBDIR=$(QTDIR)\lib QMAKE_MOC=$(QTDIR)\bin\moc.exe QMAKE_QMAKE=$(QTDIR)\bin\qmake.exe
[1] - WARNING: (internal):1: Unescaped backslashes are deprecated.
[2] - WARNING: (internal):1: Unescaped backslashes are deprecated.
[3] - WARNING: (internal):1: Unescaped backslashes are deprecated.
[4] - WARNING: Unable to generate output for: G:/MatchGame//MatchGame.vcproj.Debug [TEMPLATE vcapp]
[5] - WARNING: Unable to generate output for: G:/MatchGame//MatchGame.vcproj.Release [TEMPLATE vcapp]
--- (Import): Error(s): 5
--- (qmake) : Exit Code: 0
Could not parse QTDIR from project file MatchGame.vcproj.
--- (Import): Generated project could not be loaded.
--- (Import): Please look in the output above for errors and warnings.
[解决办法]
有.pro就够了啊 装好qt配置好环境变量好
直接进入到project目录
运行qmake 生成vs对应的nmake file
然后nmake就可以
Could not parse QTDIR from project file MatchGame.vcproj.
--- (Import): Generated project could not be loaded.
--- (Import): Please look in the output above for errors and warnings.
貌似你没配置好QTDIR环境变量参数
[解决办法]
大家有用过QT5.0吗?如何编译一个已经写好的a.cpp文件。我通过qmake -project a.cpp.然后amake a.pro之后后来再执行nmake, 但是发现生成了空的debug文件夹,程序无法使用,要怎么办?