日期:2014-05-16  浏览次数:20606 次

linux 编译
http://blog.chinaunix.net/u3/108358/showart_2132123.html
在网上发现这个源码,想编译一下
我已经有ffmpeg的源码,就在ffmpeg的根目录下创建了zhuan.c的文件
将源码拷贝进去,执行 gcc -o zhuan zhuan.c
结果:
/tmp/ccUXaZ5r.o:In function 'main':
play.c:(.text+0x1e):undefined reference to 'av_register_all'
play.c:(.text+0x56):underfined reference to 'av_open_input_file'
.
.
.
.
collect2: ld 返回1

请问有人见过这样的错吗?

------解决方案--------------------
把库链接上 gcc -o zhuan zhuan.c -l, 你可以在文件系统中找到库