创建项目编译的时候,会报错
Qt Creator - Project ERROR: Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild
首先确认安装了CommandLineTools,
在shell中输入
xcode-select --install
确认安装了CommandLineTools
然后
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
但是在我电脑上并没有什么用,还是错误
Before Xcode 8, this problem occurs when commandlinetoolsareinstalledafterXcodeisinstalled. WhathappensistheXcode-selectdeveloperdirectorygetspointedto /Library/Developer/CommandLineTools.
Point Xcode-select tothe correct Xcode Developer directorywiththecommand:
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
Confirm the license agreement withthecommand:
xcodebuild -license
This will prompt you toread through the license agreement.
Enter agree to accept the terms.