metartc / metaRTC

A cross-platform webRTC SDK
Apache License 2.0
837 stars 214 forks source link

libyangh264decoder 编译问题 #68

Open matakk opened 8 months ago

matakk commented 8 months ago

1: Ubuntu下,编译 metaplayer7, 需要libyangh264decoder ,找到了一个2年前的项目 ,https://github.com/Romantic-LiXuefeng/yangh264decoder.git 编译后出现错误: g++ -Wl,-O1 -o ../../bin/app_release/metaplayer7 main.o mainwindow.o yangrecordthread.o YangPlayFactory.o YangPlayWidget.o YangPlayerBase.o YangPlayerDecoder.o YangPlayerHandleImpl.o YangPlayerPlay.o YangRtcReceive.o YangYuvPlayWidget.o moc_mainwindow.o moc_YangPlayWidget.o moc_YangYuvPlayWidget.o -L/root/metartc7.072.linux/bin -L../..//bin/lib_release -L../..//thirdparty/lib -lmetartc7 -lmetartccore7 -lyuv -lspeexdsp -lopus -lyangh264decoder -lusrsctp -ldl -lasound -lssl2 -lcrypto2 -lsrtp2 /usr/lib/x86_64-linux-gnu/libQt5Widgets.so /usr/lib/x86_64-linux-gnu/libQt5Gui.so /usr/lib/x86_64-linux-gnu/libQt5Core.so -lGL -lpthread
/usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264.c.o): in function decode_postinit': h264.c:(.text.decode_postinit+0xc72): undefined reference toff_thread_finish_setup' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264.c.o): in function decode_nal_units': h264.c:(.text.decode_nal_units+0xe4c): undefined reference toff_thread_report_progress' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_direct.c.o): in function await_reference_mb_row': h264_direct.c:(.text.await_reference_mb_row+0xc0): undefined reference toff_thread_await_progress' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_mb.c.o): in function await_references': h264_mb.c:(.text.await_references+0x7aa): undefined reference toff_thread_await_progress' /usr/bin/ld: h264_mb.c:(.text.await_references+0x7eb): undefined reference to ff_thread_await_progress' /usr/bin/ld: h264_mb.c:(.text.await_references+0x85e): undefined reference toff_thread_await_progress' /usr/bin/ld: h264_mb.c:(.text.await_references+0x8b3): undefined reference to ff_thread_await_progress' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_mb.c.o):h264_mb.c:(.text.await_references+0x8f2): more undefined references toff_thread_await_progress' follow /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_picture.c.o): in function ff_h264_unref_picture': h264_picture.c:(.text.ff_h264_unref_picture+0x59): undefined reference toff_thread_release_buffer' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_picture.c.o): in function ff_h264_field_end': h264_picture.c:(.text.ff_h264_field_end+0x167): undefined reference toff_thread_report_progress' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_slice.c.o): in function alloc_picture': h264_slice.c:(.text.alloc_picture+0xab): undefined reference toff_thread_get_buffer' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_slice.c.o): in function h264_frame_start': h264_slice.c:(.text.h264_frame_start+0x90): undefined reference toff_thread_can_start_frame' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_slice.c.o): in function get_pixel_format': h264_slice.c:(.text.get_pixel_format+0x48c): undefined reference toff_thread_get_format' /usr/bin/ld: /root/metartc7.072.linux/bin/libyangh264decoder.a(h264_slice.c.o): in function ff_h264_decode_slice_header': h264_slice.c:(.text.ff_h264_decode_slice_header+0x350): undefined reference toff_thread_report_progress'

请问这个 yangh264decoder 哪里找 另外,如果不要这个,直接使用ffmpeg 好像不行,这个库里面有一些导出的函数

'

loveliveoil commented 7 months ago

你需要使用这个链接的yangh264decoder才能编译成功: https://gitee.com/webrtc-mirror/yangh264decoder