Skip navigation.
Home

phoneME Advanced

These are the build instructions to compile the phoneME Advanced CDC profile for Windows Mobile 2003 with Microsoft Embedded Visual C++ 4. Use Microsoft Embedded Visual Tools 3 to target PocketPC 2002 and use Visual Studio 2005 to compile for Windows Mobile 5.

If you check out the sources (as explained here) from the subversion repository into c:\phoneme_advanced_mr2, you can use the following shell script to compile the Foundation Profile for PocketPC 2003 with eVC4.


#!/bin/bash
export JAVA_HOME=/cygdrive/c/j2sdk1.4.2_17
export JAVA_PATH=$JAVA_HOME
export JDK_HOME=$JAVA_HOME
export AWT_PEERSET=pocketpc
export CVM_JAVABIN=$JAVA_HOME/bin
export CVM_PRELOAD_LIB=false
export CVM_JIT=true
export JAVAME_LEGAL_DIR=/phoneme_advanced_mr2/legal
export PATH=/bin:/usr/bin:$JAVA_HOME:/cygdrive/c/Program\ Files/Microsoft\ eMbedded\ C++\ 4.0/EVC/wce420/bin:$PATH
export RC="/cygdrive/c/Program\ Files/Microsoft\ eMbedded\ C++\ 4.0/Common/EVC/Bin/rc.exe"
export USE_VERBOSE_MAKE=true
export VERBOSE_BUILD=true
export J2ME_CLASSLIB=foundation

mount c:/phoneme_advanced_mr2 /phoneme_advanced_mr2
cd /phoneme_advanced_mr2/cdc/build/win32-arm-ppc03
make -f GNUmakefile bin
umount /phoneme_advanced_mr2


1. Build Configuration

Some configuration files need to be modified in order to build phoneME Advanced.

Download the patch:

The profile specific patches can be found below.

2. CDC and Foundation

CDC should build out of the box with the above patches applied, but the following patches add or improve certain features

  • Console.diff: Better console support (no need to install external shell applications).
  • Time.diff: Fix calculation of current time after a device suspends and resumes while application is running
  • SerialAdvanced.diff: Add support for communication over a serial port.


3. Personal Basis Profile

After setting AWT_PEERSET=pocketpc and J2ME_CLASSLIB=basis, the Personal Basis Profile build still requests the "qt.h" header for AWT support. The configuration files probably need to be modified so that the derived AWT_IMPLEMENTATION variable is no longer set to "qt". The Personal Profile does not have this issue.

No patches yet

4. Personal Profile

There are several issues with the Personal Profile build. The Pocket PC java and C/C++ files need to be updated in order to just even compile the software:

  • Lots of new Java and native methods need to be implemented.
  • The jpeg library does not compile cleanly as 'boolean' was already defined differently before.
  • The abstract java RobotHelper class is hardcoded to use Qt, and is thus not platform independent.

I made a small patch that only adds dummy methods and classes in order to build the Personal Profile. You might want to have a look at it. Note though that applying these patches may break other platform builds (that use Qt)!

Download the patches:

  • AwtPPC.diff: This patch contains modifications to Java, C++ and configuration files for Pocket PC.
  • AwtPPCStubs.diff: Contains stubs for unimplemented methods
  • DllLink.diff: Fix some AWT and Jpeg library linking issues.
  • Jpeg.diff: Defines boolean as an unsigned char for WINCE, as it was previously defined in rpcndr.h.
  • RobotHelper.diff: Fix the hardcoded Qt dependency in RobotHelper.java
  • VS2005.diff: Fix some build issues with Visual Studio 2005.


5. Dual Stack with MIDP support

It is possible to run MIDlets on a phoneME Advanced stack. You need at least to build a Foundation Profile to enable MIDP support and
apply several patches to succesfully build the stack.

Download the patches:

  • Appdb.diff: Automatically determine the location of the AppDB based the location of the executable
  • Suite.diff: Add command line options to parse the JAD descriptor of a midlet.
  • Display.diff: Fix some display issues.
  • Alert.diff: Implement audible sounds for the midlet alert notifications.
  • Font.diff: Use a smaller prerendered bitmap font.
  • RMS.diff: Fix some RMS build issues.
  • Abstractions.diff: Fix compilation issues when including optional JSRs.
  • GX.diff: Disable the use of the Game API.
  • WinCEApp.diff: Use plain GDI instead to avoid painting issue and implement some power notifications


6. Build phoneME Advanced

Change your current directory to trunk/build/win32-arm-ppc03 and type 'make -f GNUmakefile bin'. Sometimes compilation fails because the Microsoft compiler tools cannot be found:

  • export PATH=/cygdrive/c/Program\ Files/Microsoft\ eMbedded\ C++\ 4.0/EVC/wce420/bin:$PATH
  • export RC=/cygdrive/c/Program\ Files/Microsoft\ eMbedded\ C++\ 4.0/Common/EVC/Bin/rc.exe

More information can be found at PhoneMEAdvancedPlatformsWindowsMobile.