Hi,
I think that your problem might be happening because you build a
binary object (your OpenCV plugin) in one version of Ubuntu, and
then try to make it run in a different one. This is the cause Nº1
for linkage errors and things like "
libkmsmycvmoduleimpl.so.0:
undefined symbol:
_ZTv0_n64_NK7kurento12OpenCVFilter7getTypeB5cxx11Ev"
When building binaries in linux, the safest bet is to do it in the
same machine type and version than the destination. Because the
Kurento Docker images are based on "
ubuntu:16.04", that's
where you should be building your plugin.
You can install "
kurento-module-creator" without issues in a
Kurento container:
# On the host:
docker run -ti --rm --entrypoint /bin/bash
kurento/kurento-media-server:latest
# On the container:
apt-get update && apt-get install kurento-module-creator
There is an added problem: Ubuntu 16.04 (Xenial) came with OpenCV
2.x:
apt-cache policy libopencv-dev |
grep Candidate
Candidate: 2.4.9.1+dfsg-1.5ubuntu1.1
While Ubuntu 18.04 (Bionic) came with OpenCV 3.x:
apt-cache policy libopencv-dev |
grep Candidate
Candidate: 3.2.0+dfsg-4ubuntu0.1
So if you build your plugin against OpenCV 3, then it will surely
fail if you copy it and try to run with OpenCV 2.
Ideally, if your plugin is compatible with OpenCV 2, you would build
it inside a 16.04 container, and it will have a compatible binary
API for usage in Kurento Docker containers.
So I find two possibilities:
- If your plugin can be built with the OpenCV 2.x that comes
with Ubuntu 16.04, nice! all is done, and it's a good step
towards making it work.
- Otherwise, you'd need to check if it's too much effort to add
conditionals (#if and such) so that it compiles, or otherwise
maybe trying to install OpenCV 3.x on Ubuntu 16.04 (but that
will be tricky and much more complicated to get right)
We are well aware that Ubuntu 16.04 is an ancient version, that now
is even End Of Life, so we're planning on finally pulling the plug
and upgrading to Ubuntu 18.04 and Kurento 7.0 towards the end of
this year.
Regards,
Juan