xiaol / boilerpipe

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

Xerces for andorid jar file needed #74

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi, I have a problem when I included Xerces.jar into build path in order to use 
boilerpipe. It gives me error when trying to run android application,

UNEXPECTED TOP-LEVEL EXCEPTION:
com.android.dx.cf.iface.ParseException: bad utf-8 byte a0 at offset 00000004
    at com.android.dx.cf.cst.ConstantPoolParser.parseUtf8(ConstantPoolParser.java:374)
    at com.android.dx.cf.cst.ConstantPoolParser.parse0(ConstantPoolParser.java:262)
    at com.android.dx.cf.cst.ConstantPoolParser.parse0(ConstantPoolParser.java:294)
    at com.android.dx.cf.cst.ConstantPoolParser.parse(ConstantPoolParser.java:150)
    at com.android.dx.cf.cst.ConstantPoolParser.parseIfNecessary(ConstantPoolParser.java:124)
    at com.android.dx.cf.cst.ConstantPoolParser.getPool(ConstantPoolParser.java:115)
    at com.android.dx.cf.direct.DirectClassFile.parse0(DirectClassFile.java:482)
    at com.android.dx.cf.direct.DirectClassFile.parse(DirectClassFile.java:406)
    at com.android.dx.cf.direct.DirectClassFile.parseToInterfacesIfNecessary(DirectClassFile.java:388)
    at com.android.dx.cf.direct.DirectClassFile.getMagic(DirectClassFile.java:251)
    at com.android.dx.command.dexer.Main.processClass(Main.java:665)
    at com.android.dx.command.dexer.Main.processFileBytes(Main.java:634)
    at com.android.dx.command.dexer.Main.access$600(Main.java:78)
    at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:572)
    at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:284)
    at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
    at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
    at com.android.dx.command.dexer.Main.processOne(Main.java:596)
    at com.android.dx.command.dexer.Main.processAllFiles(Main.java:498)
    at com.android.dx.command.dexer.Main.runMonoDex(Main.java:264)
    at com.android.dx.command.dexer.Main.run(Main.java:230)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at com.android.ide.eclipse.adt.internal.build.DexWrapper.run(DexWrapper.java:187)
    at com.android.ide.eclipse.adt.internal.build.BuildHelper.executeDx(BuildHelper.java:786)
    at com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder.build(PostCompilerBuilder.java:597)
    at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:726)
    at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:199)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:321)
    at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:396)
    at org.eclipse.core.internal.resources.Project$1.run(Project.java:618)
    at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2344)
    at org.eclipse.core.internal.resources.Project.internalBuild(Project.java:597)
    at org.eclipse.core.internal.resources.Project.build(Project.java:124)
    at com.android.ide.eclipse.adt.internal.project.ProjectHelper.doFullIncrementalDebugBuild(ProjectHelper.java:1143)
    at com.android.ide.eclipse.adt.internal.launch.LaunchConfigDelegate.launch(LaunchConfigDelegate.java:155)
    at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:855)
    at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:704)
    at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1047)
    at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1251)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
Caused by: java.lang.IllegalArgumentException: bad utf-8 byte a0 at offset 
00000004
    at com.android.dx.rop.cst.CstString.throwBadUtf8(CstString.java:171)
    at com.android.dx.rop.cst.CstString.utf8BytesToString(CstString.java:143)
    at com.android.dx.rop.cst.CstString.<init>(CstString.java:200)
    at com.android.dx.cf.cst.ConstantPoolParser.parseUtf8(ConstantPoolParser.java:371)
    ... 43 more
...while parsing cst 00bf at offset 000008dd
...while parsing cst 003c at offset 00000109
...while parsing org/apache/xerces/impl/xpath/regex/ParserForXMLSchema.class

After done some research on google for 2 days, I found this,
http://stackoverflow.com/questions/20756461/error-while-importing-jar-into-an-an
droid-project

It seems that there are xerces jar file for android, but they only provide the 
source not binary. And i have hard time on trying to build it to jar. 

So if anyone has a ready xerces-for-android.jar, it will be much appreciated.

Original issue reported on code.google.com by lueikh...@gmail.com on 4 Apr 2014 at 3:45

GoogleCodeExporter commented 9 years ago
sorry, gave the wrong link. This is the right link,
http://stackoverflow.com/questions/2651804/xerces-on-android

Original comment by lueikh...@gmail.com on 4 Apr 2014 at 4:48

GoogleCodeExporter commented 9 years ago
easy to compile, just create in eclipse a java project and start it in folder 
with sources of this project then it builds and export a jar

jar file attachetd

Original comment by helpmep...@gmail.com on 16 Jul 2014 at 7:21

Attachments: