Technical requirements
In this chapter, we are still relying on the clang
executable, so make sure you build it, like this:
$ ninja clang
Since we are working with a driver, as we mentioned in Chapter 5, Exploring Clang's Architecture, you can use the -###
command-line option to print out the frontend flags that have been translated from the driver, like so:
$ clang++ -### -std=c++11 -Wall hello_world.cpp -o hello_world "/path/to/clang" "-cc1" "-triple" "x86_64-apple-macosx11.0.0" "-Wdeprecated-objc-isa-usage" "-Werror=deprecated-objc-isa-usage" "-Werror=implicit-function-declaration" "-emit-obj" "-mrelax-all" "-disable-free" "-disable-llvm-verifier" … "-fno-strict-return" "-masm-verbose" "-munwind-tables" "-target-sdk-version=11.0" … "-resource-dir" "/Library/Developer/CommandLineTools/usr...