How to add shared library search path to a executable file?
问题 I build the ffmpeg with librtmp. My librtmp is at /opt/librtmp/lib. When I execute the ffmpeg, it said: ./ffmpeg: error while loading shared libraries: librtmp.so.0: cannot open shared object file: No such file or directory I use ldd command it displays not found : [qty@testing bin]# ldd ffmpeg linux-vdso.so.1 => (0x00007fff15576000) librtmp.so.0 => not found libz.so.1 => /lib64/libz.so.1 (0x00002b9a71e10000) libm.so.6 => /lib64/libm.so.6 (0x00002b9a72025000) libpthread.so.0 => /lib64