User forums > Using Code::Blocks
Error while loading shared library
mihasic:
I try to use OpenCV 4.6.0 with CodeBlocks 20.03 under linuxMint 20. It looks like it compiles ok, but when it comes to running, I receive the message
: error while loading shared libraries: libopencv_core.so.406: cannot open shared object file: No such file or directory
The file in question, as well as all the other .so files, is listed in Global compiler settings ->Linker settings->Link libraries
and the directory it is in is written in the Global compiler settings ->Search directories->Linker
Could anybody tell me what I am missing?
Thank you.
stahta01:
1. Using the Global settings instead of project settings tend to cause future issues. It might also cause your current issue.
2. If running outside of Code::Blocks.
2a. copy shared library to the correct location.
2b. Or tell your system where to find the shared library.
Tim S.
stahta01:
Link to how to report problem. If you post a build log an Linux person might see the cause of the problem.
https://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F
I am a Windows person who has used Linux in the past.
Tim S.
mihasic:
--- Quote from: stahta01 on November 30, 2022, 11:20:21 pm ---Link to how to report problem. If you post a build log an Linux person might see the cause of the problem.
https://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F
I am a Windows person who has used Linux in the past.
Tim S.
--- End quote ---
I beg your pardon, the link you gave deals with compiler problems, whereas my problem is related to linkage and appears at the run time. As I had stated, the object file is produced ok.
mihasic:
--- Quote from: stahta01 on November 30, 2022, 10:22:19 pm ---1. Using the Global settings instead of project settings tend to cause future issues. It might also cause your current issue.
2. If running outside of Code::Blocks.
2a. copy shared library to the correct location.
2b. Or tell your system where to find the shared library.
Tim S.
--- End quote ---
Once again, as I had formulated in the initial post, all this had been done.
Navigation
[0] Message Index
[#] Next page
Go to full version