Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation on raspberry using opencv 4.5.0-pre library. #20

Open
Un-ka opened this issue Sep 22, 2020 · 0 comments
Open

Compilation on raspberry using opencv 4.5.0-pre library. #20

Un-ka opened this issue Sep 22, 2020 · 0 comments

Comments

@Un-ka
Copy link

Un-ka commented Sep 22, 2020

I installed opencv library version 4.5.0-pre on raspberry pi 4.
But I have errors:

/usr/bin/ld: /tmp/ccjurhlf.o: неопределённая ссылка на символ «_ZN2cv8imencodeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS_11_InputArrayERSt6vectorIhSaIhEERKSB_IiSaIiEE»
 /usr/bin/ld: //usr/local/lib/libopencv_imgcodecs.so.4.5: error adding symbols: в командной строке не указан DSO
 collect2: error: ld returned 1 exit status

I solved this problem by replacing CV_ * with cv :: in the file according to this recommendation. Also I used the following command to compile.

sudo g++ MJPEGWriter.cpp main.cpp -o MJPEG -lpthread -lopencv_highgui -lopencv_core -lopencv_imgcodecs -lopencv_videoio -std=c++11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant