Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.2.0
-
None
-
Qt 5.2.0 on Mac OS X Mavericks (10.9.1) with XCode Command Line Tools but WITHOUT XCode!
-
fa7626713b3a943609453459190e16c49d61dfd3
Description
It seems that I need to install the complete XCode IDE instead of just the XCode Command Line Tools (this requirement not that clearly documented - some docs sounds like XCode is just needed to install the Command Line Tools).
If you try to compile a Qt project using qmake (or QT Creator) without having XCode installed, you get the following error message:
"Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild."
But in this case it's not a license issue. The license is confirmed, all XCode Command Line Tools are working properly when called manually.
The message comes up from the following code:
isEmpty(QMAKE_XCODE_DEVELOPER_PATH) { # Get path of Xcode's Developer directory QMAKE_XCODE_DEVELOPER_PATH = $$system("/usr/bin/xcode-select --print-path 2>/dev/null") isEmpty(QMAKE_XCODE_DEVELOPER_PATH): \ error("Xcode path is not set. Please use xcode-select to choose Xcode installation path.") # Make sure Xcode path is valid !exists($$QMAKE_XCODE_DEVELOPER_PATH): \ error("Xcode is not installed in $${QMAKE_XCODE_DEVELOPER_PATH}. Please use xcode-select to choose Xcode installation path.") # Make sure Xcode is set up properly isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null"))): \ error("Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.") }
xcrun --find xcrun returns an error if the license is not accepted OR if XCode is not installed (or the active developer directory points to the commnd line tools).
So there should be a separate check performed to detect if XCode is installed and the active developer directory points to the XCode installations (e.g. the output of xcode-select --print-path may not contain the word "CommandLineTools").
Attachments
Issue Links
- is replaced by
-
QTBUG-41908 Build Qt on OS X Command-Line Tools Only.
- Closed
- relates to
-
QTBUG-61201 QMake cannot find MacOSX sdk when you install XCode CommandLine tools
- Closed
For Gerrit Dashboard: QTBUG-35928 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
196759,7 | Allow using Xcode Command Line Tools to build Qt | 5.9 | qt/qtbase | Status: MERGED | +2 | 0 |