I’m using JMP to try and build an android game. I’ve got a working demo that compiles and runs on my android device just fine. Now I’m working on adding accelerometer support.
In the class I’ve written to read in accelerometer values, the build process cannot find the android classes unless I manually add android.jar to “Libraries”.
However, if I manually add “android.jar” to the libraries, then when I try to build I get the following
Generating resource IDs...
Compiling 2 source files to /home/josh/Codes/java/forestrunner/mobile/bin/classes
Converting compiled files and external libraries into /home/josh/Codes/java/forestrunner/mobile/bin/classes.dex...
trouble processing "java/nio/CharBuffer.class":
Ill-advised or mistaken usage of a core class (java.* or javax.*)
when not building a core library.
This is often due to inadvertently including a core library file
in your application's project, when using an IDE (such as
Eclipse). If you are sure you're not intentionally defining a
core class, then this is the most likely explanation of what's
1 error; aborting
/home/josh/Codes/java/forestrunner/nbproject/mobile-impl.xml:21: The following error occurred while executing this line:
/home/josh/android_sdk/android-sdk-linux/tools/ant/build.xml:752: The following error occurred while executing this line:
/home/josh/android_sdk/android-sdk-linux/tools/ant/build.xml:754: The following error occurred while executing this line:
/home/josh/android_sdk/android-sdk-linux/tools/ant/build.xml:766: The following error occurred while executing this line:
/home/josh/android_sdk/android-sdk-linux/tools/ant/build.xml:256: null returned: 1
If I comment out all the android stuff from my accelerometer class I can remove android.jar from the list of libraries and the game will build and run fine.
It's my understanding that by enabling android development under "Application->mobile" in project properties, the "android.jar" should be automatically added. However, this does not seem to be the case.
Any help would be appreciated.