Hello,

I have a Flex (AIR)/Java project that I had been running with the 4.9
SDK/Maven 2/Flexmojos 3.7.1. Recently we've decided to update to SDK 4.14.1,
and so I've since discovered that Maven 3 and Flexmojos 7.1.0 come along
with it. I've mavenized my implementation already, but I'm running into this
compilation error:

[ERROR] Failed to execute goal
net.flexmojos.oss:flexmojos-maven-plugin:7.1.0-SNAPSHOT:compile-swf
(default-compile-swf) on project XXXX:
java.lang.reflect.InvocationTargetException: Unable to retrieve flex default
namespaces! NullPointerException -> [Help 1]

I have these namespaces defined in air-config.xml in my project, but FM
doesn't seem to know about them. I'm also running IntelliJ 12, which I've
read has a bug (https://youtrack.jetbrains.com/issue/IDEA-112107) that
prevents FM from generating a configuration file (could this be related?)

With the same POM in Flash Builder 4.7 though, I get this error:

Project build error: Unresolveable build extension: Plugin
net.flexmojos.oss:flexmojos-maven-plugin:7.1.0-SNAPSHOT or one of its
dependencies could not be resolved: The following artifacts could not be
resolved: org.eclipse.sisu:org.eclipse.sisu.plexus:jar:0.3.1,
org.eclipse.aether:aether-spi:jar:1.0.0.v20140518,
org.eclipse.aether:aether-impl:jar:1.0.0.v20140518,
org.eclipse.aether:aether-api:jar:1.0.0.v20140518: The repository system is
offline but the artifact org.eclipse.sisu:org.eclipse.sisu.plexus:jar:0.3.1
is not available in the local repository.       


My POM is pasted below.  Thanks!

<?xml version="1.0" encoding="utf-8"?>
<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";>

    <modelVersion>4.0.0</modelVersion>
    <groupId>com.XXXXX</groupId>
    <artifactId>XXXX</artifactId>
    <version>2.3.15rc2-SNAPSHOT</version>
    <packaging>swf</packaging>

    <name>XXXX</name>

    <properties>
       
<flashPlayer.command>${user.home}/.m2/repository/com/adobe/flash/flashplayer-debug/10.0/flashplayer-debug-10.0.exe</flashPlayer.command>
        <flex.version>4.14.1.20150325</flex.version>
        <FLEX_HOME>C:/PROGRA~2/Apache Flex/Flex 4.14.1</FLEX_HOME>
        <air.version>18.0</air.version>
    </properties>

    <dependencies>
        
        <dependency>
          <groupId>org.apache.flex</groupId>
          <artifactId>framework</artifactId>
          <version>4.14.1.20150325</version>
          <type>pom</type>
        </dependency>
        
        <dependency>
          <groupId>com.adobe.flash.framework</groupId>
          <artifactId>playerglobal</artifactId>
          <version>18.0</version>
          <type>swc</type>
        </dependency>
        <dependency>
            <groupId>org.apache.flex.framework.air</groupId>
            <artifactId>airframework</artifactId>
            <version>${flex.version}</version>
            <type>pom</type>
        </dependency>
        
        <dependency>
            
            <groupId>com.adobe.flash</groupId>
            <artifactId>flashplayer-debug</artifactId>
            <version>10.0</version>
            <type>exe</type>
        </dependency>
        <dependency>
            <groupId>com.adobe.air.framework</groupId>
            <artifactId>aircore</artifactId>
            <version>${air.version}</version>
            <type>swc</type>
        </dependency>
        <dependency>
            <groupId>org.apache.flex.framework.air</groupId>
            <artifactId>airframework</artifactId>
            <version>${flex.version}</version>
            <classifier>en_US</classifier>
            <type>rb.swc</type>
        </dependency>
        <dependency>
            <groupId>com.adobe.air.framework</groupId>
            <artifactId>airglobal</artifactId>
            <version>${air.version}</version>
            <type>swc</type>
        </dependency>

        <dependency>
            <groupId>org.swizframework</groupId>
            <artifactId>swiz-framework</artifactId>
            <version>1.0</version>
            <classifier>RC1</classifier>
            <type>swc</type>
            <scope>internal</scope>
        </dependency>
        <dependency>
            <groupId>com.adobe.flash</groupId>
            <artifactId>as3corelib</artifactId>
            <version>0.92</version>
            <type>swc</type>
        </dependency>
    </dependencies>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>net.flexmojos.oss</groupId>
                    <artifactId>flexmojos-maven-plugin</artifactId>
                    <version>7.1.0-SNAPSHOT</version>
                    <extensions>true</extensions>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>exec-maven-plugin</artifactId>
                    <version>1.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-antrun-plugin</artifactId>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-assembly-plugin</artifactId>
                    <version>2.2-beta-5</version>
                </plugin>
            </plugins>
        </pluginManagement>

        <resources>
            <resource>
                <directory>src/main/flex/assets</directory>
                <targetPath>${project.build.directory}/assets</targetPath>
            </resource>
            <resource>
                <directory>src/main/flex/config</directory>
                <targetPath>${project.build.directory}/config</targetPath>
            </resource>
            <resource>
                <directory>src/main/flex/lib</directory>
                <targetPath>${project.build.directory}/lib</targetPath>
            </resource>
        </resources>

        <sourceDirectory>src/main/flex</sourceDirectory>
        <testSourceDirectory>src/test/flex</testSourceDirectory>

        <plugins>
            <plugin>
                <groupId>net.flexmojos.oss</groupId>
                <artifactId>flexmojos-maven-plugin</artifactId>
                <version>7.1.0-SNAPSHOT</version>
                <extensions>true</extensions>
                <configuration>
                    <sourceFile>XXXX.mxml</sourceFile>
                </configuration>
                <dependencies>
                  
                  <dependency>
                    <groupId>net.flexmojos.oss</groupId>
                   
<artifactId>flexmojos-threadlocaltoolkit-wrapper</artifactId>
                    <version>7.1.0-SNAPSHOT</version>
                  </dependency>
                  
                  <dependency>
                    <groupId>org.apache.flex</groupId>
                    <artifactId>compiler</artifactId>
                    <version>4.14.1.20150325</version>
                    <type>pom</type>
                  </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <executions>
                    <execution>
                        <id>copy ${project.artifactId}.${project.packaging}
and related artifacts</id>
                        <phase>compile</phase>
                        <configuration>
                            <tasks>
                                <copy
file="${project.build.directory}/${project.artifactId}-${project.version}.${project.packaging}"
tofile="${project.build.directory}/${project.artifactId}.${project.packaging}"
/>
                                <copy
file="${project.build.directory}/../src/main/flex/XXXX-app-build.xml"
tofile="${project.build.directory}/XXXX-app.xml" />
                            </tasks>
                        </configuration>
                        <goals>
                            <goal>run</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <pluginRepositories>
        <pluginRepository>
            <id>flex-mojos-plugin-repository</id>
           
<url>http://cabelsvn05:8081/nexus/content/repositories/sonatype-snapshots</url>
            <releases> <enabled>false</enabled> </releases>
            <snapshots> <enabled>true</enabled> </snapshots>
        </pluginRepository>
    </pluginRepositories>

</project>




--
View this message in context: 
http://apache-flex-users.2333346.n4.nabble.com/Flexmojos-7-1-0-can-t-find-flex-default-namespaces-tp11276.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Reply via email to