Open springmeyer opened 6 years ago
Or, we could try to get the default build of LLVM changed such that it does work with the command line tools.
Debugging locally with @millzpaugh and @allieoop we found that clang++
v5.0.1 from mason could be made to work without XCode (and only the "command line tools" install) by passing:
-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/ -I/Library/Developer/CommandLineTools//usr/include/c++/v1/
The llvm/clang++ compiler used and provided by mason needs a full XCode installation available. Otherwise you'll hit a warning like:
And an error when the program tries to use something from the C standard library. For example:
But this error will depend on what of the C standard library is being requested.
The way to solve this is for OS X users to install a full version of XCode.
This reliance on a full version of XCode is due to this line in our compiler config: https://github.com/mapbox/mason/blob/6aa9591a336ac71bfa1974185b6ee784a9b6033a/scripts/llvm/base/common.sh#L230. It is possible we could try to get this working against the Command line tools install of C headers as well, but this is not something I've tried.