Dexguard with Maven and Android Studio doesn't work -
i taking on project, android app, developed on eclipse adt plugin. uses maven3, , dexguard obfuscate code.
as work android studio (as) imported old project in as. works fine except dexguard.
whenever want run project error saying : no implementation org.eclipse.aether.impl.versionresolver bound.
here full error message:
[error] failed execute goal com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources (default-generate-sources) on project app-android-genmsecure: execution default-generate-sources of goal com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources failed: unable load mojo 'generate-sources' (or 1 of required components) plugin 'com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32': com.google.inject.provisionexception: guice provision errors: [error] [error] 1) no implementation org.eclipse.aether.impl.versionresolver bound. [error] while locating org.eclipse.aether.internal.impl.defaultrepositorysystem [error] @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] [error] @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] [error] while locating org.eclipse.aether.repositorysystem [error] while locating com.jayway.maven.plugins.android.phase01generatesources.generatesourcesmojo [error] @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] [error] while locating org.apache.maven.plugin.mojo annotated @com.google.inject.name.named(value=com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources) [error] [error] 1 error [error] role: org.apache.maven.plugin.mojo [error] rolehint: com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources [error] -> [help 1] org.apache.maven.lifecycle.lifecycleexecutionexception: failed execute goal com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources (default-generate-sources) on project app-android-genmsecure: execution default-generate-sources of goal com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources failed: unable load mojo 'generate-sources' (or 1 of required components) plugin 'com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32' @ org.apache.maven.lifecycle.internal.mojoexecutor.execute(mojoexecutor.java:225) @ org.apache.maven.lifecycle.internal.mojoexecutor.execute(mojoexecutor.java:153) @ org.apache.maven.lifecycle.internal.mojoexecutor.execute(mojoexecutor.java:145) @ org.apache.maven.lifecycle.internal.lifecyclemodulebuilder.buildproject(lifecyclemodulebuilder.java:84) @ org.apache.maven.lifecycle.internal.lifecyclemodulebuilder.buildproject(lifecyclemodulebuilder.java:59) @ org.apache.maven.lifecycle.internal.lifecyclestarter.singlethreadedbuild(lifecyclestarter.java:183) @ org.apache.maven.lifecycle.internal.lifecyclestarter.execute(lifecyclestarter.java:161) @ org.apache.maven.defaultmaven.doexecute(defaultmaven.java:320) @ org.apache.maven.defaultmaven.execute(defaultmaven.java:156) @ org.apache.maven.cli.mavencli.execute(mavencli.java:537) @ org.apache.maven.cli.mavencli.domain(mavencli.java:196) @ org.apache.maven.cli.mavencli.main(mavencli.java:141) @ sun.reflect.nativemethodaccessorimpl.invoke0(native method) @ sun.reflect.nativemethodaccessorimpl.invoke(nativemethodaccessorimpl.java:57) @ sun.reflect.delegatingmethodaccessorimpl.invoke(delegatingmethodaccessorimpl.java:43) @ java.lang.reflect.method.invoke(method.java:606) @ org.codehaus.plexus.classworlds.launcher.launcher.launchenhanced(launcher.java:290) @ org.codehaus.plexus.classworlds.launcher.launcher.launch(launcher.java:230) @ org.codehaus.plexus.classworlds.launcher.launcher.mainwithexitcode(launcher.java:409) @ org.codehaus.plexus.classworlds.launcher.launcher.main(launcher.java:352) @ org.codehaus.classworlds.launcher.main(launcher.java:47) caused by: org.apache.maven.plugin.pluginexecutionexception: execution default-generate-sources of goal com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources failed: unable load mojo 'generate-sources' (or 1 of required components) plugin 'com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32' @ org.apache.maven.plugin.defaultbuildpluginmanager.executemojo(defaultbuildpluginmanager.java:115) @ org.apache.maven.lifecycle.internal.mojoexecutor.execute(mojoexecutor.java:209) ... 20 more caused by: org.apache.maven.plugin.plugincontainerexception: unable load mojo 'generate-sources' (or 1 of required components) plugin 'com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32' @ org.apache.maven.plugin.internal.defaultmavenpluginmanager.getconfiguredmojo(defaultmavenpluginmanager.java:488) @ org.apache.maven.plugin.defaultbuildpluginmanager.executemojo(defaultbuildpluginmanager.java:92) ... 21 more caused by: org.codehaus.plexus.component.repository.exception.componentlookupexception: com.google.inject.provisionexception: guice provision errors: 1) no implementation org.eclipse.aether.impl.versionresolver bound. while locating org.eclipse.aether.internal.impl.defaultrepositorysystem @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] while locating org.eclipse.aether.repositorysystem while locating com.jayway.maven.plugins.android.phase01generatesources.generatesourcesmojo @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] while locating org.apache.maven.plugin.mojo annotated @com.google.inject.name.named(value=com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources) 1 error role: org.apache.maven.plugin.mojo rolehint: com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources @ org.codehaus.plexus.defaultplexuscontainer.lookup(defaultplexuscontainer.java:257) @ org.codehaus.plexus.defaultplexuscontainer.lookup(defaultplexuscontainer.java:245) @ org.apache.maven.plugin.internal.defaultmavenpluginmanager.getconfiguredmojo(defaultmavenpluginmanager.java:455) ... 22 more caused by: com.google.inject.provisionexception: guice provision errors: 1) no implementation org.eclipse.aether.impl.versionresolver bound. while locating org.eclipse.aether.internal.impl.defaultrepositorysystem @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] while locating org.eclipse.aether.repositorysystem while locating com.jayway.maven.plugins.android.phase01generatesources.generatesourcesmojo @ classrealm[plugin>com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32, parent: sun.misc.launcher$appclassloader@1efde7ba] while locating org.apache.maven.plugin.mojo annotated @com.google.inject.name.named(value=com.saikoa.dexguard.maven:dexguard-maven-plugin:5.5.32:generate-sources) 1 error @ com.google.inject.internal.injectorimpl$3.get(injectorimpl.java:974) @ com.google.inject.scopes$1$1.get(scopes.java:59) @ org.sonatype.guice.bean.locators.lazybeanentry.getvalue(lazybeanentry.java:83) @ org.sonatype.guice.plexus.locators.lazyplexusbean.getvalue(lazyplexusbean.java:49) @ org.codehaus.plexus.defaultplexuscontainer.lookup(defaultplexuscontainer.java:253) ... 24 more [error]
and pom.xml file :
<?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>[hidden]</groupid> <artifactid>[hidden]</artifactid> <version>1.9.0-snapshot</version> <packaging>apk</packaging> <name>[hidden]</name> <!-- scm tag maven releases --> <scm> <connection>[hidden]</connection> <tag>head</tag> </scm> <properties> <project.build.sourceencoding>utf-8</project.build.sourceencoding> <!-- android --> <android.sdk.path>${env.android_home}</android.sdk.path> <android.sdk.platform>17</android.sdk.platform> </properties> <distributionmanagement> <!-- maven repository deploy artifact : nexus --> <repository> <id>releases</id> <name>internal releases</name> <url>[hidden]</url> </repository> <snapshotrepository> <id>snapshots</id> <name>internal snapshots</name> <url>[hidden]</url> </snapshotrepository> </distributionmanagement> <dependencies> <!-- android dependencies --> <dependency> <groupid>com.google.android</groupid> <artifactid>android</artifactid> <version>4.1.1.4</version> <scope>provided</scope> </dependency> <!-- external dependencies --> <dependency> <groupid>com.google.code.gson</groupid> <artifactid>gson</artifactid> <version>2.2.2</version> </dependency> <dependency> <groupid>commons-codec</groupid> <artifactid>commons-codec</artifactid> <version>1.5</version> </dependency> </dependencies> <build> <pluginmanagement> <plugins> <plugin> <groupid>com.saikoa.dexguard.maven</groupid> <artifactid>dexguard-maven-plugin</artifactid> <version>5.5.32</version> <extensions>true</extensions> </plugin> <!-- <plugin> --> <!-- <groupid>com.jayway.maven.plugins.android.generation2</groupid> --> <!-- <artifactid>android-maven-plugin</artifactid> --> <!-- <version>3.8.0</version> --> <!-- </plugin> --> </plugins> </pluginmanagement> <finalname>${project.artifactid}</finalname> <plugins> <plugin> <groupid>com.saikoa.dexguard.maven</groupid> <artifactid>dexguard-maven-plugin</artifactid> <extensions>true</extensions> <configuration> <dexguardconfig>dexguard-project-debug.txt</dexguardconfig> <release>false</release> </configuration> </plugin> <plugin> <artifactid>maven-compiler-plugin</artifactid> <version>2.3.2</version> <configuration> <source>1.7</source> <target>1.7</target> </configuration> </plugin> <plugin> <groupid>org.apache.maven.plugins</groupid> <artifactid>maven-resources-plugin</artifactid> <version>2.4.3</version> <configuration> <encoding>${project.build.sourceencoding}</encoding> </configuration> </plugin> <plugin> <groupid>org.codehaus.mojo</groupid> <artifactid>build-helper-maven-plugin</artifactid> <version>1.7</version> <executions> <execution> <id>add-source</id> <phase>generate-sources</phase> <goals> <goal>add-source</goal> </goals> <configuration> <sources> <source>src/main/java</source> <source>src/main/native</source> </sources> </configuration> </execution> </executions> </plugin> <plugin> <artifactid>maven-release-plugin</artifactid> <version>2.5</version> <configuration> <!-- during release:perform, enable "release" profile --> <releaseprofiles>release</releaseprofiles> </configuration> </plugin> <plugin> <groupid>org.apache.maven.plugins</groupid> <artifactid>maven-javadoc-plugin</artifactid> <version>2.10.3</version> <configuration> <failonerror>false</failonerror> </configuration> </plugin> </plugins> </build> <profiles> <profile> <!-- profile release : activated during release. obfuscate , process code --> <id>release</id> <build> <plugins> <plugin> <groupid>com.saikoa.dexguard.maven</groupid> <artifactid>dexguard-maven-plugin</artifactid> <extensions>true</extensions> <configuration> <release>true</release> <dexguardconfig>dexguard-project-release.txt</dexguardconfig> </configuration> </plugin> </plugins> </build> </profile> <profile> <!-- customer profile, rename package name. --> <id>ncr</id> <build> <plugins> <plugin> <groupid>com.saikoa.dexguard.maven</groupid> <artifactid>dexguard-maven-plugin</artifactid> <configuration> <renamemanifestpackage>[hidden]</renamemanifestpackage> </configuration> </plugin> </plugins> </build> </profile> <profile> <!-- customer profile, rename package name. --> <id>[hidden]</id> <build> <plugins> <plugin> <groupid>com.saikoa.dexguard.maven</groupid> <artifactid>dexguard-maven-plugin</artifactid> <configuration> <renamemanifestpackage>[hidden]</renamemanifestpackage> </configuration> </plugin> </plugins> </build> </profile> </profiles> </project>
tell me if need else.
thanks help.
aether eclipse library working maven repositories within eclipse. suppose makes sense system not available in android studio. don't have solution immediate problem. suppose may possible write intellij plugin exposes aether, really, that's way unreasonable :).
converting maven project gradle should straight forward, since directory structure there , gradle can handle custom maven repositories.
dexguard has gradle support, we're using @ place of work , it's painless. advice upgrade build system maven gradle , never back.
Comments
Post a Comment