The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
undefined reference to 'Android_JNI_ShowMessageBox'
Limanima


Joined: 09 Oct 2013
Posts: 75
I just updated to the last mercurial version of SDL and now I'm getting an undefined reference when compiling under Eclipse/NDK.

Note: I'm compiling for all ABI.

armeabi-v7a
compiles OK.

armeabi
Undefined reference
Here is the error:

(...)/android-ndk-r10/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld.exe: ./obj/local/armeabi/objs/SDL2/src/video/android/SDL_androidmessagebox.o: in function Android_ShowMessageBox:jni/SDL/src/video/android/SDL_androidmessagebox.c:32: error: undefined reference to 'Android_JNI_ShowMessageBox'

Any ideas?
Re: undefined reference to 'Android_JNI_ShowMessageBox'
Limanima


Joined: 09 Oct 2013
Posts: 75
Limanima wrote:
I just updated to the last mercurial version of SDL and now I'm getting an undefined reference when compiling under Eclipse/NDK.

Note: I'm compiling for all ABI.

armeabi-v7a
compiles OK.

armeabi
Undefined reference
Here is the error:

(...)/android-ndk-r10/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/../lib/gcc/arm-linux-androideabi/4.6/../../../../arm-linux-androideabi/bin/ld.exe: ./obj/local/armeabi/objs/SDL2/src/video/android/SDL_androidmessagebox.o: in function Android_ShowMessageBox:jni/SDL/src/video/android/SDL_androidmessagebox.c:32: error: undefined reference to 'Android_JNI_ShowMessageBox'

Any ideas?


There seems to be some confusion in Eclipse. I rolledback the changes and the problem persisted.
I've closed Eclipse and now I'm recompiling (after cleaning up everything). It seems to be working now, but it will take a while to compile everything...
Ignore this thread for now.
Sorry