Closed mogue2k3 closed 11 months ago
I'm compiling against AIR SDK 26 and using Java SDK 1.8.0_112
Did you install Android Studio and the Android SDK?
Yes I did. Problem was solved compiling on MAC OSX machine, problem seemed to be on gradle installation on Windows.
The gradlew.bat file should be in the repository, can you check it's in your checkout? If it is the error could be related to permissions, perhaps just check that it has execute permissions on your system?
Same problem here on windows 7 (gradlew.bat not found) ... i check permissions and the file is in the folder..
i manage to build on windows with 2 modifications, i make a copy of gradlew.bat in the ANE-CustomResources root folder and change the ligne 99 in build.xml "replacestring from="@ANDROIDSDK@" to="C:\\Users\\username\\AppData\\Local\Android\\sdk"/"
I wouldn't suggest changing gradlew.bat
, this file is produced by the android build process, so there may be something else wrong if you are having to modify it. We are making the changes identified in #16, which we are hoping will resolve this issue for users.
I don' t made any change on gradlew.bat, i just change location of the file. On windows there is only files path problems...
Could you try the latest update, we've made some changes to the way gradle is called.
Thank you for posting this :
change the ligne 99 in build.xml "replacestring from="@AndroidSDK@" to="C:\Users\username\AppData\Local\Android\sdk"/"
It solved the issue for me on windows
@marchbold the issue when we don't do this replace is that the android sdk path gets added to the ant path with removed slashes :
[exec] FAILURE: Build failed with an exception.
[exec]
[exec] * What went wrong:
[exec] A problem occurred configuring project ':app'.
[exec] > The SDK directory 'D:\Documents\_Dev\anes\ANE-CustomResources-master\platform\android\C:UsersMatseAppDataLocalAndroidSdk' does not exist.
I'm experiencing problems running ant to compile on a Windows 10 machine.
I have all the necessary files configured and installed but when I run ant I always get the same error:
Buildfile: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\build.xml
clean:
clean_actionscript: [delete] Deleting directory F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\actionscript\bin
clean_default: [delete] Deleting directory F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\default\bin
clean_android: [delete] Deleting directory F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app
build:
build_actionscript: [echo] Building actionscript library... [compc] Loading configuration: F:\FLEXSDKS\AIRSDK 26.0\frameworks\air-config.xml [compc] [compc] [compc] 2172 bytes written to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\actionscript\bin\distriqt.extension.resources.swc in 1,031 seconds [compc] [echo] done
build_default: [echo] Building default library... [compc] Loading configuration: F:\FLEXSDKS\AIRSDK 26.0\frameworks\air-config.xml [compc] [compc] [compc] 2016 bytes written to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\default\bin\distriqt.extension.resources.default.swc in 0,732 seconds [compc] [echo] done
create_android_project: [mkdir] Created dir: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app [copy] Copying 4 files to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app [mkdir] Created dir: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app\src\main\java\com\distriqt\extension\customresources [copy] Copying 2 files to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app\src\main\java\com\distriqt\extension\customresources [mkdir] Created dir: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app\src\main\res [copy] Copying 1 file to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android [copy] Copying 1 file to F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android\app\libs
build_android: [echo] Building Android library...
build_android_osx:
build_android_windows:
BUILD FAILED F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\build.xml:215: The following error occurred while executing this line: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\build.xml:146: The following error occurred while executing this line: F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\build.xml:163: Execute failed: java.io.IOException: Cannot run program "gradlew.bat" (in directory "F:\PROYECTOS\DoNetworking\ane\CustomResources\trunk\platform\android"): CreateProcess error=2, System cannot find the request file at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048) at java.lang.Runtime.exec(Runtime.java:620) at org.apache.tools.ant.taskdefs.launcher.Java13CommandLauncher.exec(Java13CommandLauncher.java:58) at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:426) at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:440) at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:629) at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:670) at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:496) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:293) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:435) at org.apache.tools.ant.Target.performTasks(Target.java:456) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1405) at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38) at org.apache.tools.ant.Project.executeTargets(Project.java:1260) at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:441) at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:105) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:293) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:435) at org.apache.tools.ant.Target.performTasks(Target.java:456) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1405) at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38) at org.apache.tools.ant.Project.executeTargets(Project.java:1260) at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:441) at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:105) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:293) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:435) at org.apache.tools.ant.Target.performTasks(Target.java:456) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1405) at org.apache.tools.ant.Project.executeTarget(Project.java:1376) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41) at org.apache.tools.ant.Project.executeTargets(Project.java:1260) at org.apache.tools.ant.Main.runBuild(Main.java:857) at org.apache.tools.ant.Main.startAnt(Main.java:236) at org.apache.tools.ant.launch.Launcher.run(Launcher.java:287) at org.apache.tools.ant.launch.Launcher.main(Launcher.java:113) Caused by: java.io.IOException: CreateProcess error=2, System cannot find the request file at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.(ProcessImpl.java:386)
at java.lang.ProcessImpl.start(ProcessImpl.java:137)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
... 49 more
I think that is something related to gradle build but not sure.