Skip to content
This repository has been archived by the owner on Oct 1, 2019. It is now read-only.

undefined reference to `cv::VideoCapture::VideoCapture()' #253

Closed
Tord-Zhang opened this issue Apr 27, 2017 · 19 comments
Closed

undefined reference to `cv::VideoCapture::VideoCapture()' #253

Tord-Zhang opened this issue Apr 27, 2017 · 19 comments

Comments

@Tord-Zhang
Copy link

when I run "make all",there are errors:
build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::set(int, double)'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::open(cv::String const&)' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::release()'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::~VideoCapture()' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::isOpened() const'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::get(int) const' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::read(cv::_OutputArray const&)'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::VideoCapture()' collect2: error: ld returned 1 exit status make: *** [.build_release/tools/compute_image_mean.bin] Error 1 make: *** Waiting for unfinished jobs.... .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::set(int, double)'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::open(cv::String const&)' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::release()'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::~VideoCapture()' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::isOpened() const'
.build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::get(int) const' .build_release/lib/libcaffe.so: undefined reference to cv::VideoCapture::read(cv::_OutputArray const&)'
`
How can I fix this?

@dutran
Copy link
Contributor

dutran commented Apr 27, 2017

do you have opencv and ffmpeg installed on your machine?

@Tord-Zhang
Copy link
Author

yes,I have already install opencv.and I can successfully compile v1.0.

@dutran
Copy link
Contributor

dutran commented May 2, 2017

It is weird, sounds like a linking problem. Some LD_LIBRARY_PATH may solve it

@dutran
Copy link
Contributor

dutran commented May 5, 2017

check this #259

@dutran
Copy link
Contributor

dutran commented May 5, 2017

@mangdian try again, just modify Makefile

@heixi
Copy link

heixi commented May 8, 2017

5tuwt
How to solve this problem? i using GTX1080 + cuda8.0 + cudnn5.0 @dutran

@sunnyxiaohu
Copy link

modify : LIBRARIES += opencv_core opencv_highgui opencv_imgproc opencv_video
to: LIBRARIES += opencv_core opencv_highgui opencv_imgproc opencv_videoio

@dutran
Copy link
Contributor

dutran commented May 8, 2017

try to pull and compile again should solve the issue.

@dutran dutran closed this as completed May 8, 2017
@jzyztzn
Copy link

jzyztzn commented May 10, 2017

@sunnyxiaohu thanks,it works for me,(and my opencv version is 3.2).

@IanMin1022
Copy link

@sunnyxiaohu how can I put the linking in my bash?

@codestamp
Copy link

thanks @sunnyxiaohu adding opencv_videoio did the job.

@prasuchit
Copy link

Hi,

Could you tell me the location of this makefile where the path change has to be made? I tried searching through the entire opencv folder and couldn't find the right file.

@ibrahimqazi
Copy link

It is weird, sounds like a linking problem. Some LD_LIBRARY_PATH may solve it

I have also the same problem, I am using ROS and compiling it using Catkin, I have CMakeLists.txt file for my package. Can you please explain what is mean by LD_LIBRARY_PATH, how can I solve it in my case ? thanks

@YHAY
Copy link

YHAY commented Dec 19, 2018

It is weird, sounds like a linking problem. Some LD_LIBRARY_PATH may solve it

I have also the same problem, I am using ROS and compiling it using Catkin, I have CMakeLists.txt file for my package. Can you please explain what is mean by LD_LIBRARY_PATH, how can I solve it in my case ? thanks

i have same problem:(

@BluebirdStory
Copy link

或许这就是大佬吧 @sunnyxiaohu

@showgood163
Copy link

@sunnyxiaohu
Thank you.

@TangAL0203
Copy link

@sunnyxiaohu 大佬大佬!

@TangAL0203
Copy link

modify Makefile as @sunnyxiaohu said!

@sljlp
Copy link

sljlp commented Mar 6, 2019

modify : LIBRARIES += opencv_core opencv_highgui opencv_imgproc opencv_video
to: LIBRARIES += opencv_core o

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests