ffmpeg的在CentOS 64位安装“安装与-fPIC”错误 [英] ffmpeg install on CentOS 64-bit 'install with -fPIC' error
问题描述
我试图在64位CentOS的机器上编译的ffmpeg时出现此错误。
I get this error when attempting to compile ffmpeg on a 64bit CentOS machine.
下面是我的./configure选项:
Here are my ./configure options:
./配置--enable-共享--enable-GPL --enable-非自由--enable-postproc --enable-swscale --enable-pthreads的--enable-libx264 --enable -libxvid --enable-libvorbis --enable-libfaac --enable-libmp3lame --enable-libvpx
让
我编译源时,出现以下错误:
I get the following error when compiling the source:
/usr/bin/ld: /usr/local/lib/libvpx.a(vpx_codec.c.o): relocation R_X86_64_32 against .rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
/usr/local/lib/libvpx.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [libavcodec/libavcodec.so.54] Error 1
我如何解决这个错误,并得到libvpx起来,与我的64位的CentOS中最新的ffmpeg运行?
How do I get around this error, and get libvpx up and running with the latest ffmpeg on my 64-bit CentOS box?
推荐答案
既然你有--enable-共享配置FFmpeg的,你还需要配置它的一些其他图书馆与--enable-共享的,而且必须使用相同的设置。
Since you configured FFMPEG with "--enable-shared", you also need to configure some of it's other libraries with "--enable-shared" also, and they must all use the same setting.
此错误消息基本上是告诉你编译libvpx再次--enable-共享添加到configure命令,然后重新编译FFMPEG(还配置了--enable-共享)。有机会,然后你会得到同样的错误,但它会说libx264或libmp3lame而不是libvpx,所以你也将需要重新编译那些库与--enable-共享的configure命令。
This error message is basically telling you to compile libvpx again with "--enable-shared" added to the configure command, then try compiling FFMPEG again (also configured with "--enable-shared"). Chances are that you will then get the same error but it will say "libx264" or "libmp3lame" instead of "libvpx", so you will also need to recompile those libs with "--enable-shared" in the configure command.
这篇关于ffmpeg的在CentOS 64位安装“安装与-fPIC”错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!