C/C++ How to Port a C++ Project into Android NDK?

AI Thread Summary
Porting a C++ project to Android poses challenges, particularly when integrating libraries like NTL, GMP, and OpenSSL. While compiling these libraries is manageable with available online resources, the main concern is effectively calling the C++ code within the Android environment. The common approach involves wrapping individual C++ functions in Java using JNI, but this method may not be practical for large projects with extensive codebases and multiple function calls. The discussion highlights the need for more comprehensive guidance on handling such complex integrations in Android development.
knowLittle
Messages
307
Reaction score
3
Hello All,

I know that this post is very old, but I have a similar question. I believe that it is very relevant and there should be copious material on the net, but I have been unable to find it.

I am trying to port a C++ project into Android. My project uses NTL, GMP, and OpenSSL. I am able to compile this libraries using instructions on the net, but I wonder how to go about calling the code in the project.
I have seen examples that individually call a function from a library in C++. So, this function would be wrapped in JAVA JNI form.
I highly doubt that this is the way to go in porting a huge project with many lines of code in many different files and different function calls.

Any one can help?
Thank you.
 
Technology news on Phys.org
This is a very good question and deserves to see some input, but unfortunately I don't have any good input, for I am having the same problem.
 
Dear Peeps I have posted a few questions about programing on this sectio of the PF forum. I want to ask you veterans how you folks learn program in assembly and about computer architecture for the x86 family. In addition to finish learning C, I am also reading the book From bits to Gates to C and Beyond. In the book, it uses the mini LC3 assembly language. I also have books on assembly programming and computer architecture. The few famous ones i have are Computer Organization and...
I had a Microsoft Technical interview this past Friday, the question I was asked was this : How do you find the middle value for a dataset that is too big to fit in RAM? I was not able to figure this out during the interview, but I have been look in this all weekend and I read something online that said it can be done at O(N) using something called the counting sort histogram algorithm ( I did not learn that in my advanced data structures and algorithms class). I have watched some youtube...
Back
Top