Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-10736] Android: Modules: Module packaging fails on Linux

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionInvalid
Resolution Date2014-06-16T16:48:29.000+0000
Affected Version/sRelease 2.1.1, Release 2.1.2
Fix Version/sn/a
ComponentsAndroid
Labelscore, qe-and082012
ReporterDustin Hyde
AssigneeIngo Muschenetz
Created2012-08-31T15:13:11.000+0000
Updated2017-03-20T21:29:59.000+0000

Description

When packaging android modules on Linux, there is a build error. Console:
BUILD FAILED
/home/tester/.titanium/mobilesdk/linux/2.1.2.GA/module/android/build.xml:265: Compile failed; see the compiler error output for details.
This is not a regression. This worked on Ubuntu 10.04 using ant 1.8, but reinstalling 1.8 caused the same problem. Steps to Reproduce: 1. Create an Android Module. 2. Package Android Module using ant, either from Studio or command line. Actual Result: Error. Expected Result: Android Module Packages.

Attachments

FileDateSize
console.txt2012-08-31T15:13:11.000+000017605

Comments

  1. Dustin Hyde 2012-08-31

    This is not occurring using Titanium Studio on Ubuntu 10.04, but it is occurring using Titanium Studio on Ubuntu 12.04.
  2. Dustin Hyde 2012-08-31

    Reinstalling Studio fixed the issue in Titanium Studio Android Module Packaging on Ubuntu 12.04. There is yet to be a solution for command line ant builds on android modules.
  3. Dustin Hyde 2012-10-13

    This appears to be an issue with needing to restart the os in order for ant to be properly recognized.
  4. Paras Mishra 2013-11-20

    I am able to reproduce the issue. Using the environment: Appcelerator Studio, build: 3.2.0.201311161724 SDK: 3.2.0.v20131119142443 alloy: 1.3.0 acs: 1.0.7 npm: 1.3.2 titanium: 3.2.0-alpha titanium-code-processor: 1.1.0-alpha OS: Ubuntu 12.04 (64-bit) LTS Hers's the log
       home/global/.titanium/mobilesdk/linux/3.2.0.v20131119142443/module/android/build.xml:281: exec returned: 2
       	at org.apache.tools.ant.ProjectHelper.addLocationToBuildException(ProjectHelper.java:551)
       	at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:401)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:616)
       	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:392)
       	at org.apache.tools.ant.Target.performTasks(Target.java:413)
       	at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
       	at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
       	at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
       	at org.eclipse.ant.internal.core.ant.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
       	at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
       	at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:672)
       	at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:498)
       	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:616)
       	at org.eclipse.ant.core.AntRunner.run(AntRunner.java:378)
       	at com.appcelerator.titanium.android.internal.ui.launching.AndroidModulePackageLaunchConfigurationDelegate$PackagingProcess$1.run(AndroidModulePackageLaunchConfigurationDelegate.java:231)
       	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
       Caused by: /home/global/.titanium/mobilesdk/linux/3.2.0.v20131119142443/module/android/build.xml:281: exec returned: 2
       	at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:646)
       	at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:672)
       	at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:498)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:616)
       	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.taskdefs.Sequential.execute(Sequential.java:68)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:616)
       	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.taskdefs.MacroInstance.execute(MacroInstance.java:398)
       	... 22 more
       
       
  5. Paras Mishra 2013-12-19

    Module packing is working fine now Tested on: Appcelerator Studio, build: 3.2.0.201312181652 SDK: 3.2.0.v20131210191510 alloy: 1.3.0-cr2 acs: 1.0.10 npm: 1.3.2 titanium: 3.2.0-cr3 titanium-code-processor: 1.1.0-cr2 OS: Ubuntu 12.04 (64-bit) LTS
  6. Paras Mishra 2014-06-12

    Issue is reproducible Environment used: Tested on: SDK: 3.3.0.v20140611130912 CLI version : 3.3.0-rc OS : Ubuntu(12.04), 32-bit Alloy: 1.4.0-beta2 ACS: 1.0.14 npm:1.3.2 LiveView: 1.0.4 Titanium Studio, build: 3.3.0.201406101332 titanium-code-processor: 1.1.1 Logs are as follows
       MESSAGE /home/global/.titanium/mobilesdk/linux/3.3.0.v20140611130912/module/android/build.xml:326: The following error occurred while executing this line:
       /home/global/.titanium/mobilesdk/linux/3.3.0.v20140611130912/module/android/build.xml:281: exec returned: 2
       !STACK 0
       /home/global/.titanium/mobilesdk/linux/3.3.0.v20140611130912/module/android/build.xml:326: The following error occurred while executing this line:
       /home/global/.titanium/mobilesdk/linux/3.3.0.v20140611130912/module/android/build.xml:281: exec returned: 2
       	at org.apache.tools.ant.ProjectHelper.addLocationToBuildException(ProjectHelper.java:551)
       	at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:401)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:606)
       	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:392)
       	at org.apache.tools.ant.Target.performTasks(Target.java:413)
       	at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
       	at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
       	at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
       	at org.eclipse.ant.internal.core.ant.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
       	at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
       	at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:672)
       	at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:498)
       	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:606)
       	at org.eclipse.ant.core.AntRunner.run(AntRunner.java:378)
       	at com.appcelerator.titanium.android.internal.ui.launching.AndroidModulePackageLaunchConfigurationDelegate$PackagingProcess$1.run(AndroidModulePackageLaunchConfigurationDelegate.java:279)
       	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
       Caused by: /home/global/.titanium/mobilesdk/linux/3.3.0.v20140611130912/module/android/build.xml:281: exec returned: 2
       	at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:646)
       	at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:672)
       	at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:498)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:606)
       	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.taskdefs.Sequential.execute(Sequential.java:68)
       	at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
       	at sun.reflect.GeneratedMethodAccessor45.invoke(Unknown Source)
       	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       	at java.lang.reflect.Method.invoke(Method.java:606)
       	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.taskdefs.MacroInstance.execute(MacroInstance.java:398)
       	... 22 more
       
       
  7. Samuel Dowse 2014-06-13

    Tested on: Ubuntu 14.04 Appcelerator Studio, build: 3.3.0.201406111952 Titanium Studio, build: 3.3.0.201406111946 Titanium SDK, build: 3.3.0.v20140612101712 Titanium CLI, build: 3.3.0-rc Alloy: 1.4.0-rc Android NDK: r9d The issue [~pmishra] is hitting is due to missing dependancies. To fix this issue, download the following: Apache Ant: [Version 1.9.4](http://apache.claz.org//ant/binaries/apache-ant-1.9.4-bin.zip) Python: [Version 2.7.7](https://www.python.org/ftp/python/2.7.7/Python-2.7.7.tgz) sudo apt-get install gperf -y Once downloaded, set each of them in your environment variables. To set the environment variables, do the following: Run 'sudo pico ~/.bashrc' in your terminal Add these lines to the end of the file:
       export PATH="<path/to/ant/bin/folder>":$PATH
       export PATH="<path/to/python/root/folder>":$PATH
       
    Once all of these were set up I was able to successfully package the module from Studio and the CLI.
  8. Ingo Muschenetz 2014-06-16

    Based on comments, I believe this is invalid. Please let me know if you believe otherwise.
  9. Lee Morris 2017-03-20

    Closing ticket as invalid.

JSON Source