Open zou493451860 opened 8 months ago
SRS 版本是5.0 ,Ubuntu 20.04
Ubuntu 23 server 版本 编译 srtp2报错
tar zxvf libsrtp-2-fit.tar.gz
cd libsrtp-2-fit/
./configure
make
cp libsrtp2.a FFmpeg-n4.3.3/metartc6
报错信息如下 :
root@iZwz9asjbuf3dgqcuunbeiZ:/mydata/ffmpeg/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6/libsrtp-2-fit# make
gcc -DHAVE_CONFIG_H -Icrypto/include -I./include -I./crypto/include -fPIC -Wall -pedantic -Wstrict-prototypes -O4 -fexpensive-optimizations -funroll-loops -I./test -L. -o crypto/test/aes_calc crypto/test/aes_calc.c test/util.c libsrtp2.a -lsrtp2
/usr/bin/ld: libsrtp2.a(datatypes.o):(.bss+0x0): multiple definition of `bit_string'; /tmp/ccKzQlkn.o:(.bss+0x0): first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:209: crypto/test/aes_calc] Error 1
Ubuntu 23 server 版本 编译 srtp2报错
编译 srtp2
tar zxvf libsrtp-2-fit.tar.gz cd libsrtp-2-fit/ ./configure make cp libsrtp2.a FFmpeg-n4.3.3/metartc6
我的编译环境是Ubuntu 20.04 ,GCC版本是:gcc version 11.3.0 (GCC) 你这个错误可以看看这个解决办法:编译libsrtp-2-fit的错误
@zou493451860 这个报错怎么处理 BEGIN /tmp/ffconf.Dx9AVYuG/test.c 1 int main(void){ return 0; } END /tmp/ffconf.Dx9AVYuG/test.c gcc -c -o /tmp/ffconf.Dx9AVYuG/test.o /tmp/ffconf.Dx9AVYuG/test.c gcc -o /tmp/ffconf.Dx9AVYuG/test /tmp/ffconf.Dx9AVYuG/test.o -L/home/user/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6 -lmetartccore6 -lpthread -lsrtp2 -lssl -lcrypto -ldl /usr/bin/ld: cannot find -lmetartccore6: No such file or directory /usr/bin/ld: cannot find -lsrtp2: No such file or directory collect2: error: ld returned 1 exit status C compiler test failed.
@zou493451860 这个报错怎么处理 BEGIN /tmp/ffconf.Dx9AVYuG/test.c 1 int main(void){ return 0; } END /tmp/ffconf.Dx9AVYuG/test.c gcc -c -o /tmp/ffconf.Dx9AVYuG/test.o /tmp/ffconf.Dx9AVYuG/test.c gcc -o /tmp/ffconf.Dx9AVYuG/test /tmp/ffconf.Dx9AVYuG/test.o -L/home/user/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6 -lmetartccore6 -lpthread -lsrtp2 -lssl -lcrypto -ldl /usr/bin/ld: cannot find -lmetartccore6: No such file or directory /usr/bin/ld: cannot find -lsrtp2: No such file or directory collect2: error: ld returned 1 exit status C compiler test failed.
--extra-libs='-L/home/oook/user/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6 -lmetartccore6 -lpthread -lsrtp2 -lssl -lcrypto -ldl' 确认你的ffmpeg-webrtc目录是在/home/oook/user/下
@zou493451860 这个报错怎么处理 BEGIN /tmp/ffconf.Dx9AVYuG/test.c 1 int main(void){ return 0; } END /tmp/ffconf.Dx9AVYuG/test.c gcc -c -o /tmp/ffconf.Dx9AVYuG/test.o /tmp/ffconf.Dx9AVYuG/test.c gcc -o /tmp/ffconf.Dx9AVYuG/test /tmp/ffconf.Dx9AVYuG/test.o -L/home/user/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6 -lmetartccore6 -lpthread -lsrtp2 -lssl -lcrypto -ldl /usr/bin/ld: cannot find -lmetartccore6: No such file or directory /usr/bin/ld: cannot find -lsrtp2: No such file or directory collect2: error: ld returned 1 exit status C compiler test failed.
--extra-libs='-L/home/oook/user/ffmpeg-webrtc/FFmpeg-n4.3.3/metartc6 -lmetartccore6 -lpthread -lsrtp2 -lssl -lcrypto -ldl' 确认你的ffmpeg-webrtc目录是在/home/oook/user/下
可以了,感谢
请问推流的时候不会报错吗?我推流报如下的错误: avinfo->sys.whipUrl==webrtcProxy/exchangeSdp?streamName=dyj-test session->context.avinfo->sys.whipUrl=webrtcProxy/exchangeSdp?streamName=dyj-testYang Error(1): query whip sdp failure! [webrtc @ 0x5617f1b7d6c0] connect failed! uri= http://10.71.7.32:8080/webrtcProxy/exchangeSdp?streamName=dyj-test [webrtc @ 0x5617f1b7d6c0] webrtc_open exit
请问推流的时候不会报错吗?我推流报如下的错误: avinfo->sys.whipUrl==webrtcProxy/exchangeSdp?streamName=dyj-test session->context.avinfo->sys.whipUrl=webrtcProxy/exchangeSdp?streamName=dyj-testYang Error(1): query whip sdp failure! [webrtc @ 0x5617f1b7d6c0] connect failed! uri= http://10.71.7.32:8080/webrtcProxy/exchangeSdp?streamName=dyj-test [webrtc @ 0x5617f1b7d6c0] webrtc_open exit
使用ffmpeg-webrtc推whip协议流没有测试成功,可以推rtmp流到SRS,然后拉取SRS的whep流是可以的
请问推流的时候不会报错吗?我推流报如下的错误: avinfo->sys.whipUrl==webrtcProxy/exchangeSdp?streamName=dyj-test session->context.avinfo->sys.whipUrl=webrtcProxy/exchangeSdp?streamName=dyj-testYang Error(1): query whip sdp failure! [webrtc @ 0x5617f1b7d6c0] connect failed! uri= http://10.71.7.32:8080/webrtcProxy/exchangeSdp?streamName=dyj-test [webrtc @ 0x5617f1b7d6c0] webrtc_open exit
使用ffmpeg-webrtc推whip协议流没有测试成功,可以推rtmp流到SRS,然后拉取SRS的whep流是可以
现在应该是推不了webrtc,正常的查询sdp信息的接口,代码也会报错。我看了metaRTC最新版的代码和这个库里面差别有点大,估计修复了,没更新到这里面来。
FFmpeg-Webrtc Ubuntu编译
FFmpeg-Webrtc拉取 whep命令示例
增加ffplay、pulse配置 -》 编译FFmpeg-webrtc
我把Get the Dependencies建议的包都给安装了