Reputation: 35114
I have been developed one utility named, Ticker.
I packed in a Jar and try to use in different project.
I am using Eclipse. At the time of creating binary (JAD/JAR) I am getting pre-verification error.
After that I tried one workaround. I create binary and manually inject required classes in it.
When I tried to run on Sun Emulator (WTK 2.5 DefaultColorPhone) getting pre-verification error. On the other hand build is working fine on KEmulator (all you know KEmulator run on JVM rather than KVM).
Subsequently, I looked in a lib and found classes are not verified.
Then I do verification using WTK preverify.exe; but what I noticed out of 4, 2 classes are not pre-verified (StackMap entry is missing).
Class Hierarchy
Ticker.java //Verified
Text.java extends Component.java //Verified
Component.java extends TimeControlled.java //Not Verified
TimeControlled.java //Not Verified
Please get me rid of that.
Amit
Upvotes: 0
Views: 175
Reputation: 4043
In the past I have done this by creating an Ant script with Antenna:
. compile the java source
<wtkbuild srcdir="./src" destdir="./classes" preverify="false"/>
. copy your resources
<copy todir="./classes">
<fileset dir="./res"/>
</copy>
. extract the library jar
<unjar src="./lib/Ticker.jar" dest="./classes"/>
. preverify everything
<wtkpreverify srcdir="./classes" destdir="./classes"/>
. package your jar file
<wtkpackage jarfile="myapp.jar" jadfile="myapp.jad">
<fileset dir="./classes"/>
</wtkpackage>
Upvotes: 0