问题描述
新建一个main window程序后运行程序坞出现图标,但是不显示界面(之前windows从来没遇到过)
然后仔细查看了运行输出,发现提示SDK版本有问题
Project WARNING: Qt has only been tested with version 10.15 of the platform SDK, you’re using 12.3.
Project WARNING: This is an unsupported configuration. You may experience build issues, and by using
Project WARNING: the 12.3 SDK you are opting in to new features that Qt has not been prepared for.
Project WARNING: Please downgrade the SDK you use to build your app to version 10.15, or configure
Project WARNING: with CONFIG+=sdk_no_version_check when running qmake to silence this warning.
解决方法
修改pro文件中的配置,实现对于SDK版本的忽略
CONFIG += sdk_no_version_check
QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.15
最后记得一定要先清除一下再重新编译,否则不生效