A script enabled browser is required for this page to function properly.
Exit Print View

Oracle® Java Micro Edition Embedded Client Installation Guide, Version 1.0

Get PDF Book Print View
 

Document Information

1.  System Requirements

2.  Installation Procedures

Installing the SDK

Install the Linux/X86 SDK

Install the Windows SDK

SDK Installation Structure

Setting Up the Target Runtime Environment

Install the Linux/ARM Package on the Host

Test an Oracle Java ME Embedded Client Application on the Linux/ARM Target

3.  Working With NetBeans

4.  Working With Eclipse

5.  Command Line Options

Chapter 2

Installation Procedures

This chapter discusses installation procedures for the Oracle Java ME Embedded Client SDK binary and the environment required to support the emulator.

Installing the SDK

This section describes how to install the SDK on Linux and Windows hosts.

Install the Linux/X86 SDK

Before You Begin

This command line procedure installs the SDK in /usr/local.

  1. Download the Oracle Java ME Embedded Client bundle to any location on a compliant system.
  2. From a Linux terminal use the following command to enable execute permissions on the binary:
    $ chmod +x ./ojec_1.0_linux_x86_sdk.bin
  3. Use the following steps to run the installer binary:
    $ sudo ./ojec_1.0_linux_x86_sdk.bin
    $ [sudo] password for userid:
    $ Oracle Java Micro Edition Embedded client version 1.0 
      Installer is starting, please wait...
  4. At the prompt, type 1 to start the installation.
    1 - Install
    2 - Uninstall
    3 - Quit
    Enter choice: 1
    Installing Oracle Java Micro Edition Embedded Client
    version 1.0...

    If the installation is successful you will see the message “Installation completed.”

    If another version exists in /usr/local, you will be warned:

    Please note that installation directory 
    /usr/local/Oracle_JavaME_Embedded_Client/1.0
    is not empty and files under it will be overwritten! 
    Do you want to continue [y/n]?

    Type y to continue or n to exit.

    Oracle Java ME Embedded Client is installed in /usr/local/Oracle_JavaME_Embedded_Client/1.0.

Install the Windows SDK

Before You Begin

This command line procedure installs the SDK in C:\Program Files\Oracle\Oracle JavaME Embedded Client\1.0 by default.

  1. Download the file ojec_1.0_win32_x86_sdk.zip. Extract the zip file.

    This exposes ojec-sdk-setup.msi and setup.exe.

  2. Double-click on setup.exe to start the installation.
    Welcome page of SDK installer for Windows platform.

    Click Next to continue.

  3. Select an installation folder.
    Dialog box with a Browse button to allow the user to search for the desired installation folder. Then a Next button to continue.
  4. Confirm that you want to start the installation.
    Click Next to confirm that you want to start the installation.
  5. Click Close at the end of the installation.
    Click Close at the end of the installation.

SDK Installation Structure

The default installation locations are:

Linux:
Windows:
/usr/local/Oracle_JavaME_Embedded_Client/1.0
C:\Program Files\Oracle\Oracle JavaME Embedded Client\1.0 (on 32-bit machines) or C:\Program Files (x86)\Oracle\Oracle JavaME Embedded Client\1.0 (on 64-bit machines)

The installation directory contains the following subdirectories:

docs/
Contains all binary files, libraries and others necessary to run the Java Virtual Machine.
Contains API documentation and product documentation for the JSRs provided with this SDK.
legal/
emulator-platform/
Contains license agreements for the Oracle Java Micro Edition Embedded Client.

Setting Up the Target Runtime Environment

The procedures in this section describe how to install the runtime package on a Linux development host and make it available to a target device.

The procedures in this section describe working with the runtime binary targeted for an ARMv7 device running Linux. The procedures are very similar for the other available runtime binaries, such as ARMv5, MIPS or Power PC.

Install the Linux/ARM Package on the Host

Before You Begin

When an embedded platform has limited memory it is advisable to install the stack on the host, then mount the stack from the ARM device. If the ARM device has sufficient storage you can copy the Oracle Java ME Embedded Client platform directory to the device.

  1. Download ojec_1.0_linux_arm_pack.tar.gz and save it on a qualified Linux host (see SDK Requirements).
  2. To extract the contents in the current directory, use this command:

    tar xfz ojec_1.0_linux_arm_pack.tar.gz

    The directory Oracle_JavaME_Embedded_Client/1.0 is created in the extraction directory. It includes these subdirectories:


       binaries
    All binaries and libraries for Oracle Java ME Embedded Client for Linux/ARM.
       legal
    Copyright and other legal documents.
       docs
    All relevant documentation for Oracle Java ME Embedded Client.
  3. If you are going to copy the stack to the device, mount the Oracle_JavaME_Embedded_Client/1.0 directory. If you are going to mount the binaries from the ARM device, export the Oracle_JavaME_Embedded_Client/1.0/binaries directory.

    For example, add the path to /etc/exports with proper permissions and then restart the NFS server.

Optional JAR Files in the Stack

The Oracle Java ME Embedded Client runtime for Linux/ARM comes bundled with a number of optional packages, which are found in:

InstallDir/Oracle_JavaME_Embedded_Client/1.0/binaries/lib

If these APIs are not used and you choose to reduce the size of the static footprint, you can safely delete any of the following files from the system:

Optional Package
File Name(s)
RMI Optional Package Specification Version 1.0
jsr66.jar
JDBC Optional Package for CDC/Foundation Profile 1.0
jsr169.jar
J2ME ME Web Services Specification 1.0
jsr172.jar, xmlparser.jar
Security Optional Package 1.0
jaas.jar, jce.jar, jsse-cdc.jar, ext/sunjec_provider.jar, sunrsasign.jar

Test an Oracle Java ME Embedded Client Application on the Linux/ARM Target

Before You Begin

These instructions assume the target device complies with the Target Device Requirements.

  1. From the Linux/ARM target platform, mount the directory exported from the Linux host computer in Step 3 of Install the Linux/X86 SDK.

    For example:

    mount -t nfs -o nolock 
    linuxhost:/usr/local/Oracle_JavaME_Embedded_Client/1.0/binaries
    /mnt/Oracle_JavaME_Embedded_Client

    Alternatively, you can copy the entire stack from the mount point to the device, or only the parts of the stack you need, as described in Step 3 in Install the Linux/ARM Package on the Host.

  2. Use the Oracle Java ME Embedded Client SDK to build and compile an application on the Linux host computer.

    Note - In version 1.0, the only available client is headless. Your application must use a Main file that uses public static void main (String[] args) { }. Your headless application must not use an Xlet and it must not rely on a graphics stack.


  3. Make your application’s JAR (or class) file accessible from the Linux/ARM target platform (for example, use mount).
  4. Run the application using either the optimized version or the debug version of the VM:

    InstallDir/Oracle_JavaME_Embedded_Client/1.0/binaries/bin/cvm

    For example:

    cd /mnt/Oracle_JavaME_Embedded_Client/1.0/bin

    ./cvm -cp /projects/Hello/dist/Hello.jar hello.Main

    Check the output to validate the results.