[GUIDE] Set up ADB and Fastboot on a Mac easily (With Screenshots!)

Search This thread

AshtonTS

Senior Member
May 11, 2011
5,727
2,656
24
Woodstock, CT
Ok, so I'm going to make a little write up on how to easily install ADB and fastboot on a Mac. It's actually quite simple, and plus you don't have to worry about drivers like in Windows.

Instructions

First, make a folder named "android" (no quotes of course :)) You can place it anywhere on your hard drive, it doesn't really matter. Put it somewhere you'll easily remember, because you're going to be using it a LOT. I placed mine on my desktop.
ScreenShot2012-10-02at42205PM.png


Next, you'll want to download the android SDK from Here. (you won't need to install Java first like you would on a Windows PC, though I would recommend it anyway)
(As pointed out by Wlmeng11, you could skip this step just download a zip that I will have attached at the bottom of the page containing the adb and fastboot files instead of downloading the whole SDK)
ScreenShot2012-10-02at42257PM.png


When the SDK finishes downloading, Unzip it and the contents of the "android-sdk-mac_x86" folder into your android folder.

Once you have done that, open your android folder. Go into the tools folder inside of it. Double click on the file called "android" (possibly called android sdk) This file is a UNIX executable and will open within a Terminal window.
ScreenShot2012-10-02at42232PM.png


When it finishes opening, check the folder called tools. Make sure both "Android SDK Tools" and "Android SDK Platform-tools" are selected within the tools folder. Click install and wait for them to download.
ScreenShot2012-10-02at42242PM.png


When they finish downloading, go into the platform-tools folder inside your android folder, then copy adb and fastboot and paste them into the root of your android folder.
ScreenShot2012-10-02at42733PM.png


Now that you have adb and fastboot installed, we're going to want to test them to make sure they work.

Go ahead and plug in your android device at this time. Make sure android debugging is enabled in settings. Go into Settings > Apps > Developer and check it there (for Gingerbread 2.3 and lower) or go into Settings > Developer Options and check it there for Ice Cream Sandwich or Jellybean. As of now, there are two ways to access adb and fastboot.

Open a Terminal window (look in Applications > Utilities if you can't find it). Type "cd" followed by the path you saved your android folder to (I'm going to use the Desktop for this demonstration) it should look like this
Code:
cd /Users/<yourusername>/Desktop/android
ScreenShot2012-10-02at43423PM.png


Press enter.
ScreenShot2012-10-02at43424PM.png


Now you need to actually execute an adb or fastboot command. To do this, you'll need to type "./adb (or fastboot) <command>" For this tutorial, we will use "ADB devices" since it doesn't actually do anything to the phone. (we won't use fastboot since it requires rebooting to the boot loader which is different for every device)

In the same terminal window as before type the following:
Code:
./adb devices
then hit enter. It should turn up your device's serial number. If it does, proceed to the next step, if not recheck your steps, then leave a post in this thread.
ScreenShot2012-10-02at44100PM.png


(if it says * daemon not running. starting it now on port 5037 *
* daemon started successfully * that is perfectly normal)

Now, at this moment, ADB and Fastboot are both completely useable. However, it's very annoying to have to CD into the directory and use ./ in front of every terminal command. I'll 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
Code:
nano ~/.bash_profile

it will open a window that looks like this:
ScreenShot2012-10-02at44356PM.png

(Yours will probably be blank, because I've added a lot of stuff to mine over the years)

Add a line to it that contains the path to your android folder. (again, I'm using Desktop) It should look like this
Code:
export PATH=${PATH}:/Users/<yourusername>/Desktop/android
ScreenShot2012-10-02at44544PM.png


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.

Now we need to verify that it works. Open a new Terminal window and type
Code:
adb devices
If it shows the serial number, then you have set it up successfully and are good to go!
ScreenShot2012-10-02at44817PM.png


If you have any questions or issues let me know in the thread below.

If this has helped, please press thanks!

Awesome! This made the front page of XDA :) Thanks guys!
 

Attachments

  • android.zip
    154.3 KB · Views: 106,983
Last edited:

Fallon9111

Senior Member
Jul 1, 2012
273
87
The Shire, Middle Earth
I still prefer linux

I still prefer the linux enviroment, although its handy to have the adb on my macbook for when I'm not at home and have bricked my device :S

I had already got this setup, I just didn't know the ~/.bash_profile bit :) Now I know had to add my own programs as actual programs and not just aliases XD
 
  • Like
Reactions: lordaker and themo7

sshvetsov

Senior Member
Nov 12, 2010
80
9
Well since this guide is primarily aimed towards users who only want to root their phone, rather than developers, adb/fastboot is really all you need.
So it would save time to just use an adb/fastboot combo.

Indeed, though this method allows you to update your adb and fastboot via Android SDK Manager (ASM). Also, in cases where all you need is adb and fastboot, you can speed up future update checks by going to "Tools"->"Manage Add-on Sites..." in ASM and click on "Disable All" button in "Official Add-on Sites" tab. From there on Android SDK Manager will check only the default repository containing tools and APIs.
 
Last edited:

AshtonTS

Senior Member
May 11, 2011
5,727
2,656
24
Woodstock, CT
First off, nice guide. I am still trying to understand why you've moved adb and fastboot from platform-tools, rather than export the path to that directory. Is there any particular reason?

EDIT: BTW, you've hit the front page on XDA. :D
It could be done that way, but I personally put other stuff in the android folder on my Mac, and also it's a bit quicker to just drag a file into one folder on your desktop than into a folder within a folder :)
 

wlmeng11

Senior Member
Apr 23, 2012
3,223
1,362
Palo Alto, CA
You bet! this will work on any mac running any OS X (unless Google blocks the install of the SDK, but I have a way around that. :)

Actually, that's a PowerPC Mac, so Intel OSX software will not work.
There is no official support for PowerPC that I know of, but someone on XDA did make binaries for PowerPC.

Sent from my HTC Rezound

Edit: yup, official sdk is x86 only.
BTW, here's the link to the ported binaries.
http://forum.xda-developers.com/showthread.php?t=898744
 
Last edited:

Pithism

Senior Member
Dec 21, 2010
1,052
63
Boston, MA
Hi thanks so much for this. Ive been wanting something like this for months/ almost a year.

All the other guides didnt work for me, but this was simple and easy to follow.

Ive encountered one problem and its device specific. My nexus 7 tablet works great with adb, but my htc evo 4g lte doesnt. its rooted, and running cm 10 4.1.2. its debugged any idea how to make it see the device?

UPDATE. so i turned on my usb storage on the device and it now sees the phone. Great work!!!!

Am i going to have to connect storage to mac all the time for this to work on any device?
 
Last edited:
  • Like
Reactions: seven hole

Top Liked Posts

  • There are no posts matching your filters.
  • 315
    Ok, so I'm going to make a little write up on how to easily install ADB and fastboot on a Mac. It's actually quite simple, and plus you don't have to worry about drivers like in Windows.

    Instructions

    First, make a folder named "android" (no quotes of course :)) You can place it anywhere on your hard drive, it doesn't really matter. Put it somewhere you'll easily remember, because you're going to be using it a LOT. I placed mine on my desktop.
    ScreenShot2012-10-02at42205PM.png


    Next, you'll want to download the android SDK from Here. (you won't need to install Java first like you would on a Windows PC, though I would recommend it anyway)
    (As pointed out by Wlmeng11, you could skip this step just download a zip that I will have attached at the bottom of the page containing the adb and fastboot files instead of downloading the whole SDK)
    ScreenShot2012-10-02at42257PM.png


    When the SDK finishes downloading, Unzip it and the contents of the "android-sdk-mac_x86" folder into your android folder.

    Once you have done that, open your android folder. Go into the tools folder inside of it. Double click on the file called "android" (possibly called android sdk) This file is a UNIX executable and will open within a Terminal window.
    ScreenShot2012-10-02at42232PM.png


    When it finishes opening, check the folder called tools. Make sure both "Android SDK Tools" and "Android SDK Platform-tools" are selected within the tools folder. Click install and wait for them to download.
    ScreenShot2012-10-02at42242PM.png


    When they finish downloading, go into the platform-tools folder inside your android folder, then copy adb and fastboot and paste them into the root of your android folder.
    ScreenShot2012-10-02at42733PM.png


    Now that you have adb and fastboot installed, we're going to want to test them to make sure they work.

    Go ahead and plug in your android device at this time. Make sure android debugging is enabled in settings. Go into Settings > Apps > Developer and check it there (for Gingerbread 2.3 and lower) or go into Settings > Developer Options and check it there for Ice Cream Sandwich or Jellybean. As of now, there are two ways to access adb and fastboot.

    Open a Terminal window (look in Applications > Utilities if you can't find it). Type "cd" followed by the path you saved your android folder to (I'm going to use the Desktop for this demonstration) it should look like this
    Code:
    cd /Users/<yourusername>/Desktop/android
    ScreenShot2012-10-02at43423PM.png


    Press enter.
    ScreenShot2012-10-02at43424PM.png


    Now you need to actually execute an adb or fastboot command. To do this, you'll need to type "./adb (or fastboot) <command>" For this tutorial, we will use "ADB devices" since it doesn't actually do anything to the phone. (we won't use fastboot since it requires rebooting to the boot loader which is different for every device)

    In the same terminal window as before type the following:
    Code:
    ./adb devices
    then hit enter. It should turn up your device's serial number. If it does, proceed to the next step, if not recheck your steps, then leave a post in this thread.
    ScreenShot2012-10-02at44100PM.png


    (if it says * daemon not running. starting it now on port 5037 *
    * daemon started successfully * that is perfectly normal)

    Now, at this moment, ADB and Fastboot are both completely useable. However, it's very annoying to have to CD into the directory and use ./ in front of every terminal command. I'll 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
    Code:
    nano ~/.bash_profile

    it will open a window that looks like this:
    ScreenShot2012-10-02at44356PM.png

    (Yours will probably be blank, because I've added a lot of stuff to mine over the years)

    Add a line to it that contains the path to your android folder. (again, I'm using Desktop) It should look like this
    Code:
    export PATH=${PATH}:/Users/<yourusername>/Desktop/android
    ScreenShot2012-10-02at44544PM.png


    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.

    Now we need to verify that it works. Open a new Terminal window and type
    Code:
    adb devices
    If it shows the serial number, then you have set it up successfully and are good to go!
    ScreenShot2012-10-02at44817PM.png


    If you have any questions or issues let me know in the thread below.

    If this has helped, please press thanks!

    Awesome! This made the front page of XDA :) Thanks guys!
    24
    Added screenshots :)
    7
    So... Macs are Impersonal Computers?

    ---------- Post added at 06:24 PM ---------- Previous post was at 06:17 PM ----------

    Nice guide though btw

    Lol I'll fix that. Thanks btw. I'm out today, but I'll give you one tomorrow (too lazy to use my phone)
    4
    you won't need to install Java first like you would on a PC

    So... Macs are Impersonal Computers?

    ---------- Post added at 06:24 PM ---------- Previous post was at 06:17 PM ----------

    Nice guide though btw
    4
    To save time, you might want to just have a adb/fastboot combo instead of the entire sdk.
    (BTW it's tomorrow :p)

    Sent from my HTC Rezound

    Maybe, I actually use other parts of the SDK ;). Ill look into that though
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone