The Source for Java Technology Collaboration


Sharp Zaurus using pdaXrom

A powerful machine like the Zaurus just deserves a decent Java environment. It's just great to develop and run Java applications in the palm of your hand.
These instructions cover building the phoneME Advanced MR2 CDC Personal Profile plus MIDP Profile and Jump (Application Management System) implementation.
The target device was a Sharp Zaurus SL-C750 running pdaXrom version 1.1.0 RC12.

Binary distribution

A binary distribution can be found on the Zaurus OESF forum

Prerequisites

Make sure your Linux host meets all requirements as described in Sun CDC Build System Guide.
I used Ubuntu version 6.10 running in VirtualBox on Windows XP. Works like a charm for me.

In my case (standard Ubuntu with development tools) I had to additionally install:

  1. Java J2SE?. To be on the save side, Download and install version 1.4.2
  2. Install some optional packages:
      # sudo apt-get install g++
      # sudo apt-get install bison
      # sudo apt-get install flex
      # sudo apt-get install ant (I'm not sure about this one)
      # sudo apt-get install ant-optional (I'm not sure about this one)
      # sudo apt-get install gawk
       

Setup cross compilation environment

  1. Download the pdaXrom Cross-SDK toolchain. Make sure you install the right version. I used the RC12 version.
  2. Extract the SDK in the / directory.

Getting the PhoneME source

  1. Make and go to build directory
       # mkdir ~/src/phoneme
       # cd ~/src/phoneme
       
  2. Check out the latest sources from the trunk with Subversion:
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/cldc/trunk cldc
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/pcsl/trunk pcsl
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/midp/trunk midp
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/cdc/trunk cdc
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/tools/trunk tools
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/jump/trunk jump
       # svn co https://phoneme.dev.java.net/svn/phoneme/components/abstractions/trunk abstractions
       

Build steps

  1. Do NOT run /opt/cross/arm/3.4.4-xscale-softvfp/runsdk.sh as you normally would do
  2. Go to the build directory
       cd ~/src/phoneme/cdc/build/linux-arm-generic
       
  3. Append the toolchain directory to the search path
       export PATH=/opt/cross/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux/qt/bin:$PATH
       
  4. Starting the build
       make \
         JDK_HOME=/usr/java/j2sdk1.4.2_13 \
         J2ME_CLASSLIB=personal \
         CVM_TARGET_TOOLS_PREFIX=/opt/cross/arm/3.4.6-xscale-softvfp/bin/armv5tel-linux- \
         QT_TARGET_DIR=/opt/cross/arm/3.4.6-xscale-softvfp/armv5tel-cacko-linux/qt \
         CC_ARCH_FLAGS="-march=armv5 -mtune=xscale" \
         HOST_CC=/usr/bin/cc HOST_CCC=/usr/bin/g++ \
         AWT_IMPLEMENTATION=peer_based AWT_PEERSET=qt \
         CVM_PRELOAD=true USE_MIDP=true USE_JUMP=true \
         USE_GCI=false USE_DIRECTFB=false \
         USE_STATIC_PROPERTIES=true USE_AAPCS=false 
       

Create the installation package

Run the same make command again, this time use make bin

Installation

It's beyond the scope of this instruction how to create a installation package (ipk file) for the Zaurus, so I keep it simple here.
Just transfer the zip file from ~/src/phoneme/cdc/build/linux-arm-generic/install to the Zaurus, and extract the file in /usr/java

Testing

On the Zaurus, go to the java directory and run some tests

   # cd /usr/java
   # bin/cvm -cp testclasses.zip Test
   
After running the tests, this should result in the message
   *CONGRATULATIONS: test Test completed with 411 tests passed and 0 failures
   

A more compelling test is maybe

   # bin/cvm -cp democlasses.jar personal.DemoFrame
   

Notes

  1. I created a special build directory (~/src/phoneme/cdc/build/linux-arm-pdaxrom) and added a few of the build options. The above instructions work similar, so I left it out.
  2. I've succesfully build the same configuration with the gtk-peer instead of the qt-peer. I've not tested this thoroughfully, so I hope to come back with more info on that.
  3. Feel free to email questions (omegamoon [at] gmail.com) and I'll try to be of any help if I can

-- Main.egoelema - 08 Jun 2007

Topic PhoneMEAdvancedPlatformsZaurusPdaXrom . { Edit | Ref-By | Printable | Diffs r4 < r3 < r2 < r1 | More }
 XML java.net RSS

Revision r4 - 06 Jul 2007 - 20:45:17 - Main.egoelema
Parents: WebHome > PhoneMEAdvanced