有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

带有安卓 maven插件的核心库

我想在安卓上使用nativ库。当我试图用

mvn clean install 

我犯了个错误

[INFO] If you really intend to build a core library -- which is only
[INFO] appropriate as part of creating a full virtual machine
[INFO] distribution, as opposed to compiling an application -- then use
[INFO] the "--core-library" option to suppress this error message.

如何向pom添加核心库参数。xml

我的pom看起来像

http://maven.apache.org/maven-v4_0_0.xsd“>; 4.0.0

<parent>
    <groupId>com.temp</groupId>
    <artifactId>SipAndroidClient</artifactId>
    <version>0.1</version>
</parent>

<artifactId>安卓-di</artifactId>
<packaging>apk</packaging>
<name>安卓-di - Application</name>

<dependencies>
    <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.hamcrest</groupId>
        <artifactId>hamcrest-all</artifactId>
        <version>1.3</version>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-all</artifactId>
        <version>1.9.5</version>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>com.pivotallabs</groupId>
        <artifactId>robolectric</artifactId>
        <version>1.1</version>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>com.google.安卓</groupId>
        <artifactId>安卓</artifactId>
    </dependency>
    <dependency>
        <groupId>org.roboguice</groupId>
        <artifactId>roboguice</artifactId>
        <version>2.0</version>
    </dependency>
    <dependency>
        <groupId>de.mindpipe.安卓</groupId>
        <artifactId>安卓-logging-log4j</artifactId>
        <version>1.0.3</version>
    </dependency>
    <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.17</version>
    </dependency>
    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>1.7.2</version>
    </dependency>
    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-log4j12</artifactId>
        <version>1.7.2</version>
    </dependency>
    <dependency>
        <groupId>javax.sip</groupId>
        <artifactId>jain-sip-api</artifactId>
        <version>1.2.1.4</version>
    </dependency>
    <dependency>
        <groupId>javax.sip</groupId>
        <artifactId>jain-sip-ri</artifactId>
        <version>1.2.167</version>
    </dependency>
</dependencies>
<build>
    <plugins>
        <plugin>
            <groupId>com.jayway.maven.plugins.安卓.generation2</groupId>
            <artifactId>安卓-maven-plugin</artifactId>
            <configuration>
                <安卓ManifestFile>${project.basedir}/AndroidManifest.xml</安卓ManifestFile>
                <assetsDirectory>${project.basedir}/assets</assetsDirectory>
                <resourceDirectory>${project.basedir}/res</resourceDirectory>
                <nativeLibrariesDirectory>${project.basedir}/src/main/native</nativeLibrariesDirectory>
                <sdk>
                    <platform>10</platform>
                    <path>/home/damian/.安卓-sdk</path>
                </sdk>
                <undeployBeforeDeploy>true</undeployBeforeDeploy>
            </configuration>
            <extensions>true</extensions>
        </plugin>
        <plugin>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.0</version>
            <configuration>
                <source>1.6</source>
                <target>1.6</target>
            </configuration>
        </plugin>
    </plugins>
</build>


共 (1) 个答案