The compile command I use is as follows:
gcc demuxing_decoding.c -o demuxing_decoding -g -I ./ffmpeg-5.0.1/include -L ./ffmpeg-5.0.1/lib/ \
-l avcodec -l avutil -l avformat -l swresample -lm -Wl,-rpath=./ffmpeg-5.0.1/lib/
The directory ./ffmpeg-5.0.1/lib/ clearly has the library libswresample.so.4, but it is suggested that the dynamic library cannot be found.
It is best to have no choice. You can only follow the method commonly used on the Internet: /etc/ld Add the directory where the library libswresample.so.4 is located in .so.conf, and execute the command ldconfig.
Read More:
- error while loading shared libraries: lib*.so: cannot open shared object file: No such file or directory
- ./popins2: error while loading shared libraries: libbifrost.so: cannot open shared object file: No such file or directory
- [Solved] error while loading shared libraries: libopencv_highgui.so.3.4: cannot open shared object file…
- [Solved] import cv2 Error: ImportError: libGL.so.1: cannot open shared object file: No such file or directory
- [619]libgtk-3.so.0 or libXt.so.6: cannot open shared object file: No such file or directory
- [Solved] import mxnet Error: OSError: libcudart.so.8.0: cannot open shared object file: No such file or directory
- [Samtools] Run error: error while loading shared libraries: libcrypto.so.1.0.0 or libncurses.so.5 or libtinfow.so.5
- ffmpeg:error while loading shared libraries: libopenh264.so.5
- [Solved] curl error while loading shared libraries libcrypto.so.1.0.0
- DM Install Error: error while loading shared libraries: libdmnsort.so:
- [Solved] fatal error C1083: Could Not Open Unable to open include file:“stdint.h”: No such file or directory
- [Solved] ERROR: Could not open requirements file: [Errno 2] No such file or directory : ‘requirments.txt‘
- [Solved] fatal error C1083: Cannot open included files: “stdafx.h”: No such file or directory
- [Solved] mongodb Install Error: mongod: error while loading shared libraries
- [Solved] open failed: ENOENT (No such file or directory)
- VSCode Unable to find custom header file directory: fatal error: no such file or directory
- Keil Compile Error: ..\OBJ\USART.axf: error: L6002U: Could not open file ..\obj\sys.o: No such file or directory
- [Solved] 1.fatal error: NvInfer.h: No such file or directory
- [Solved] fatal error: Eigen/Geometry: No such file or directory
- [Solved] utils.c:33:18: fatal error: zlib.h: No such file or directory