Hi,
I'm working on a flex sdk4 project. I'm using spark components in the
project. Now, when I build the project using flex-mojos, I get the
following error for all fx namespace references in all mxml files:

Error: [Could not resolve <fx:Script> to a component implementation]

Here is my POM. Please suggest if there is a missing dependency?

<project xmlns="http://maven.apache.org/POM/4.0.0";
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd";>
        <parent>
                <groupId>com.scm</groupId>
                <artifactId>master-flex-player10</artifactId>
                <version>20</version>
        </parent>
        <artifactId>myproject</artifactId>
        <properties>
                <majorMinorVersion>0.0</majorMinorVersion>
                <patchVersion>1</patchVersion>
                <buildNumber>${BUILD_NUMBER}</buildNumber>
                <flex.version>4.1.0.16076</flex.version>
        </properties>
        <version>${majorMinorVersion}.${patchVersion}</version>
        <modelVersion>4.0.0</modelVersion>
        <groupId>com.scmt</groupId>
        <packaging>swf</packaging>

        <dependencies>
                <dependency>
                        <groupId>com.adobe.flex.framework</groupId>
                        <artifactId>textLayout</artifactId>
                        <version>${flex.version}</version>
                        <type>swc</type>
                        <scope>caching</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>framework</artifactId>
            <version>${flex.version}</version>
            <type>swc</type>
            <scope>caching</scope>
        </dependency>
        <dependency>
               <groupId>com.adobe.flex.framework</groupId>
               <artifactId>playerglobal</artifactId>
               <version>${flex.version}</version>
               <classifier>10</classifier>
               <type>swc</type>
                </dependency>
                <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>spark</artifactId>
            <version>${flex.version}</version>
            <type>swc</type>
            <scope>caching</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>sparkskins</artifactId>
            <version>${flex.version}</version>
            <type>swc</type>
            <scope>caching</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>rpc</artifactId>
            <version>${flex.version}</version>
            <type>swc</type>
            <scope>caching</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>datavisualization</artifactId>
            <version>${flex.version}</version>
            <type>swc</type>
            <scope>caching</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flex.framework</groupId>
            <artifactId>flex-framework</artifactId>
            <version>${flex.version}</version>
            <type>pom</type>
        </dependency>
        </dependencies>
        <build>
                <finalName>${artifactId}.${version}-local</finalName>
                <sourceDirectory>src/main/flex</sourceDirectory>

                <resources>
                        <resource>
                                <directory>src/main/resources</directory>
                                <filtering>true</filtering>
                        </resource>
                </resources>
                <plugins>
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
                                <artifactId>maven-resources-plugin</artifactId>
                                <executions>
                                        <execution>
                                                <id>process-as</id>
                                                <phase>process-resources</phase>
                                                <goals>
                                                        <goal>resources</goal>
                                                </goals>
                                                <configuration>
                                                        <outputDirectory>
                                                                
${basedir}/target/generated-as
                                                        </outputDirectory>
                                                </configuration>
                                        </execution>
                                </executions>
                        </plugin>
                        <plugin>
                                <groupId>info.flex-mojos</groupId>
                                <artifactId>flex-compiler-mojo</artifactId>
                                <configuration>
                                        <skipTests>false</skipTests>
                                        <moduleFiles>
                                                
<module>VideoClipping.mxml</module>
                                        </moduleFiles>
                                        <sourcePaths>
                                                
<path>${project.build.sourceDirectory}</path>
                                                
<path>${basedir}/target/generated-as</path>
                                        </sourcePaths>
                                        <includeSources>
                                                
<param>${project.build.sourceDirectory}</param>
                                                
<param>${basedir}/target/generated-as</param>
                                        </includeSources>
                                        
<loadExternsOnModules>false</loadExternsOnModules>
                                        
<configurationReport>true</configurationReport>

                                </configuration>
                        </plugin>
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
                                <artifactId>maven-dependency-plugin</artifactId>
                                <executions>
                                        <execution>
                                                <id>copy-dependencies</id>
                                                <phase>validate</phase>
                                                <goals>
                                                        
<goal>copy-dependencies</goal>
                                                </goals>
                                                <configuration>
                                                        
<outputDirectory>libs</outputDirectory>
                                                        
<overWriteReleases>true</overWriteReleases>
                                                        <overWriteSnapshots>
                                                                true
                                                        </overWriteSnapshots>
                                                        
<overWriteIfNewer>true</overWriteIfNewer>
                                                        
<excludeTransitive>true</excludeTransitive>
                                                        <excludeGroupIds>
                                                                
com.adobe.flex.sdk,com.adobe.flex.framework
                                                        </excludeGroupIds>
                                                </configuration>
                                        </execution>
                                </executions>
                        </plugin>
                </plugins>
        </build>
        <profiles>
                <profile>
                        <id>hudson</id>
                        <build>
                                <finalName>
                                        ${artifactId}.${version}-${BUILD_NUMBER}
                                </finalName>
                        </build>
                </profile>
                <profile>
                        <activation>
                                <os>
                                        <family>unix</family>
                                </os>
                        </activation>
                        <build>
                                <plugins>
                                        <plugin>
                                                
<groupId>info.flex-mojos</groupId>
                                                
<artifactId>flex-compiler-mojo</artifactId>
                                                <configuration>
                                                        <flexUnitCommand>
                                                                
<argument>gflashplayer</argument>
                                                                <argument>
                                                                        
${project.build.testOutputDirectory}/TestRunner.swf
                                                                </argument>
                                                        </flexUnitCommand>
                                                </configuration>
                                        </plugin>
                                </plugins>
                        </build>
                </profile>
                <profile>
                        <id>flexunit-mac</id>
                        <activation>
                                <os>
                                        <family>mac</family>
                                </os>
                        </activation>
                        <build>
                                <plugins>
                                        <plugin>
                                                
<groupId>info.flex-mojos</groupId>
                                                
<artifactId>flex-compiler-mojo</artifactId>
                                                <configuration>
                                                        <flexUnitCommand>
                                                                
<argument>open</argument>
                                                                
<argument>-g</argument>

                                                                <argument>
                                                                        
${project.build.testOutputDirectory}/TestRunner.swf
                                                                </argument>
                                                        </flexUnitCommand>
                                                </configuration>
                                        </plugin>
                                </plugins>
                        </build>
                </profile>
        </profiles>
        <reporting>
                <plugins>
                        <plugin>
                                <groupId>info.flex-mojos</groupId>
                                <artifactId>asdoc-mojo</artifactId>
                                <configuration>
                                        <!-- Paths to classes -->
                                        <sourcePaths>
                                                
<path>${project.build.sourceDirectory}</path>
                                                
<path>${basedir}/target/generated-as</path>
                                        </sourcePaths>
                                </configuration>
                        </plugin>
                </plugins>
        </reporting>
</project>

thanks,
Komal

-- 
You received this message because you are subscribed to the Google
Groups "Flex Mojos" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/flex-mojos

http://flexmojos.sonatype.org/

Reply via email to