vdj
vdj

Reputation: 11

Android NDK and shared library (libskia_android.so)

When I call a methods that are declared and defined in the header file I get SIGSEGV! When I call a methods that are not defined in header (they are implemented in .cpp file) everything works fine.

How linker works?How to solve this issue?

Thanks

Upvotes: 0

Views: 325

Answers (1)

vdj
vdj

Reputation: 11

I figure out what is problem! In Android.mk must be included "LOCAL_CFLAGS += -DSKIA_DLL". This will prevent instance counting. Instance counting relies on static variables in functions defined in header files,which increase size of class and changes the application binary interface (ABI) !

Upvotes: 1

Related Questions