DLL not found

Going through
https://cmake.org/cmake/help/v3.15/manual/cmake-toolchains.7.html#cross-compiling-for-android

I assume we are in 32bit mode
And CMAKE_ANDROID_ARM_MODE should be on…

I couldn’t make it work either…

Yes it should be 32bit

Update : I can see that something is not propagating through the cmake generation process in my docker container.

The android toolchain file is being processed by my superbuild, but when it kicks off subordinate builds (eigen3, protobuf, and pulse), cmake is somehow not forwarding all the build information to them.
So what has been happening is that PulseC.so is just regular linux object, as all the cross compile directives got lost.

Still trying to figure out how what huh…

I wish I could be more helpful but I haven’t worked with c++ and make files since university. The least I can do is test any build you make.

Yeah, thanks Abray for helping us with this. I will test it too when you need it

Here is the latest Pulse cross compiled against my (old) Magic Leap/LuminOS SDK
This is for arm-v8a

https://data.kitware.com/#collection/59849c788d777f7d33e9c084/folder/5f20407f9014a6d84e44816e

I tried to make an IL2CPP build since Mono doesn’t compile to ARM64, and it didn’t work with that .so

Hmm… maybe Degly might have luck with it?

But while we wait, here is my latest incantation of armv7a
https://data.kitware.com/#collection/59849c788d777f7d33e9c084/folder/5f1971aa9014a6d84e34cd44

Reporting back!

Well, I tried both and they are showing the same errors as before. Tested with Mono and IL2CPP but the errors are still the same.

Thanks for trying it out.
I am going to try one more thing with my dockcross container
(Should get it up later tonight)

I am installing Codeworks now, so if that fails, I am going to see if I can use these NVidia tools to build a PulseC.so

Thank you abray, I will be here to test anything you send

Ok, next incantation:

https://data.kitware.com/#collection/59849c788d777f7d33e9c084/folder/5f1971aa9014a6d84e34cd44

Tried it, Still the same error. I tried it with the Vitals Monitor Scene, will try it on my project to see if it works

Same error for me too

Ok
I am fairly confident that I got my CMake issues all worked out
at this point I think I am going to try to experiment with various clang compiler and linker flags to see if I can get something out that works

I am using NDK version 16, which seems to be the lowest common denominator for armv7 support
Going to try with these flags (was not using any compiler flags before)

set(CMAKE_C_FLAGS “-march=armv7-a -Wl,–fix-cortex-a8 -mfpu=neon”)
set(CMAKE_CXX_FLAGS “-march=armv7-a -Wl,–fix-cortex-a8 -mfpu=neon”)
set(CMAKE_EXE_LINKER_FLAGS “-llog”)
set(CMAKE_SHARED_LINKER_FLAGS “-llog”)
set(CMAKE_MODULE_LINKER_FLAGS “-llog”)

I am not sure if I should set the -mcpu to anything in particular

Can you walk me through how you are testing this again?
I have unity 2019.4.5.f1
I installed all the android bells and whistles
I tried to use Nox, but it blue screens when I run it (I am not sure it likes running with docker or something)

In my case, I also have 2019.4.5f1
I have a completely clean project, and I only add a script with a DllImport for the impulse library on the method Allocate. And then I call that method on the start function.

This way I can explicitly check if the library works without any interference from other things. I also tested this with other libraries and it worked fine.

Then I make a build using Mono, for ARMv7 (which is the only architecture possible for Mono). And I sideload it to my samsung smartphone using adb.

Hmm
I don’t think I have a ARMv7 android device handy…

Looking in the unity settings


It looks like I need to at least build against 19 (I am currently using 16)
Do you have a minimum API level?

Yes I’m building for API level 19 as well

Here is a build against the 27 API using NDK revision 16b
https://data.kitware.com/#collection/59849c788d777f7d33e9c084/folder/5f1971aa9014a6d84e34cd44

I can push these out pretty quickly now, assuming everything is correct flag wise…