すべてのモジュールのリストとパッケージ pom のタイプを含む pom.xml である A として呼び出すメイン ルート プロジェクトがあります。
<?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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.example</groupId>
<artifactId>A</artifactId>
<version>0.0.1</version>
<packaging>pom</packaging>
<properties>
<android.version>4.1.1.4</android.version>
<android.target.version>17</android.target.version>
<android.plugin.version>3.6.0</android.plugin.version>
<android.roboelectric.version>2.2</android.roboelectric.version>
<android.support.version.4>r7</android.support.version.4>
</properties>
<modules>
<module>AA</module>
<module>AB</module>
</modules>
このプロジェクトには 2 つの子があり、プロジェクト AA と AB にも poms があります。
プロジェクト AA はタイプ apklib をパッケージ化しており、android-maven-plugin (android:apklib) を介したコンパイル インストールでも nop の問題があります。ここに pom があります。
<?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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.example</groupId>
<artifactId>A</artifactId>
<version>0.0.1</version>
</parent>
<groupId>com.example</groupId>
<artifactId>AB</artifactId>
<packaging>apklib</packaging>
<build>
<finalName>${project.artifactId}-${project.parent.version}</finalName>
<pluginManagement>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<version>${android.plugin.version}</version>
<extensions>true</extensions>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<configuration>
<sdk>
<platform>17</platform>
<path>${env.ANDROID_HOME}</path>
</sdk>
</configuration>
</plugin>
</plugins>
</build>
プロジェクト AB は、以下のように pom でプロジェクト AA に依存しています
<?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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.example</groupId>
<artifactId>A</artifactId>
<version>0.0.1</version>
</parent>
<groupId>com.example</groupId>
<artifactId>AB</artifactId>
<packaging>apklib</packaging>
<dependencies>
<dependency>
<groupId>com.examplet</groupId>
<artifactId>AA</artifactId>
<version>0.0.1</version>
<type>apklib</type>
</dependency>
</dependencies>
<build>
<finalName>${project.artifactId}-${project.version}</finalName>
<pluginManagement>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<version>${android.plugin.version}</version>
<extensions>true</extensions>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<configuration>
<sdk>
<platform>17</platform>
</sdk>
</configuration>
</plugin>
</plugins>
</build>
パッケージング中または android:apklib でさえ、次のようなエラーが表示されます
プロジェクト util で目標を実行できませんでした: プロジェクト com.example.AB:apklib:0.0.1 の依存関係を解決できませんでした: [com.example.AA:apklib:0.0.1 (提供)] の依存関係を収集できませんでした: 失敗しましたcom.example.AA:apklib:0.0.1 のアーティファクト記述子を読み取る: 中央にアーティファクト com.example:A:pom:0.0.1 が見つかりませんでした ( http://repo.maven.apache.org/maven2 ) -> 【ヘルプ1】
プロジェクト AA で mvn install を実行しましたが、.m2 にインストールされているように見えます
何か案は?前もって感謝します。