IU-90.94 - Flex - Problem with Flex Mojos library project

Hi,

I have a library (swc) project built with Maven that I imported into IDEA.

Running the Maven goals from the Maven Projects panel works as expected. The library compiles and tests are executed correctly.

However, when I try to compile or make using the Compile or Make commands in the IDE, I get the following error: "Invalid target player version '' for facet 'Flex' of module 'spring-actionscript-core'". So I go the module settings and I see that there is no target player. After entering the player version, I try to recompile and get to the error: "Error: unable to open './localFonts.ser'". I get the same error when trying to run one or more tests from the IDE commands.

I'm wondering:
- why do I need to enter a target player for a library project? I have not defined it in my POM files either where compiling works perfectly.
- is there a way to fix this?

regards,
Christophe

10 comments
Comment actions Permalink

Please check 'Use custom compiler configuration file' in your Flex facet settings and make sure that the file ".../target/...-config-report.xml" (that should be in respective text field) really exists. Details are here: http://blogs.jetbrains.com/idea/2009/09/flexmojos-inmaia/

0
Comment actions Permalink

As for the first question about target player. It is important even for library projects because there are different versions of playerglobal.swc file for different Flash player versions. When you do not define it in pom - Flexmojos uses default value. Just look in /target/...-compiler-report.xml - a lot of interesting stuff there

0
Comment actions Permalink

Hi Alexander,

thanks for your answer. The box was not checked so I selected it and it seems to pick up the correct config-report now.

However, I get another error now: "unknown configuration variable 'compute-digest'"

Any ideas?

regards,
Christophe

0
Comment actions Permalink

Check your Flex facet settings again,
I guess you have output type = Application, but flexmojos Library project is imported

0
Comment actions Permalink

Strange, output type is set to "Library".

I noticed that my pom references the 3.4 SDK while I only have:
- compiler-3.2.0.3958.pom
- compiler-3.3.0.4852.pom

Could this be causing the problem?

0
Comment actions Permalink

if you have following flexmojos plugin dependency:
          <dependency>
            <groupId>com.adobe.flex</groupId>
            <artifactId>compiler</artifactId>
            <version>3.4.0.9271</version>
            <type>pom</type>
          </dependency>
then sdk named "compiler-3.4.0.9271.pom" must have been created and set for facet during import. May be you need to force maven reimport manually if auto-reimport is disabled.

In any case it is not connected to 'compute-digest' because compiler configuration options are the same for all Flex SDK 3.x. 'compute-digest' option is valid for SWCs only and the error you pasted can happen only if IDEA tries to compile facet as Application. What compilation command do you see in Messages tool window? 'mxmlc' or 'compc'? I can't believe that IDEA launches 'mxmlc' command for 'Library'-configured facet...

0
Comment actions Permalink

Oh, I see, you get an error with 'compute-digest' when trying to launch FlexUnit. In this case IDEA compiles its Test Runner as application, but it uses the same custom config file. And the options that are valid for SWCs only stop compilation.
It will be fixed soon.
Current workaround is to remove manually <compute-digest> tag and few others from config file.

0
Comment actions Permalink

What's the status on this issue, is there a jira ticket I can look at?

0
Comment actions Permalink

Das Modehaus Alexander McQueen dementierte, dass die Bestellung für http://www.dress4sale.de/strand-brautkleider das Brautkleid der künftigen Prinzessin bei ihm eingegangen sei. "Ich  wüßte es, wenn wir das machen würden", sagte Unternehmenschef Jonathan  Akeroyd laut "Sunday Times". Dem Bericht zufolge hatte Akeroyd

---
Original message URL: http://devnet.jetbrains.net/message/5299675#5299675

0

Please sign in to leave a comment.