The first thing we are going to do is make sure you have your Xcode command-line environment set up. You should already have Xcode installed, but we will need its associative command-line tools because of the GCC compiler (https://en.wikipedia.org/wiki/GNU_Compiler_Collection).
It is assumed that you have macOS Sierra installed, but if not, it will most likely work with older versions, though this is not guaranteed.
First, make sure you have the latest version of Xcode installed, which is Xcode 8 at the time of writing, by going to the App Store and seeing if any updates are available. Next, let's see if you already have the full Xcode package installed by typing the following in a Terminal:
$ Xcode-select -p
If you get back the full path to your Developer folder, as follows, you are already set and have the full Xcode package...