posted 23 years ago
I am just trying to create a JVM from C program however I always got the following error message during compilation. I have already include the path of the jni.h and jni_md.h during compilation
/tmp/cc8LnTgM.o: In function `main':
/tmp/cc8LnTgM.o(.text+0xc3): undefined reference to `JNI_GetDefaultJavaVMInitArgs'
/tmp/cc8LnTgM.o(.text+0xfa): undefined reference to `JNI_CreateJavaVM'
/tmp/cc8LnTgM.o(.rodata+0x74): undefined reference to `Java_test_MainWithNatives_native0'
/tmp/cc8LnTgM.o(.rodata+0x80): undefined reference to `Java_test_MainWithNatives_native1'
collect2: ld returned 1 exit status
Does anyone know how the causes of such error message and how to solve it?
Thanks