[AC-2808] Android module compilation fails on ubuntu 11.10 with 1.8.0.1 and later (reason known)
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-02-21T12:08:11.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Titanium SDK & CLI |
Labels | n/a |
Reporter | Patric de Waha |
Assignee | Shak Hossain |
Created | 2011-12-26T05:21:15.000+0000 |
Updated | 2016-03-08T07:47:44.000+0000 |
Description
Compilation of custom module fails to due to KrollBindingGenerator
Exact problem is in: KrollBindingGenerator.java:248
It tries to get the path from the current class, which on my system results
in the path of ANT: /usr/share/ant
Then it tries to load the titanium.jar which of course cannot be found in that path.
I am not the only one with this probably (c.f. Q&A)
Dump of exception during compile
{noformat}
Buildfile: build.xml
init:
[mkdir] Created dir: /home/psec/Development/MobileApps/modules/zaponutils/build/classes
[mkdir] Created dir: /home/psec/Development/MobileApps/modules/zaponutils/dist
process.annotations:
[mkdir] Created dir: /home/psec/Development/MobileApps/modules/zaponutils/build/generated/json
[javac] Compiling 1 source file to /home/psec/Development/MobileApps/modules/zaponutils/build/classes
[javac] Note: [KrollBindingGen] Running Kroll binding generator.
[javac] Note: [KrollBindingGen] No binding data found, creating new data file: org.appcelerator.titanium.bindings/zaponutils.json
[javac] Note: [KrollBindingGen] Found binding for module Zaponutils
[javac] Note: [KrollBindingGen] Generating JSON: /home/psec/Development/MobileApps/modules/zaponutils/build/generated/json/org/appcelerator/titanium/bindings/zaponutils.json
[javac] warning: The following options were not recognized by any processor: '[kroll.checkTiContext]'
generate.rhino.bindings:
[java] java.util.zip.ZipException: error in opening zip file
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:194)
[java] at org.apache.tools.ant.taskdefs.Java.run(Java.java:764)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:218)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:132)
[java] at org.apache.tools.ant.taskdefs.Java.execute(Java.java:105)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:62)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:394)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.Target.execute(Target.java:357)
[java] at org.apache.tools.ant.Target.performTasks(Target.java:385)
[java] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
[java] at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
[java] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[java] at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
[java] at org.apache.tools.ant.Main.runBuild(Main.java:758)
[java] at org.apache.tools.ant.Main.startAnt(Main.java:217)
[java] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
[java] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
[java] Caused by: java.util.zip.ZipException: error in opening zip file
[java] at java.util.zip.ZipFile.open(Native Method)
[java] at java.util.zip.ZipFile.(ZipFile.java:127)
[java] at java.util.jar.JarFile.(JarFile.java:135)
[java] at java.util.jar.JarFile.(JarFile.java:99)
[java] at org.appcelerator.kroll.annotations.generator.KrollBindingGenerator.loadTitaniumBindings(KrollBindingGenerator.java:248)
[java] at org.appcelerator.kroll.annotations.generator.KrollBindingGenerator.main(KrollBindingGenerator.java:355)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:152)
[java] ... 34 more
[java] --- Nested Exception ---
[java] java.util.zip.ZipException: error in opening zip file
[java] at java.util.zip.ZipFile.open(Native Method)
[java] at java.util.zip.ZipFile.(ZipFile.java:127)
[java] at java.util.jar.JarFile.(JarFile.java:135)
[java] at java.util.jar.JarFile.(JarFile.java:99)
[java] at org.appcelerator.kroll.annotations.generator.KrollBindingGenerator.loadTitaniumBindings(KrollBindingGenerator.java:248)
[java] at org.appcelerator.kroll.annotations.generator.KrollBindingGenerator.main(KrollBindingGenerator.java:355)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:152)
[java] at org.apache.tools.ant.taskdefs.Java.run(Java.java:764)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:218)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:132)
[java] at org.apache.tools.ant.taskdefs.Java.execute(Java.java:105)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:62)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:394)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
[java] at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.Target.execute(Target.java:357)
[java] at org.apache.tools.ant.Target.performTasks(Target.java:385)
[java] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
[java] at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
[java] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[java] at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
[java] at org.apache.tools.ant.Main.runBuild(Main.java:758)
[java] at org.apache.tools.ant.Main.startAnt(Main.java:217)
[java] at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
[java] at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
[java] Java Result: -1
{noformat}
Hi Patric, Would you provide a bit more information so that we can help you solve the issues you are facing? Specifically, we need steps to reproduce what you are seeing. (I am able to successfully build modules, otherwise I would not be asking for these steps.) Are you able to see this issue with a newly created module? Or just with existing modules? Have you done an ant clean before attempting an ant? Regards, Dawson
I this exact same issue, but on osx 10.6.8. I can't compile the example module project even. http://developer.appcelerator.com/question/132207/cannot-build-custom-android-module-on-osx-with-181
Tested on 1.8.1, examples are compiling properly.
Working fine.