CLDC software is an OSS community version of Sun Microsystems' Connected Limited Device Configuration HotSpot Implementation virtual machine. Although primarily created from the same shared code base, Sun Microsystems' commercial product might not fully and accurately represent the OSS source base, due to licensing and other legal restrictions.
This document has the following sections:
For more information about building and running CLDC, see CLDC HotSpot Implementation software documentation.
Building a default version of CLDC creates the CLDC software executable cldc_vm.exe for the JavaCall porting layer on a Windows x86 target platform. To properly build the CLDC software on a Windows x86 build platform, you must set the environment variables shown in TABLE 4-1.
The location of your CLDC software
source code workspace. For example,
JVMWorkSpace=%COMPONENTS_DIR%/cldc.
|
|
The location of your CLDC software build output. For example, JVMBuildSpace=%BUILD_OUTPUT_DIR%/cldc. |
|
Required for building CLDC with
the PCSL software component. Must be set to |
|
PCSL_OUTPUT_DIR |
The location of PCSL build output.
Required for building CLDC if |
Required for building a CLDC implementation
with multitasking capability. Must be set to true. If not explicitly set to
Note: If you set
|
|
JAVACALL_OUTPUT_DIR
|
The location of JavaCall porting layer output. For example,
|
TOOLS_DIR |
Defines the directory where needed build tools are located. For example,
|
TOOLS_OUTPUT_DIR |
Defines a directory location for tools-specific output. For example,
|
Building CLDC for a Windows x86 Target Platform
JVMWorkSpace
variable, as shown here.
$ set JVMWorkSpace=%COMPONENTS_DIR%/cldc
JVMBuildSpace
variable, as shown here.
$ set JVMBuildSpace=%BUILD_OUTPUT_DIR%/cldc
make
command as a single command-line string, as shown here.
$ make -C %JVMWorkSpace%/build/javacall_i386_vc ENABLE_PCSL=true PCSL_OUTPUT_DIR=%BUILD_OUTPUT_DIR%/pcsl ENABLE_ISOLATES=true JAVACALL_OUTPUT_DIR=%BUILD_OUTPUT_DIR%/javacall TOOLS_DIR=%COMPONENTS_DIR%/tools TOOLS_OUTPUT_DIR=%BUILD_OUTPUT_DIR%/tools
The generated CLDC output is found under %JVMBuildSpace%/javacall_i386_vc/dist.
Once you build the CLDC software, you can invoke it from the command line to run a class compiled from the Java programming language. The path to the executable depends on the target platform (operating system and processor) for which you build the software.
Running CLDC on a JavaCall porting layer on Windows x86 Target Platform
$ cd %JVMBuildSpace%/javacall_i386/dist
$ bin/cldc_vm.exe -classpath location-of-compiled-applications/classes classname
For example, to run the HelloWorld
application:
$ bin/cldc_vm -classpath C:/src/classes HelloWorld
You can create HTML documents from CLDC porting interfaces. To do this for the CLDC software, use the make docs_html build target.
Generating Javadoc Tool Documentation
Building Javadoc tool documentation is the same for all build platforms.
For example, this could be a Linux on i386 platform, as shown here.
$ cd %JVMWorkSpace%/build/linux_i386
$ make docs_html
Viewing phoneME Feature Documents
Use any browser to display the Javadoc tool output file at the following URL:
first | prev | next-last