Stumbled upon this thread (glad I did). Had the same error as the original poster and your native.java fixed it. I did not have this issue in 3.5, but I did in 4.0. I did have to use the updated sw.jar file to first even get the android SDK/NDK to download. Did many project cleans, reinstalled the SDK/NDK as well as most recent Java SDK. Only this fix helped, app compiled fine and pushed out to my android device with no issues afterwards. Let me know if you want any further info on system setup/versions/etc.