[HOW-TO] Set up SDK/ADB on Ubuntu 11.10 | 32 & 64 bits

Search This thread

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
Video-Tutorial:
http://bit.ly/HzzmUn

Step 1. Install JDK

Open Terminal and enter the following command(s), then enter your ubuntu login password followed by ‘y’ when prompted for yes/no.

Code:
$ sudo apt-get update

$ sudo apt-get install openjdk-6-jdk
Step 2. Install 32 bit libraries - Only for 64 bit users

On x64 systems you are required to install some 32-bit libraries or the android toolkit will not work. In a terminal write:

Code:
$ sudo apt-get install ia32-libs
Step 3. Download and Install Android SDK

Download the Android SDK. Choose the one for linux: android-sdk_r16-linux.tgz

Extract android-sdk_r16-linux.tgz and put the folder in your desired location. I recommend to put it under home/username/ | When using the terminal the same path is described as ~/

Step 4. Choose packages to install

First of all go to ~/android-sdk-linux/tools/
Right clic to android >> Properties >> Permissions
Make sure "allow executing file as a program" it's checked

Screenshot%20at%202012-03-16%2015%3A10%3A13.png


Once done close that window and doble click on the Android file, select Run in Terminal.
Download the tools as shown in the following picture:

Screenshot%20at%202012-03-16%2014%3A12%3A55.png



Step 5. Check your device's permission

Now head over to the platform-tools directory

Code:
$ cd ~/android-sdk-linux/platform-tools
Check if you have permission for your device

Code:
$ ./adb devices
If you're getting the following, go on to Step 6.

Code:
List of devices attached

OR

List of devices attached
????????????    no permissions
If you're getting something like shown below or other random numbers with the word device next to it, congrats! You can now use ADB. Now go on to Step 7.

Code:
List of devices attached
0123456789ABCDEF    device
Step 6. Adding USB Vendor ID of your device

Open HOME folder and enable Show Hidden Files:

Screenshot%20at%202012-03-16%2014%3A24%3A48.png


Open .android folder >> right click >> Create New Document >> Empty Document, name it adb_usb.ini and open it. Put the following on it:

Screenshot%20at%202012-03-16%2014%3A27%3A07.png


Save & close the window

Then unplug your NT and plug it again (From the NT usb port, not PC). Now to check if it works...

Code:
$ ./adb devices
You should be getting something similar to the following line:

Code:
List of devices attached
0123456789ABCDEF    device
Congrats! Now you can use ADB in Ubuntu! Now hop on to Step 7!

Step 7. Create path for ADB

NOTE: while using adb on Linux you'll need to type ./adb to execute adb commands unless you create a path in ~/.bashrc. In a terminal write:

Code:
$ sudo gedit ~/.bashrc
Add the following line at the very end of the file. Once you're done, save and exit.

Code:
# Android tools
export PATH=~/android-sdk-linux/platform-tools:~/android-sdk-linux/tools:$PATH
Then in a Terminal run this command to reload your .bashrc:
Code:
source ~/.bashrc
Now you can just run adb without put ./ before every command.

Screenshot%20at%202012-03-16%2014%3A44%3A31.png


~ Veronica
 
Last edited:

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
Can this help with porting and building from source

______________________________________________
Sent from my SPH-D710-EPIC-4G-TOUCH-using Tapatalk

this helps partly it just gives you the basics to make adb work but if you want to develop then you will need other tools, to setup ubuntu for development/theming then use this script.

~ Veronica
 
  • Like
Reactions: tylerdurdin

Devol

Member
Jan 4, 2007
22
3
Followed your video tutorial, but ubuntu adb still doesn`t see my device, while at the very same time it perfectly works under windows. The only step i missed is step 2, terminal is saying ia32-libs no candidate for installation(translating from russian, might be smth different)
PS: USB debugging is enabled in my nook settings dev
 
Last edited:

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
Followed your video tutorial, but ubuntu adb still doesn`t see my device, while at the very same time it perfectly works under windows. The only step i missed is step 2, terminal is saying ia32-libs no candidate for installation(translating from russian, might be smth different)
PS: USB debugging is enabled in my nook settings dev

cd to the folder where adb is located and type:

$ sudo ./adb devices

~ Veronica
 
  • Like
Reactions: tylerdurdin

Devol

Member
Jan 4, 2007
22
3
I followed your video, so i`ve tried sudo aswell...may be i can just go on with windows adb?
Actually i`ve tried it already, there are only 7 files for 8gb partitions, i`ve copied one of them to my 4th big sdcard partition, and tried to dd if...bla bla bla... = writes error: no space left on device
 
Last edited:

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
I followed your video, so i`ve tried sudo aswell...may be i can just go on with windows adb?
Actually i`ve tried it already, there are only 7 files for 8gb partitions, i`ve copied one of them to my 4th big sdcard partition, and tried to dd if...bla bla bla... = writes error: no space left on device

hmm did you mount /sdcard in CWM? the cwm recovery by @meghd00t works now for 8GB NT... anyways that's ok you can copy it to /data instead of sdcard go one by one, i don't know what exactly you have done to your device but i recommend to just use the necessary partitions.

~ Veronica
 
  • Like
Reactions: tylerdurdin

Devol

Member
Jan 4, 2007
22
3
No, i`m booting of cm7 sd card, used a file manager to go to internal emmc, looks like alot of files there...most 0kb, my mmc0p7 is in dev\block, but not copied fully, only around 208mb(full size is 300mb somthing)...file manager doesn`t allow to delete anything...
 

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
No, i`m booting of cm7 sd card, used a file manager to go to internal emmc, looks like alot of files there...most 0kb, my mmc0p7 is in dev\block, but not copied fully, only around 208mb(full size is 300mb somthing)...file manager doesn`t allow to delete anything...

no, you can't copy from a file manager the partition images neither remove them for security it is why you use dd from CWM to copy the partition images while non of them are IN USE!!!

advice don't be playing around with the partition table, please use @meghd00t recovery he has posted zip with all you need. Boot into CWM from sdcard run the commands.

PS: we're going offtopic in this thread

~ Veronica
 
  • Like
Reactions: tylerdurdin

Devol

Member
Jan 4, 2007
22
3
Nope, it(meghd00t Repartition, Reformat, Restore and Rescue SDcard) also stops at 25% while restoring factory defaults at the last step...(

Ok, my actions that lead to this situation: rooted nook with sd card method for 8gb, installed recovery flasher apk, flashed cwm, followed steps(wiping data, daviks - here it hang up, then rebooted, after that tried flashing cm7 which was a big mistake, wish guys had a word in the topic that it`s not meant for 8gb...and the result is i cant boot from internal mem, only sd. btw, cwm acted strangly, it could hang on all of a sudden, or work for a while, cwm was internally installed, now i`ve removed it)
If we are offtoping, lets move to some other thread...

PS: for some reason nook doesn`t boot from cwm sd(cable plugged, part active fat32)...basicly it will boot only from cm7 rom and meghd00t recovery images.
 
Last edited:

ridleyj329

Senior Member
Oct 12, 2008
448
29
cant get past the checking phone permission stage! keeps saying no permissions. if it helps any, im using ubuntu 12.04. im gonna reboot and try in windows. is there any benefit to using adb in linux over windows anyway?
 

lavero.burgos

Senior Member
Mar 5, 2011
2,836
1,392
cant get past the checking phone permission stage! keeps saying no permissions. if it helps any, im using ubuntu 12.04. im gonna reboot and try in windows. is there any benefit to using adb in linux over windows anyway?

For when you hard brick your device your device yes, you need linux and adb working or for those like me that prefer to use linux over windows daily.

~ Veronica
 

unspokenzero

New member
Jul 9, 2011
3
0
Bamberg
Thanks alot just got this working on ubuntu 12.04 with no issues. Just make sure you complete a:

apt-get update && apt-get upgrade
apt-get dist upgrade prior to any of the steps
 

Top Liked Posts

  • There are no posts matching your filters.
  • 59
    Video-Tutorial:
    http://bit.ly/HzzmUn

    Step 1. Install JDK

    Open Terminal and enter the following command(s), then enter your ubuntu login password followed by ‘y’ when prompted for yes/no.

    Code:
    $ sudo apt-get update
    
    $ sudo apt-get install openjdk-6-jdk
    Step 2. Install 32 bit libraries - Only for 64 bit users

    On x64 systems you are required to install some 32-bit libraries or the android toolkit will not work. In a terminal write:

    Code:
    $ sudo apt-get install ia32-libs
    Step 3. Download and Install Android SDK

    Download the Android SDK. Choose the one for linux: android-sdk_r16-linux.tgz

    Extract android-sdk_r16-linux.tgz and put the folder in your desired location. I recommend to put it under home/username/ | When using the terminal the same path is described as ~/

    Step 4. Choose packages to install

    First of all go to ~/android-sdk-linux/tools/
    Right clic to android >> Properties >> Permissions
    Make sure "allow executing file as a program" it's checked

    Screenshot%20at%202012-03-16%2015%3A10%3A13.png


    Once done close that window and doble click on the Android file, select Run in Terminal.
    Download the tools as shown in the following picture:

    Screenshot%20at%202012-03-16%2014%3A12%3A55.png



    Step 5. Check your device's permission

    Now head over to the platform-tools directory

    Code:
    $ cd ~/android-sdk-linux/platform-tools
    Check if you have permission for your device

    Code:
    $ ./adb devices
    If you're getting the following, go on to Step 6.

    Code:
    List of devices attached
    
    OR
    
    List of devices attached
    ????????????    no permissions
    If you're getting something like shown below or other random numbers with the word device next to it, congrats! You can now use ADB. Now go on to Step 7.

    Code:
    List of devices attached
    0123456789ABCDEF    device
    Step 6. Adding USB Vendor ID of your device

    Open HOME folder and enable Show Hidden Files:

    Screenshot%20at%202012-03-16%2014%3A24%3A48.png


    Open .android folder >> right click >> Create New Document >> Empty Document, name it adb_usb.ini and open it. Put the following on it:

    Screenshot%20at%202012-03-16%2014%3A27%3A07.png


    Save & close the window

    Then unplug your NT and plug it again (From the NT usb port, not PC). Now to check if it works...

    Code:
    $ ./adb devices
    You should be getting something similar to the following line:

    Code:
    List of devices attached
    0123456789ABCDEF    device
    Congrats! Now you can use ADB in Ubuntu! Now hop on to Step 7!

    Step 7. Create path for ADB

    NOTE: while using adb on Linux you'll need to type ./adb to execute adb commands unless you create a path in ~/.bashrc. In a terminal write:

    Code:
    $ sudo gedit ~/.bashrc
    Add the following line at the very end of the file. Once you're done, save and exit.

    Code:
    # Android tools
    export PATH=~/android-sdk-linux/platform-tools:~/android-sdk-linux/tools:$PATH
    Then in a Terminal run this command to reload your .bashrc:
    Code:
    source ~/.bashrc
    Now you can just run adb without put ./ before every command.

    Screenshot%20at%202012-03-16%2014%3A44%3A31.png


    ~ Veronica
    2
    Update april/10

    Added Video-Tutorial

    ~ Veronica
    1
    Can this help with porting and building from source

    ______________________________________________
    Sent from my SPH-D710-EPIC-4G-TOUCH-using Tapatalk

    this helps partly it just gives you the basics to make adb work but if you want to develop then you will need other tools, to setup ubuntu for development/theming then use this script.

    ~ Veronica
    1
    Followed your video tutorial, but ubuntu adb still doesn`t see my device, while at the very same time it perfectly works under windows. The only step i missed is step 2, terminal is saying ia32-libs no candidate for installation(translating from russian, might be smth different)
    PS: USB debugging is enabled in my nook settings dev

    cd to the folder where adb is located and type:

    $ sudo ./adb devices

    ~ Veronica
    1
    I followed your video, so i`ve tried sudo aswell...may be i can just go on with windows adb?
    Actually i`ve tried it already, there are only 7 files for 8gb partitions, i`ve copied one of them to my 4th big sdcard partition, and tried to dd if...bla bla bla... = writes error: no space left on device

    hmm did you mount /sdcard in CWM? the cwm recovery by @meghd00t works now for 8GB NT... anyways that's ok you can copy it to /data instead of sdcard go one by one, i don't know what exactly you have done to your device but i recommend to just use the necessary partitions.

    ~ Veronica