Monday 17 January 2011

BlackBerry Environment Setup Under Ubuntu


Notes:

These instructions were developed under Ubuntu 10.04 (Lucid Lynx), wine version 1.1.42.

Before proceeding with the setup, create a developer account on http://na.blackberry.com/eng/developers/

Steps:

1. Install wine

sudo aptitude install wine

2.From winetricks you need gdiplus and msxml3. You can get winetricks from here http://wiki.winehq.org/winetricks. To install these simply run:

sh winetricks

and a GUI with a list of available packages will open.

3.Install Sun JDK for windows on wine. Download the latest version of JDK for Windows (remember to get the Windows version, not the linux one. You'll be installing it with wine) from http://www.java.sun.com. Go to your download folder and run:

wine jdk-6u20-windows-i586.exe

4.After you install the JDK you need to insert your JDK path on wine. For this, edit ~/.wine/system.reg and find this line:

"PATH"=str(2):"C:\\Windows\\system32;C:\\Windows"

Change it so it'll look like this:

"PATH"=str(2):"C:\\Windows\\system32;C:\\Windows;C:\\Program Files\\Java\\jdk1.6.0_20\\bin"

After this you can try:

wine javac

to see if the new settings are correct.

5.Install Eclipse. Do not install from aptitude. You need to get the windows 3.5.2 version from here http://www.eclipse.org/downloads/packages/release/galileo/sr2 and extract eclipse in your home folder. It needs to be in your home folder, otherwise RIM JDE won't work.

6.Start Eclipse by going into ~/eclipse and running:

wine eclipse

and go to: Help -> Install New Software and click on Add. In the location field insert this link http://www.blackberry.com/go/eclipseUpdate/3.5/java and click OK. From the list that is generated select “Blackberry Java Plug-in” and “BlackBerry Java SDK 5.0.0” and start the installation. Now you'll use the user/password created on http://na.blackberry.com/eng/developers/. You'll be prompted for those. After eclipse finishes the installations, restart it.

7.Go to eclipse_home/plugins/net.rim.ide..../components/bin and, on all .rc files, change “\” with “/”.

8.Go to eclipse_home/plugins/net.rim.ide..../components/simulator/ and change paths on SimPackage_JDE.rc

Now you should have a working environment.

Links:

http://supportforums.blackberry.com/t5/Java-Development/Eclipse-JDE-Plugin-Linux-a-working-environment/m-p/192473

No comments:

Post a Comment