patricmutwiri / symja

Automatically exported from code.google.com/p/symja
0 stars 0 forks source link

Java heap space error when deploying android symja #45

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.When I build the android symja version, it's successful. But when running it 
into android device, it has an error: Java heap space. I don't know why it is. 
Do you have the same problem?

Original issue reported on code.google.com by huynhlam...@gmail.com on 30 Oct 2012 at 1:49

GoogleCodeExporter commented 9 years ago
Try the SymjaWebDroid first:
http://code.google.com/p/symja/source/browse/#svn%2Fandroid%2Ftrunk%2FSymjaWebDr
oid

It doesn't need less ressoureces but an internet connection to do the 
calculation on the server.

If you use device in connection with Eclipse, is there a stack trace you can 
send?

Original comment by axelclk@gmail.com on 30 Oct 2012 at 7:57

GoogleCodeExporter commented 9 years ago
When I run the build version from eclipse into devices, I get:

[2012-11-01 14:00:37 - MathEclipse] Dx 
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already added: 
Lorg/matheclipse/android/util/CommonAndroidCodeLibrary;
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.dex.file.DexFile.add(DexFile.java:163)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processClass(Main.java:486)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processFileBytes(Main.java:455)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.access$400(Main.java:67)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:394)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:135)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processOne(Main.java:418)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.run(Main.java:206)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
a:25)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
java.lang.reflect.Method.invoke(Method.java:597)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:180)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.jav
a:702)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(Po
stCompilerBuilder.java:646)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:629)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:172)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:282)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:363)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project$1.run(Project.java:545)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1975)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project.internalBuild(Project.java:524)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project.build(Project.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebu
gBuild(ProjectHelper.java:1000)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchCo
nfigDelegate.java:147)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.j
ava:853)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.j
ava:702)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:92
4)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1128)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
[2012-11-01 14:00:37 - MathEclipse] Dx 
UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already added: 
Lorg/matheclipse/android/util/Logger;
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.dex.file.DexFile.add(DexFile.java:163)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processClass(Main.java:486)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processFileBytes(Main.java:455)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.access$400(Main.java:67)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:394)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:135)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:1
91)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processOne(Main.java:418)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.dx.command.dexer.Main.run(Main.java:206)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
a:25)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
java.lang.reflect.Method.invoke(Method.java:597)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:180)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.jav
a:702)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(Po
stCompilerBuilder.java:646)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:629)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:172)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:282)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:363)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project$1.run(Project.java:545)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1975)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project.internalBuild(Project.java:524)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.resources.Project.build(Project.java:123)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebu
gBuild(ProjectHelper.java:1000)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchCo
nfigDelegate.java:147)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.j
ava:853)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.j
ava:702)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:92
4)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1128)
[2012-11-01 14:00:37 - MathEclipse] Dx  at 
org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
[2012-11-01 14:01:27 - Dex Loader] Unable to execute dex: Java heap space
[2012-11-01 14:01:27 - MathEclipse] Conversion to Dalvik format failed: Unable 
to execute dex: Java heap space

Original comment by huynhlam...@gmail.com on 1 Nov 2012 at 7:03

GoogleCodeExporter commented 9 years ago
The answers on stackoverflow may help?
http://stackoverflow.com/questions/7075875/java-heap-space

See this answer from December 2011:
"I experienced this Conversion to Dalvik format failed: Unable to execute dex: 
Java heap space. increasing the all of the values in the eclipse.ini file 
didn't help. This happened to me after I upgraded my ADT plugin from 12 to 16. 
I changed the Android SDKs that were pointed to my existing projects prior to 
the upgrade (from the android sdks that were connected on my previous adt I 
changed them to the android sdks that were connected to my new adt) and it 
solved the issue for me."

Original comment by axelclk@gmail.com on 1 Nov 2012 at 10:39

GoogleCodeExporter commented 9 years ago
Do you use the org.matheclipse.core.integrate.rubi package in adroid version? I 
removed that package, then it can be deployed into the device (HTC phone, 
android 4.0.3).

Original comment by huynhlam...@gmail.com on 1 Nov 2012 at 4:02