Closed gaobaiq closed 2 years ago
For Android you need to support libzmq yourself. I have made some changes (which are not published yet), which support other dll/lib names other than liblibzmq-v142-mt-4_3_5
(e.g. libzmq).
But essentially you need to follow these steps, which will get you a libzmq.so
. Which you need to include in your project following these steps
I hope to get a new version out, where the mentioned steps are not needed anymore
Very good. I'm trying to do the same. Now I build an so file and try to run the project.
Very good. I'm trying to do the same. Now I build an so file and try to run the project.
Also for now you will need to rename libzmq.so
to libzmq-v142-mt-4_3_5.so
Very good. I'm trying to do the same. Now I build an so file and try to run the project.
Also for now you will need to rename
libzmq.so
tolibzmq-v142-mt-4_3_5.so
yes,i did.
@gaobaiq I have pushed/released a new version, which has some changes and also adresses an issue with loading the share library. Now it should be possible to just have the library named libzmq.so
@gaobaiq I have pushed/released a new version, which has some changes and also adresses an issue with loading the share library. Now it should be possible to just have the library named
libzmq.so
It's so beautiful.I also want to run my project and share it with you later.
Does it work for you? I am also trying to get a simple example running on Android, but it does not find/load the native library
Ahh so it seems libc++_shared.so
is also needed for this to work
https://developer.android.com/ndk/guides/cpp-support#shared_runtimes
Luckily the Android ndk includes compiled versions of these for all platforms
Ahh so it seems
libc++_shared.so
is also needed for this to work https://developer.android.com/ndk/guides/cpp-support#shared_runtimes
I failed to build so.
Ahh so it seems
libc++_shared.so
is also needed for this to work https://developer.android.com/ndk/guides/cpp-support#shared_runtimesI failed to build so.
You don't have to. There are compiled versions of it inside the ndk (ndk\21.4.7075529\toolchains\llvm\prebuilt\windows-x86_64\sysroot\usr\lib
)
You don't have to. There are compiled versions of it inside the ndk (
ndk\21.4.7075529\toolchains\llvm\prebuilt\windows-x86_64\sysroot\usr\lib
)
I have many problems compiling with r23
Ohh gotcha, you need to use r21e
for now, newer versions are not supported (https://github.com/zeromq/libzmq/issues/4276)
Ohh gotcha, you need to use
r21e
for now, newer versions are not supported (zeromq/libzmq#4276)
OKey, i try it. thx!
Do you have a compiled so file? Can you share it? My email is baiqianggao@gmail.com or gaobaiqandroid@126.com
This zip includes all needed files for android native-libraries.zip
Ok, thanks!
Does it work now?
I also just noticed that my compiled version of libzmq does not have support for pgm
, tipc
, norm
, curve
, gssapi
and draft
, but for ipc
. So I will have to compile with curv
support again (because I need it). I also implemented the zmq_has
function so this can be checked during run-time.
Yes, I also found that the so file you provided does not support the TiCP protocol. And I also tried to run it with my own compiled so file, but it also failed.Now I'm trying to deal with it.
I also have no clue how to get it to compile with support for pgm
, tipc
, norm
, gssapi
and draft
. But lets see what the curve
binary has to offer
I also have no clue how to get it to compile with support for
pgm
,tipc
,norm
,gssapi
anddraft
. But lets see what thecurve
binary has to offer
Yes, we can start with this
As you might have noticed I released a new version, now containing checks for different capabilities. Also my new shared binary just has curve
support. No pgm
, tipc
, norm
, gssapi
and draft
.
@gaobaiq Do you really need tipc
on a mobile platform/Android? I don't see the use case there
@gaobaiq Do you really need
tipc
on a mobile platform/Android? I don't see the use case there
The company happened to have this server, so I tried it.
But isn't tipc
used for interprocess cluster communication? I would say that you would use a normal tcp
socket for communication with your frontend/app
Yes, there is no problem with TCP, but I happen to have a scene that needs it. And I can't use it now.
@gaobaiq So I can close this issue now?
I think you will have to figure out how to get a compiled version with tipc
yourself. If you manage to get it working I would be happy if you could share your findings. Then I can include them in the readme for others.
Failed to load dynamic library 'liblibzmq-v142-mt-4_3_5.so': dlopen failed: library "liblibzmq-v142-mt-4_3_5.so" not found