Here is a simple guide how to setup adb and fastboot on Mac. The guide is to simple and a good thing is that you don’t need to worry about drivers like in a Windows PC. Fisrtly make a folder named “Android” and place it anywhere on you hard drive where you can easily find it, because you will use it a lot. A good place would be desktop.
After that, you need to download Android SDK from here. Java isn’t needed to install but it is suggested to do it. When Android SKD finishes downloading, unzip it and find the contents of the “android-sdk-mac_x86” and put in the Android folder.
Once you have done that, go to the Android folder you created and into the tools folder inside it, double-click on a file called “android” (possibly called android sdk). It is a UNIX executable and a terminal window will open. Once the terminal windows is open, check the folder called tools and make sure that both “Android SDK Tools” and the Android SDK Platform-tools” are selected within the tools folder. Then click install and wait for them to download.
When it finish downloading, go inside the platform-tools folder into the Android Folder you created at first, and then copy adb and fastboot and paste them into the root of your Android folder.
Now that adb and fastboot are installed, we are going to test them to be sure that they really work. So go ahead and plug in your Android device. Make sure that USB Debugging is enabled on your Android device. To enable them go to Settings > Developer Options > and enable them by checking the box near USB Debugging.
To access adb and fastboot are two ways. Open a terminal windows and type “cd” followed by the path you have saved your android folder. We have saved the Android folder and in our case it will look like the code below:
Next you need to execute and adb or fastboot command. To do that, you will need to type: “ ./adb (or fastboot) <command> “. For this tutorial we will use “ADB Devices” because it doesn’t actually do anything to the phone. We haven’t use fastboot because it requires rebooting to the bootloader which is different for every Android device.
Type in the same terminal the following code:
Press enter. It should turn up your device’s serial number. If it does, go to the next step, if not then recheck your steps.
If it says “daemon not running. Starting it now on port 5037” “daemon started successfully” it’s perfectly normal.
Now it’s sure that adb and fastboot are completely useable. Having a CD into the directory and use ./ in front of every terminal command is very annoying. So we will show you how to add it to your path so you don’t have to do any of that.
Open a new Terminal window and type:
It will a window that look like this:
Your window will look probably blank, because we have added a lot of stuff to ours over the years.
Add a line to it that contains the path to your Android folder. Again we will use desktop, and it should look something like this:
Once you have added that, press CTRL + X to exit, then Y to confirm the save then press Enter. It will close the nano editor. You can close the terminal window now.
We need to verify that it really works. So open Terminal windows and type:
If it shows the serial number, then you have set it up successfully and are good to go!
We are not the author of this guide. You can check the source here.