4

I am currently working on an android project that requires me to make use of functions included in a shared library (.so). I also only have header (.h) files for the library provided to me.

Is it possible to work with just these two files? Or do I need to create my own implemenations via c++ codes?

I am using Android Studio intend to use CMake.

Regards,

Philip

Philip
  • 55
  • 4

1 Answers1

3

Most Android apps are written in Java. Google has released the Native Developer Kit (NDK) in order to allow developers to write libraries in C++. However, these libraries are usually very low level and called from the Java code which defines the UI and higher-level app logic. Most likely you will need to write a wrapper for the library so that you can call it from Java code. Looks like this blog is a good place to start.

Code-Apprentice
  • 81,660
  • 23
  • 145
  • 268