Mac users... here's your basics on ADB

Andrew Ruffolo

Well-known member
Jan 5, 2010
3,567
172
0
Visit site
So there are a lot of tutorials out there for windows and cmd prompt. Not one out there for Mac users, though. I did you all one better. I made a tutorial for you all. I recorded a video tutorial, but the screen capture software I used came out crappy, so I'd rather not even post it.
So what is ADB? ADB stands for Android Debugging Bridge and it allows you to gain access to your device. It is an essential part of rooting (if you don't do the flash rec method). It will also allow you to customize a ROM once installed (remove apps and what not). Basically, the code is the same as the windows tutorials, so you can keep those handy. But there are differences.
Good thing:
Takes a lot less time to install the Mac SDK than the Windows one and you don't need to download the Java developer kit as its built in to Mac. So literally you just download the SDK and you are done with setup. Just unzip it and for the basics of the tutorial, place it in your home folder
No drivers to install :)

So whats different?
1. You will use terminal instead of command prompt, but they work very similar. Terminal is located in Utilities (applications--> utilities --> terminal)
2. Well, you may notice in the Windows tutorials, when you are talking about the phone, there are [/] when you are talking about the windows machine, there are [\], thats because linux is Unix based. Mac's are also Unix based, and therefore, will also have [/] when talking about files on the machine.
3. Since it is Unix based, file sites are placed differently. Paths are /users/username/folder/so on.
With a Windows machine, files are c:\ where [c:\] is the drive
4. So lets put it together and add the third point.
Windows: cd c:\android-sdk-windows\tools
mac: cd /users/username/android-sdk-mac_86/tools
You will see terminal navigate to that folder now from:
Code:
YOURNAME's-macbook:~ USERNAME$
to:
Code:
YOURNAME-macbook:tools USERNAME$

Where windows users just type:
Code:
adb devices
Mac users must type:
Code:
./adb devices

From here, you would just follow the steps in the windows tutorials but editing the code to fit Mac (file locations and the ./adb)

Notes:
once you have gotten a little familiar, you can remove some bloatware, but you need to know where they are installed and what their names are. I'm not a nascar fan, so here's my example.

1. mount the phone so you can edit files *WARNING, this could screw up your phone if you aren't careful, so please read all steps first before you just start typing*
Code:
cd android-sdk-mac_86/tools
./adb remount
2. Use a file explorer to find out the APK you don't want. The sprint ones are pretty obvious, but others aren't so don't just delete files you don't know. These files are located in the /system/app/ folder.
Code:
./adb shell
You should see a # sign. This means you are entering commands on the phone level
3.
Code:
rm /system/app/Sprint_Nscar.apk
rm stands for remove and the next code is the path and file name of the Nascar app.
4. Reboot the phone. This closes off the read/write capabilities so you don't accidently screw up vital files.

Enjoy
 

Andrew Ruffolo

Well-known member
Jan 5, 2010
3,567
172
0
Visit site
excellent. thanks!

No problem. I had my mac with me today and I wanted to see what problems people were having... and it is really a lot more confusing on a mac/terminal
I found the ./adb on google and it fixed my issue trying to connect to my sdk/tools. Until the Evo comes out, I'll use the PC/Mac for all input output that has to do with the phone :). Maybe if I set up a donations account, I can cut my out of pocket costs...
 

Jerry Hildenbrand

Space Cowboy
Staff member
Oct 11, 2009
5,569
2,797
113
Visit site
No problem. I had my mac with me today and I wanted to see what problems people were having... and it is really a lot more confusing on a mac/terminal
I found the ./adb on google and it fixed my issue trying to connect to my sdk/tools. Until the Evo comes out, I'll use the PC/Mac for all input output that has to do with the phone :). Maybe if I set up a donations account, I can cut my out of pocket costs...

LOL. I find it much easier on a terminal than a Windows command prompt. It's un-natural for me to type \ vs. / :)
 

tim.sherrod

Member
Apr 18, 2010
7
0
0
Visit site
actually, one quick question. what is the purpose of the sdk tools an do I always have to navigate to them before enter root level on my phone.

Do I always have to type: cd android-sdk-mac_86/tools before ./adb remount and
./adb shell?
 

Andrew Ruffolo

Well-known member
Jan 5, 2010
3,567
172
0
Visit site
um, well.... no
You can just pull the adb file in there and move it to the home folder and you wouldn't even need to navigate to it at all.
 

Gunnyman

Well-known member
Apr 10, 2010
223
3
0
Visit site
you can also use a little unix/linux to eliminate the need for ./

1) download a free text editor called text wrangler
2) Open text wrangler and choose new file
3) put this on one line "export PATH=/SDKLOCATION:$PATH" (no quotes of course) I unzipped my sdk to a folder called /Android so I use /Android for SKDLOCATION
4) save this file call it .bash_profile this dot is very important it tells the mac that this is a hidden file save it to /Users/yourusername
5) Log out

When you log back in you should be able to open a terminal window and type adb without having to cd anywhere or use the ./
 

Forum statistics

Threads
943,188
Messages
6,917,695
Members
3,158,867
Latest member
Non