How to manually generate RSL file for Flash Player

Tagged Under : ,

In my last post , I spoke about how we can exclude the RSL files from Flex SWF generation. So, I uploaded framework_3.0.189825.swz file to the same folder where the SWF sits on the server. This file can be found under C:\Program Files\Adobe\Flex Builder 3\sdks\3.0.0\frameworks\rsls assuming that you have the default installation. However, a few people reported that they were getting this error “RSL error 1 of 1″, and on some investigation I got to this link and I realized I was missing a RSL file. The problem was that I had uploaded framework_3.0.189825.swz which is the “signed” framework RSL and I also needed to upload the framework_3.0.189825.swf which is the “unsigned” framework RSL. So I thought its just a matter of uploading the missing file and I should be done.

However, I could not find this file in the RSLs folder. So I did some Googling and followed these steps to generate the .swf file.

1) Extract library.swf file from C:\Program Files\Adobe\Flex Builder 3\sdks\3.0.0\frameworks\libs\framework.swc
2) Using the command line Flex tools, run the following command :-
optimizer library.swf –output framework_3.0.189825.swf –keep-as3-metadata=Bindable,Managed,ChangeEvent,NonCommittingChangeEvent,Transient

This optimizer commands removes any debugging information from the file and makes it fit for deployment.

Then I uploaded the file and the error is now presumably gone. I did test on several different machines.

I just thought this might be some useful information for someone who faces the same problem.