Command line compilation of Flex 4

Apr 23, 2010 15:50

1. Download and Install the FlexSDK 4 and unzip it to D:\
The following files should come along with the SDK:
D:\FlexSDK\templates\swfobject
D:\FlexSDK\runtimes\player\10\lnx (lnx for Linux, win for Windows and mac for OS X)

ls -1 D:\FlexSDK\templates\swfobject
history - this is a directory
index.template.html - the template file which must be used for deploying Flex applets.
playerProductInstall.swf - This will help the user install the latest flash player.
swfobject.js - Helper Javascript code for

% ls -1 D:\FlexSDK\runtimes\player\10\lnx
flashplayer.tar.gz
install_flash_player_10_linux.tar.gz
libflashplayer.so.tar.gz

HelloWorld.mxml:

xml version="1.0" encoding="utf-8"?

% mxmlc HelloWorld.mxml

Deployment:
1. Make a copy of D:\FlexSDK\templates\swfobject\index.template.html and open it.

The template contains placeholders for values you should insert. This includes
everything from the page's title (${title}) to the size of the Flash content
(in ${width} and ${height} in multiple places each). Just search for instances
of ${ and edit what you find.
-- ${version_major}.${version_minor}.${version_revision} should be replaced
with 10.0.0 corresponding Flash Player 10.
-- ${expressInstallSwf} should be replaced with the name of the SWF file that
will handle the Flash Player plug-in express installation. The
playerProductInstall.swf file, also found in the SDK's templates/swfobject
directory, can serve this purpose.
-- ${application} should be the project's name.
-- ${swf} is to be replaced with the actual SWF file.
2. Make sure that the other files are also copied to the web server along with the html file:
playerProductInstall.swf and swfobject.js
Up