Flex application using RSLs and Flex Mojos/Maven support

Hi all,

the new built-in flex-mojos support is just awsome! I just had to import the Maven 2 projects using Flex Mojos and was able to compile these projects right away. That's really great.

Unfortunately it does not help much, when your application has a dependency to other libraries that are consumed as RSLs. Each time you want to launch the application from within the IDE the application cannot load the library RSLs as they are not included in the target folder. So you have to copy all RSLs of dependent libraries there. But this isn't a practical solution.

So it would be great, if IntelliJ could provide a workaround this:

  1. Suggestion: Look up the libraries that have either the scope 'rsl' or 'caching'  and automatically copy them to the output directory according to the configured rslUrl schema. E.g. this can be configured with Flex Mojos like this:

    so an RSL should be copied to target/rsls/myLibrary-1.0-SNAPSHOT.swf.
  2. When running a compile in IDEA offer the option in the Flex facet to link libraries statically and ignore the RSL scope.

I would prefer Option 1, since this is closest to the Maven build, but Option 2 would also be OK as our current workaround is to not use the generated flex-config, but use the IDEA internal compiler to create an application that statically links against the libraries.

Best regards,

Comment actions Permalink

Hi Carsten,
Thank you for your feedback!
Your suggestion looks reasonable. I'd say it would be better to look for rsl-url not in pom but in flex compiler config file. I think a checkbox could be added to flex run configuration to control files copying. You may open a request for that: http://jetbrains.net/tracker/welcome

Currently if you want to avoid manual copying you may create an ant task and configure it to be executed before launching Flex run configuration.

Comment actions Permalink


yes you are right. Looking that up in the generated compiler file makes more sense and is probably much easier to implement for you. However I just saw that all path-elements refer to artifacts in the Maven repository. It would be better, if IDEA would only take the artifacts that are not build by a module in the current projects from the repository.

Normaly a developer has modules that generate some of his own RSLs. In that case IDEA should make these RSLs and copy them from the output directory of the module and not from the repository.

Best regards,

Comment actions Permalink
However I just saw that all path-elements refer to artifacts in the Maven repository.

I noticed that if pom.xml has ordinary swc dependency


then *-config report.xml file has link to respective swc in local target folder


Can you attach an example of pom.xml and *-config-report.xml files were you expect to see different path?


Please sign in to leave a comment.