Ask Your Question
0

Error building OpenCV 2.4.x "Undefined reference to av_opt_set@LIBAVUTIL_51"

asked 2013-01-04 20:54:22 -0600

wabryan gravatar image

updated 2013-01-04 20:56:58 -0600

I have tried building all versions of 2.4, and they all fail when "Linking CXX executable ../../bin/opencv_test_core" with:

/home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_opt_set@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_strcasecmp@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_bprint_finalize@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_timecode_make_smpte_tc_string@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_timecode_make_string@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_realloc_f@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_timecode_get_smpte_from_framenum@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_timecode_init@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_samples_set_silence@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_calloc@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_opt_get@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_strncasecmp@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_samples_fill_arrays@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_get_media_type_string@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_dynarray_add@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_bprint_init@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_asprintf@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_sample_fmt_is_planar@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_samples_get_buffer_size@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_opt_get_int@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_timecode_make_mpeg_tc_string@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_rescale_q_rnd@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_bprintf@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_samples_copy@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_get_default_channel_layout@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_timecode_init_from_string@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_bprint_chars@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_des_mac@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavcodec.so.54: undefined reference to 'av_timecode_adjust_ntsc_framenum@LIBAVUTIL_51' /home/root/opencv/2.4.3/build/lib/libavformat.so.54: undefined reference to 'av_timegm@LIBAVUTIL_51 ... (more)

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2013-01-05 03:21:54 -0600

updated 2013-01-05 03:27:03 -0600

libavutil is a part of FFMPEG. It looks like libavutil is missing on your machine or the path to the library is not add to environment variables. Try to use ffmpeg tool for test. Is it fine?

edit flag offensive delete link more

Comments

I have it installed, but I'm not sure how to go about testing it. Can you provide me with some advice on how to test it, specifically?

Thanks

wabryan gravatar imagewabryan ( 2013-01-06 20:14:30 -0600 )edit

root@omap4-mult:~i# ffmpeg ffmpeg version 0.11.2 Copyright (c) 2000-2012 the FFmpeg developer built on Jan 3 2013 22:25:03 with gcc 4.7.2 configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab --enable-shared --enable-static --enable-pic libavutil 51. 54.100 / 51. 54.100 libavcodec 54. 23.100 / 54. 23.100 libavformat 54. 6.100 / 54. 6.100 libavdevice 54. 0.100 / 54. 0.100 libavfilter 2. 77.100 / 2. 77.100 libswscale 2. 1.100 / 2. 1.100 libswresample 0. 15.100 / 0. 15.100 libpostproc 52. 0.100 / 52. 0.100

wabryan gravatar imagewabryan ( 2013-01-06 20:20:42 -0600 )edit

Question Tools

2 followers

Stats

Asked: 2013-01-04 20:54:22 -0600

Seen: 2,197 times

Last updated: Jan 05 '13