Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,772,773 Members 52,201 Now Online
XDA Developers Android and Mobile Development Forum

[GUIDE] VirtualBox Set-Up (MORE TO COME!)

Tip us?
 
Thatgrass
Old
(Last edited by Thatgrass; 24th April 2013 at 06:00 AM.)
#1  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Default [GUIDE] VirtualBox Set-Up (MORE TO COME!)

Hello there,

Quote:
This thread isn't finished yet. It's a Work In Progress thread, for setting up a working Environment for Developing Apps and also a quick guide for developing ROMs from source. I hope to see you again when there are more updates!
Are you on Windows or OS X and do you want to develop for Android with(out) dual-boot or installing a whole new operating system on your PC? Well, then you have come to the right place!
In this guide I'am going to show you how to set-up a virtual machine with Java, the Android SDK, the Eclipse IDE and the Android Source Code.
I will be using Windows in this tutorial, but you can use pretty much every OS out there; The setup is pretty much the same. I use Ubuntu 12.10 for the VirtualBox guide and 12.04 for the other guides in this thread, but you can use every version of Ubuntu you'd like.
So let's get started.

1. Setting up VirtualBox (You can skip this step if you want to develop apps with your current OS, or if you don't want to build ROMs from source code)
Quote:
VirtualBox is a cross-platform virtualization application. What does that mean? For one thing, it installs on your existing Intel or AMD-based computers, whether they are running Windows, Mac, Linux or Solaris operating systems. Secondly, it extends the capabilities of your existing computer so that it can
run multiple operating systems (inside multiple virtual machines) at the same time. So, for example, you can run Windows and Linux on
your Mac, run Windows Server 2008 on your Linux server, run Linux on your Windows PC, and so on, all alongside your existing applications. You can install
and run as many virtual machines as you like -- the only practical limits are disk space and memory.

VirtualBox is deceptively simple yet also very powerful. It can run everywhere from small embedded systems or desktop class machines
all the way up to datacenter deployments and even Cloud environments.
a. Go to virtualbox.org and select your proper operating system, in my case this will be the Windows Hosts download.
b. Once downloaded, run the installer and leave all boxes ticked as they are and hit ''Install'' at every pop-up.
c. Now go to ubuntu.com and download the 32 or 64 bit image. I'd recommend 32 bit, since it'll run smoother in VirtualBox, but if your intention is to develop ROMs, you should pick the 64 bit.

d. When it has downloaded, open VirtualBox and hit the ''New'' button in the upper left corner. Call it Ubuntu12.10 and make sure it looks like the following.
e. Add at least 1000MB of RAM and if you can spare more, but make sure it's not more than half of your host PC RAM, otherwise you're PC could crash. Then click ''Next".

f.
Now choose ''Create new Virtual Harddisk and hit ''Next'', then choose ''VDI'' and then the ''Dynamic'' option. Now choose you amount of storage in the Virtual Harddisk, I'd recommend at least 40GB, but if you've in mind developing from source, I should go for 70GB or more. After that, click the ''Create'' button.
g. Click on the Ubuntu12.10 tab on the left side and then hit ''Storage'' in the right pannel.
h. Now hit ''Empty'' button underneath ''Controller IDE'', click in the right pannel the disk image and click ''Choose virtual CD/DVD-Image''
i. Navigate to the Ubuntu12.10 Image you've downloaded earlier and open it. After that, hit ''OK'' on the downright corner.

j. Now click the option ''Display'', in the same tab as in step ''g''. Move the ''Videomemory'' all the way up to the top and hit ''OK'' again.

k. Just hit ''Start'' and Ubuntu should right boot to the installer screen.
l. First pick your language on thee right side, then we want to ''Install Ubuntu''.

m.
Tick the boxes ''Download updates while installing'' and ''Install this third-party software''. Make sure you are connected to the internet and your good to go; hit ''Continue''.
n. Leave the installation type on ''Erase Disk and install Ubuntu'', don't worry, this will only wipe your Virtual Harddisk. Hit ''Continue'' again; this will start the installation process.
o. While installing, Ubuntu will ask you for your location, keyboard layout, name and give you some information about Ubuntu 12.10. For me this installation took around 50 minutes.
p. If it says ''Remove Disk please'' or something simular, just press ''Enter''. When the VM has booted up, login, then click at the top ''Devices''. At the bottom it says:''Install Guest additions..''. Click it and follow the instructions on screen. It'll auto-reboot.
q. The last step: Search for the programm: ''Software Updater'' in ''Dash Home''. Open it and it will check for updates, then click ''Install now''. This will install the latest Ubuntu updates.
Now you have a complete Ubuntu OS running in VirtualBox. Congratulations!
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
The Following 12 Users Say Thank You to Thatgrass For This Useful Post: [ Click to Expand ]
 
Thatgrass
Old
(Last edited by Thatgrass; 6th April 2013 at 06:32 PM.)
#2  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Reserved for further updates
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
The Following User Says Thank You to Thatgrass For This Useful Post: [ Click to Expand ]
 
Thatgrass
Old
(Last edited by Thatgrass; 6th April 2013 at 06:32 PM.)
#3  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Reserved for further updates
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
 
Thatgrass
Old
#4  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Reserved for further updates
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
 
pedja1
Old
#5  
pedja1's Avatar
Recognized Developer
Thanks Meter 1599
Posts: 1,262
Join Date: Oct 2011
Location: Zrenjanin

 
DONATE TO ME
I don't know about OS X but eclipse works in both Linux and windows. Why would anyone want to setup virtualbox for app development?
Device: Nexus 5 ROM:Stock, Android 4.4.4 Recovery: TWRP Multirom

My Blog - latest news about my projects and stuff

 
Thatgrass
Old
#6  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Quote:
Originally Posted by pedja1 View Post
I don't know about OS X but eclipse works in both Linux and windows. Why would anyone want to setup virtualbox for app development?
If you are a developer you can definately use linux, because of the android and linux integration; when developing for Android, Linux provides more features than Windows or OS X does.

Thatgrass.
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
 
thewadegeek
Old
#7  
thewadegeek's Avatar
Senior Member
Thanks Meter 762
Posts: 694
Join Date: Mar 2011
Location: Cedar Rapids
Quote:
Originally Posted by Thatgrass View Post
If you are a developer you can definately use linux, because of the android and linux integration; when developing for Android, Linux provides more features than Windows or OS X does.

Thatgrass.
No really. You get all the same features in OS X and Windows, I can't think of one reason to use Linux over any of the other areas.
Search before asking for help.
Search again.
Once more.
And again.
Now post.
Oh and you ask for thanks? I say no.
 
Tungstwenty
Old
#8  
Tungstwenty's Avatar
Recognized Contributor
Thanks Meter 4366
Posts: 1,799
Join Date: Nov 2011

 
DONATE TO ME
Quote:
Originally Posted by Thatgrass View Post
c. Now go to ubuntu.com and download the 32 or 64 bit image. I'd recommend 32 bits, since it'll run smoother in VirtualBox.
If you're going to build parts Android (the OS, I mean) from source, I believe JB *requires* a 64-bit VM.

Device: Xperia Z (C6603)
ROM: Stock 4.4.2 10.5.A.0.230
Locked bootloader, rooted, XZDualRecovery
Retired device: Samsung Galaxy S2 (GT-I9100)

My threads that you might find useful:

SUPERCOMPUTER: what it sounded like before you bought it
 
Thatgrass
Old
#9  
Thatgrass's Avatar
Senior Member - OP
Thanks Meter 541
Posts: 1,618
Join Date: Jan 2012
Location: XDA-Developers

 
DONATE TO ME
Quote:
Originally Posted by Tungstwenty View Post
If you're going to build parts Android (the OS, I mean) from source, I believe JB *requires* a 64-bit VM.
There is still more to come
Devices
Sony Ericsson W250 > Samsung Galaxy Gio > Samsung Galaxy Nexus > Samsung Galaxy Note > HTC One X Plus > Samsung Galaxy Mega 6.3 > HTC One M7 > Nokia Lumia 1020 > LG G Flex
Acer Iconia W700
LG G Watch
_____________________________________________
Development
Visit the Hexus project here
 
Rescue9
Old
#10  
Rescue9's Avatar
Senior Member
Thanks Meter 19
Posts: 183
Join Date: Oct 2007
Quote:
Originally Posted by pedja1 View Post
I don't know about OS X but eclipse works in both Linux and windows. Why would anyone want to setup virtualbox for app development?
My Windoze side is really just for gaming & a bit of photoshop work. I much prefer developing on the Linux side for ease of use, especially with command line stuff. It all just works 'better'. I've been using Ubuntu 12.04 64bit with Eclipse Juno as a guest on my hosting Win 7 machine for over a year now. I find it much better to compartmentalize my work, especially since I routinely reformat my win partition for various reasons.
AT&T HTC One M8
ROM:CM 11 M9 w/ Furnace Kernel

Galaxy Note 10.1
ROM:CM10.1 2014-03-23 Nightly


Please hit "Thanks" if this post helped.

The Following User Says Thank You to Rescue9 For This Useful Post: [ Click to Expand ]
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes