Specifications

CHAPTER 8
154
The following sections provide examples of using the mxmlc application compiler options on the command line.
You can also use these techniques with the application compilers in the Flex Builder and web-tier environments.
Basic example of using mxmlc
The most basic example is one in which the MXML file has no external dependencies (such as components in a
SWC file or ActionScript classes) and no special options. In this case, you invoke the mxmlc compiler and point
it to your MXML file as the following example shows:
mxmlc c:/myfiles/app.mxml
The default option is the target file to compile into a SWF file, and it is required to have a value. If you use a space-
separated list as part of the options, you can terminate the list with a double hyphen before adding the target file;
for example:
mxmlc -option arg1 arg2 arg3 -- target_file.mxml
verbose-stacktraces=true|false
Generates source code that includes line numbers. When a run-time error
occurs, the stacktrace shows these line numbers.
Enabling this option generates larger SWF files.
Enabling this option does not generate a debug SWF file. To do that, you must
set the
debug option to true.
The default value is false.
verify-digests=true|false
Instructs the application to check the digest of the RSL SWF file against the
digest that was compiled into the application at compile time. This is a security
measure that lets you load RSLs from remote domains or different sub-
domains. It also lets you enforce versioning of your RSLs by forcing an applica
-
tion’s digest to match the RSL’s digest. If the digests are out of sync, you must
recompile your application or load a different RSL SWF file.
For more information about RSLs, see Using Runtime Shared Librarieson
page 195.
version
Returns the version number of the MXML compiler. If you are using a trial or
Beta version of
Flex, the version option also returns the number of days
remaining in the trial period and the expiration date.
warn-warning_type=true|false
Enables specified warnings. For more information, see “Viewing warnings and
errors” on page 172.
warnings=true|false
Enables all warnings. Set to false to disable all warnings. This option over-
rides the warn-warning_type options.
The default value is true.
Option Description