java - Converting JavaFX to Android using gradlew -
i new javafx, , trying convert android apk using javafxmobile plugin.
while converting android using gradlew, getting error execution failed task ':dex'
.
system has jdk 1.8u40 installed , gradle configured it.
tried using dalvik sdk, still not converting.
here complete error:
c:\users\vss\documents\netbeansprojects\andytest>gradlew android :compilejava up-to-date :compileretrolambdamain up-to-date :processresources up-to-date :classes up-to-date :compileandroidjava up-to-date :compileretrolambdaandroid skipped :compiletestjava up-to-date :compileretrolambdatest skipped :compileretrolambda up-to-date :mergeclassesintojar :validatemanifest :collectmultidexcomponents :shrinkmultidexcomponents :createmaindexlist :dex [ant:java] java result: 1 :dex failed failure: build failed exception.
what went wrong:
execution failed task ':dex'.
org.gradle.api.gradleexception (no error message)
tried:
run --stacktrace option stack trace.
run --info or --debug option more log out put.build failed
total time: 1 mins 9.768 secs
when ran --stacktrace, got following error details:
c:\users\vss\documents\netbeansprojects\andytest>gradlew -stacktrace android :compilejava up-to-date :compileretrolambdamain up-to-date :processresources up-to-date :classes up-to-date :compileandroidjava up-to-date :compileretrolambdaandroid skipped :compiletestjava up-to-date :compileretrolambdatest skipped :compileretrolambda up-to-date :mergeclassesintojar :validatemanifest :collectmultidexcomponents :shrinkmultidexcomponents :createmaindexlist :dex [ant:java] java result: 1 :dex failed failure: build failed exception.
what went wrong:
execution failed task ':dex'.
org.gradle.api.gradleexception (no error message)
tried: run --info or --debug option more log output.
my exception is:
org.gradle.api.tasks.taskexecutionexception: execution failed task ':dex'. @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeactions(executeaction staskexecuter.java:69) @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.execute(executeactionstaskex ecuter.java:46) @ org.gradle.api.internal.tasks.execution.postexecutionanalysistaskexecuter.execute(postexecution analysistaskexecuter.java:35) @ org.gradle.api.internal.tasks.execution.skipuptodatetaskexecuter.execute(skipuptodatetaskexecut er.java:64) @ org.gradle.api.internal.tasks.execution.validatingtaskexecuter.execute(validatingtaskexecuter.j ava:58) @ org.gradle.api.internal.tasks.execution.skipemptysourcefilestaskexecuter.execute(skipemptysourc efilestaskexecuter.java:42) @ org.gradle.api.internal.tasks.execution.skiptaskwithnoactionsexecuter.execute(skiptaskwithnoact ionsexecuter.java:52) @ org.gradle.api.internal.tasks.execution.skiponlyiftaskexecuter.execute(skiponlyiftaskexecuter.j ava:53) @ org.gradle.api.internal.tasks.execution.executeatmostoncetaskexecuter.execute(executeatmostonce taskexecuter.java:43) @ org.gradle.api.internal.abstracttask.executewithoutthrowingtaskfailure(abstracttask.java:306) @ org.gradle.execution.taskgraph.abstracttaskplanexecutor$taskexecutorworker.executetask(abstract taskplanexecutor.java:79) @ org.gradle.execution.taskgraph.abstracttaskplanexecutor$taskexecutorworker.processtask(abstract taskplanexecutor.java:63) @ org.gradle.execution.taskgraph.abstracttaskplanexecutor$taskexecutorworker.run(abstracttaskplan executor.java:51) @ org.gradle.execution.taskgraph.defaulttaskplanexecutor.process(defaulttaskplanexecutor.java:23)
@ org.gradle.execution.taskgraph.defaulttaskgraphexecuter.execute(defaulttaskgraphexecuter.java:8
8) @ org.gradle.execution.selectedtaskexecutionaction.execute(selectedtaskexecutionaction.java:29) @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:62) @ org.gradle.execution.defaultbuildexecuter.access$200(defaultbuildexecuter.java:23) @ org.gradle.execution.defaultbuildexecuter$2.proceed(defaultbuildexecuter.java:68) @ org.gradle.execution.dryrunbuildexecutionaction.execute(dryrunbuildexecutionaction.java:32) @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:62) @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:55) @ org.gradle.initialization.defaultgradlelauncher.dobuildstages(defaultgradlelauncher.java:149) @ org.gradle.initialization.defaultgradlelauncher.dobuild(defaultgradlelauncher.java:106) @ org.gradle.initialization.defaultgradlelauncher.run(defaultgradlelauncher.java:86) @ org.gradle.launcher.exec.inprocessbuildactionexecuter$defaultbuildcontroller.run(inprocessbuild actionexecuter.java:80) @ org.gradle.launcher.cli.executebuildaction.run(executebuildaction.java:33) @ org.gradle.launcher.cli.executebuildaction.run(executebuildaction.java:24) @ org.gradle.launcher.exec.inprocessbuildactionexecuter.execute(inprocessbuildactionexecuter.java :36) @ org.gradle.launcher.exec.inprocessbuildactionexecuter.execute(inprocessbuildactionexecuter.java :26) @ org.gradle.launcher.cli.runbuildaction.run(runbuildaction.java:51) @ org.gradle.internal.actions$runnableactionadapter.execute(actions.java:169) @ org.gradle.launcher.cli.commandlineactionfactory$parseandbuildaction.execute(commandlineactionf actory.java:237) @ org.gradle.launcher.cli.commandlineactionfactory$parseandbuildaction.execute(commandlineactionf actory.java:210) @ org.gradle.launcher.cli.javaruntimevalidationaction.execute(javaruntimevalidationaction.java:35 ) @ org.gradle.launcher.cli.javaruntimevalidationaction.execute(javaruntimevalidationaction.java:24 ) @ org.gradle.launcher.cli.commandlineactionfactory$withlogging.execute(commandlineactionfactory.j ava:206) @ org.gradle.launcher.cli.commandlineactionfactory$withlogging.execute(commandlineactionfactory.j ava:169) @ org.gradle.launcher.cli.exceptionreportingaction.execute(exceptionreportingaction.java:33) @ org.gradle.launcher.cli.exceptionreportingaction.execute(exceptionreportingaction.java:22) @ org.gradle.launcher.main.doaction(main.java:33) @ org.gradle.launcher.bootstrap.entrypoint.run(entrypoint.java:45) @ org.gradle.launcher.bootstrap.processbootstrap.runnoexit(processbootstrap.java:54) @ org.gradle.launcher.bootstrap.processbootstrap.run(processbootstrap.java:35) @ org.gradle.launcher.gradlemain.main(gradlemain.java:23) @ org.gradle.wrapper.bootstrapmainstarter.start(bootstrapmainstarter.java:30) @ org.gradle.wrapper.wrapperexecutor.execute(wrapperexecutor.java:127) @ org.gradle.wrapper.gradlewrappermain.main(gradlewrappermain.java:61) caused by: org.gradle.api.gradleexception: @ org.javafxports.jfxmobile.plugin.android.task.dex.dex(dex.groovy:57) @ org.gradle.internal.reflect.javamethod.invoke(javamethod.java:63) @ org.gradle.api.internal.project.taskfactory.annotationprocessingtaskfactory$standardtaskaction. doexecute(annotationprocessingtaskfactory.java:218) @ org.gradle.api.internal.project.taskfactory.annotationprocessingtaskfactory$standardtaskaction. execute(annotationprocessingtaskfactory.java:211) @ org.gradle.api.internal.project.taskfactory.annotationprocessingtaskfactory$standardtaskaction. execute(annotationprocessingtaskfactory.java:200) @ org.gradle.api.internal.abstracttask$taskactionwrapper.execute(abstracttask.java:585) @ org.gradle.api.internal.abstracttask$taskactionwrapper.execute(abstracttask.java:568) @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeaction(executeactions taskexecuter.java:80) @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeactions(executeaction staskexecuter.java:61) ... 47 more
build failed
total time: 1 mins 33.13 secs
my build.gradle file follows:
task wrapper(type: wrapper) { gradleversion = '2.3' } buildscript { repositories { jcenter() } dependencies { classpath 'org.javafxports:jfxmobile-plugin:1.0.0-b9' classpath 'org.codehaus.groovy:groovy-backports-compat23:2.3.5' } } apply plugin: 'org.javafxports.jfxmobile' mainclassname = 'andytest.andytest' version = '8u40' repositories { jcenter() } jfxmobile { android { applicationpackage = 'andytest.andyhere' } }
i had same problem, missing directory android studio:
..\android\sdk\extras\android\support\multidex
here example have made self: https://github.com/viktorcitaku/javafxandroid
Comments
Post a Comment