Setting Java Compiler Options
To set Java compiler options:
- Compile your class files with the Java Development Kit compiler's
-g
command line option.
The -g
option causes the compiler to generate the LocalVariableTable
attribute in the class file. The Converter uses this attribute to determine local variable types.
If you do not use the -g
option, the Converter attempts to determine the variable types on its own. This is expensive in terms of processing and might not produce the most efficient code.You must also compile your class files with the -g
option if you want to generate a debug component in the CAP file by using the Converter's -debug
option.
Do not compile with the -O
option. The -O
option is not recommended on the Java compiler command line, for these reasons:
-
This option is intended to optimize execution speed rather than minimize memory usage. Minimizing memory usage is much more important in the Java Card environment than in other environments.
-
The
LocalVariableTable
attribute is not generated.