When call a shared library, a java.lang.UnsupportedClassVersionError: Bad version number in .class file exception occurs.
A compile-time/run-time mismatch in the versions of Java.
The library was compiled for Java1.6; however, it was running with Java1.5.
In the Ant build file, specify the version of source and target in the javac task to match the run-time Java version.
<javac … source=”1.5″ target=”1.5″/>