Running capgen

To run capgen:

  1. Enter the following on the command line (see capgen Command Line Options for a description of the options):

capgen.[sh|bat] [options] filename

Note:

The file to invoke capgen is a batch file (capgen.bat) that must be run from a working directory of [ $JC_HOME_TOOLS/bin | %JC_HOME_TOOLS%\bin ] in order for the code to execute properly.

Table 5-4 capgen Command Line Options

Option Description

-help

Prints a help message.

-nobanner

Suppresses all banner messages.

filename

Specifies the Java Card Assembly file in case of the compact CAP file generation or a capgen JSON configuration file in case of the extended CAP file generation.

-o filename

Enables you to specify an output file. If the output file is not specified with the -o flag, output defaults to the file a.jar in the current directory.

-version

Outputs the version information.

-config

Enables capgen to run in the extended mode. In this case, the filename parameter is a JSON configuration file, similar to the one given for the Converter in the extended mode. The JCA input files are defined in the configuration file.