OpenCV .so libraries show different symbol tables, why?

asked 2020-03-25 15:54:09 -0500

CharlesC gravatar image

updated 2020-03-25 15:54:57 -0500

Hello,

I did cross-compilation on opencv source code, and got a .so library for Android. When I check the symbol table, I found

nm -D libopencv_all.so | grep imread

0000000000865890 T _ZN2cv11imreadmultiERKSsRSt6vectorINS_3MatESaIS3_EEi 0000000000861600 T _ZN2cv6imreadERKSsi

nm -D libopencv_world.so | grep imwrite

0000000000866170 T _ZN2cv7imwriteERKSsRKNS_11_InputArrayERKSt6vectorIiSaIiEE

But when I check the symbol table of the libopencv_java4.so that I downloaded from opencv.org, I found the following

nm -D libopencv_java4.so | grep imread

00000000001d6d48 T Java_org_opencv_imgcodecs_Imgcodecs_imread_10 00000000001d70e0 T Java_org_opencv_imgcodecs_Imgcodecs_imread_11 00000000001d7cf4 T Java_org_opencv_imgcodecs_Imgcodecs_imreadmulti_10 00000000001d7f00 T Java_org_opencv_imgcodecs_Imgcodecs_imreadmulti_11 0000000000857dbc T _ZN2cv11imreadmultiERKNSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEERNS0_6vectorINS_3MatENS4_ISA_EEEEi 00000000008571c8 T _ZN2cv6imreadERKNSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEEi

nm -D libopencv_java4.so | grep imwrite

00000000001d8108 T Java_org_opencv_imgcodecs_Imgcodecs_imwrite_10 00000000001d833c T Java_org_opencv_imgcodecs_Imgcodecs_imwrite_11 000000000085879c T _ZN2cv7imwriteERKNSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEERKNS_11_InputArrayERKNS0_6vectorIiNS4_IiEEEE

Can anyone tell why there is a difference in the symbol tables of the two libraries? Many thanks!

Best Charles

edit retag flag offensive close merge delete