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
linking error on Ubuntu 14.04 32 bit #215
Comments
This should not happen, I suspect there's something wrong with your ffmpeg/libav installation. Did you accidentally install two versions of ffmpeg/libav at the same time? |
I think so, I manually installed ffmpeg in the past. This link http://askubuntu.com/questions/432542/is-ffmpeg-missing-from-the-official-repositories-in-14-04 states that ffmpeg is not compatible with 14.04 so it's dropped. From which source code can I install it and with which parameters? |
ffmpeg is compatible with Ubuntu 14.04, but the old 'ffmpeg' package isn't the real ffmpeg. Ubuntu uses libav (a fork of ffmpeg). You can't really install ffmpeg and libav at the same time, and you probably can't uninstall the libav packages because lots of applications depend on it. If you want the real ffmpeg, you may want to try this PPA: |
I removed libav-tools and installed ffmpeg from http://answers.ros.org/question/171326/catkin-linking-order-undefined-reference-to-symbol/ |
The problem is that your headers (/usr/include) don't match your libraries (/usr/lib). That probably means you still have some old version of ffmpeg/libav lying around somewhere. Installing new versions won't help unless you also remove the old version. Try running |
I am sorry for taking your time. It appears that I have a few
|
I think you should remove the following files:
But you should do the same for libavformat, libavutil, libswscale, libswresample, libavresample, libavfilter, ... so it is probably better to find the real source of the files rather than just manually deleting them. The ones in /usr/local/lib were probably installed manually with I'm not sure where the libavcodec.so.53 files came from, those belong in Ubuntu 12.04, not 14.04 ... |
For the record, I was able to do the 64-bit part of the compilation using the standard |
@saiarcot895 |
I managed to compile it at last. I think your solution worked saiarcot895 Thank both of you for all your help. |
Hi;
Thank you for nice project. I cloned your repo here and run
./simple-build-and-install
in the source directory, all went well till linking process. I got./.libs/libsimplescreenrecorder-target-ssse3.a -lQtGui -lQtCore -lrt -lavformat -lavcodec -lavutil -lswscale -lX11 -lXext -lXfixes -lXi -lasound -lpulse -ljack -pthread AV/simplescreenrecorder-AVWrapper.o: In function
AVFrameWrapper::AVFrameWrapper(std::shared_ptr const&)':AVWrapper.cpp:(.text+0x123): undefined reference to
av_frame_alloc' AV/simplescreenrecorder-AVWrapper.o: In function
AVFrameWrapper::~AVFrameWrapper()':AVWrapper.cpp:(.text+0x22d): undefined reference to
av_frame_free' collect2: error: ld returned 1 exit status
error message. I googled it a bit some say that it stems from linker order http://stackoverflow.com/questions/16885314/c-code-using-ffmpeg-libraries-compilation-error, another says it stems from outdated ffmpeg installation, and another guy points out
encompassing FFmpeg includes using extern "C"."
http://stackoverflow.com/questions/9701764/undefined-reference-using-ffmpeg-library-avcodec-on-ubuntu-64-bits-system
How can I fix that error?
Regards
Kenn
The text was updated successfully, but these errors were encountered: