Running a compiled program on another ubuntu?

Good afternoon. Compiled the program in qt creator using opencv lib.
Copied to another computer folder release, an error in atstovai library and copied to this folder the necessary libs, it is still an error, copied in /usr/local/lib the same crap.
So did sudo ldconfig - v.

Used in Windows when you transfer all dll just to the folder with the exe to throw and everything works, but here's some sort of trick.
I'm not trying to compile opencv on each machine where a program is run?
June 10th 19 at 15:20
7 answers
June 10th 19 at 15:22
First and foremost, please forget that is
in Windows
. What was in the wind, then left in the wind. In Linux a different approach. There will not be a gun left loaded libs.
1. Check that /etc/ld.so.conf.d there is a file (any name) containing the line:
/usr/local/lib
If not, create and then ldconfig. Ensure that the correct libraries system saw through ldconfig -p
2. If you use opencv, then on the target machine must stand OpenCV - do You think package managers which automatically resolve dependencies and set - up just out of boredom?
3. You also automatically detecting it needs through the configure and error to give sane that OpenCV is not detected is if the program is only in the raw material to spread. But if packages that put the relevant package Manager, for which he should be given instruction of course :)
. What was in the wind, then left in the wind. In Linux a different approach. There will not be a gun left loaded libs.

these guys don't really agree )
https://www.ubuntu.com/desktop/snappy - sherwood.Gutkows commented on June 10th 19 at 15:25
Is the problem guys :) couldn't be bubuntu something special done, I just haven't worked out it never. But we had to carry practices between antosari and FreeBSD (not between them of course, but between multiple centesimi and several FreeBSD). So there turned out to be easier to develop the local package managers and packing experience in packages, when you install or pkg_add, yum itself will put dependi.

But here, of course everyone has his own owl :) - Esta_Upton commented on June 10th 19 at 15:28
June 10th 19 at 15:24
Link your statically
tell me how to do it in qt creator - sherwood.Gutkows commented on June 10th 19 at 15:27
, https://stackoverflow.com/questions/41188707/how-t... - Esta_Upton commented on June 10th 19 at 15:30
static linkage is not the fruit gave says error

error while loading shared libraries: libopencv_imgcodecs.so.3.3: cannot open shared object file: no such file or directory

in the pro file connect Libu so
LIBS += "pkg-config opencv --libs" - Kamryn.Crooks commented on June 10th 19 at 15:33
Have static link will appear to the licensing issues, since the LGPL allows you to not open their source code only when dynamic linking - chaz commented on June 10th 19 at 15:36
say, when statically linking, you can publish the object modules. - Kamryn.Crooks commented on June 10th 19 at 15:39
June 10th 19 at 15:26
In Ubuntu for such tasks invented Snappy
June 10th 19 at 15:28
For starters, take it for granted that the linux binary is not the app, the app is an entry in package Manager, with dependencies configured.

You should carefully record in dependencies all required libraries, to compile using crosscompilation, the application under several popular platforms (i686/x86_64/may be multiple arm), to build deb/rpm packages, at least for several popular versions of OSes (+, for aesthetes - ebuild) and only then to consider that you moved the app on another PC, otherwise it is crap to end users.
p.s. as a developer, you will be able to do it without any problems, because I KNOW what your app is and what uses it.
and Yes, test it all assembled debootstrap a minimal system image
June 10th 19 at 15:30
June 10th 19 at 15:32
Or linkui statically or collect the package, which will tighten libs
June 10th 19 at 15:34

Find more questions by tags LinuxProgrammingQt