简体   繁体   English

为Kali Linux 2编译FFMPEG

[英]Compiling FFMPEG for Kali Linux 2

I'm trying to install FFMPEG to Kali Linux 2.0 So far I've been trying to use the following commands: 我正在尝试将FFMPEG安装到Kali Linux 2.0到目前为止,我一直在尝试使用以下命令:

git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
cd ffmpeg
./configure
make
make install

However when I try and make it I get the following errors: 但是,当我尝试使其成功时,出现以下错误:

屏幕截图

libavcodec/x86/imdct36.asm:393: error: operation size not specified
library.mak:30: recipe for target 'libavcodec/x86/imdct36.o' failed
make: *** [libavcodec/x86/imdct36.o] Error 1

I'm really stumped as how to resolve this as my skill are only moderate... 我真的很困惑如何解决此问题,因为我的技能只是中等水平...

我偶然遇到了答案,但是我需要在编译之前安装YASM ...

apt-get install yasm

this particular problem took a lot of tracking down, due to the large numbers of macros in the source. 由于源中有大量的宏,此特定问题需要大量跟踪。 line 393 reads: 第393行显示:

DEFINE_IMDCT

and looking for that macro, we find it at line 179. but it has numerous instructions in it, and conditionals, and any one of those could be the culprit. 并在第179行找到该宏。但是它包含许多指令和条件,而其中任何一个都可能是罪魁祸首。 so first what we do is make V=1 to turn on verbose (normal) GNU make output. 所以首先我们要做的是make V=1以打开详细(正常)的GNU make输出。 then we see: 然后我们看到:

jcomeau@aspire:~/rentacoder/jcomeau/floureon/ffmpeg$ nasm -f elf -DPIC -g -F dwarf -I./ -I.// -Pconfig.asm -I libavcodec/x86/ -o libavcodec/x86/imdct36.o libavcodec/x86/imdct36.asm

we change that to: 我们将其更改为:

jcomeau@aspire:~/rentacoder/jcomeau/floureon/ffmpeg$ nasm -l /tmp/imdct36.lst -f elf -DPIC -g -F dwarf -I./ -I.// -Pconfig.asm -I libavcodec/x86/ -o libavcodec/x86/imdct36.o libavcodec/x86/imdct36.asm

to get a listing file. 获取清单文件。 looking into the listing for the operation size not specified error, we find it at line 102741, at level <4> of the macro expansion. 查看operation size not specified错误的列表,我们在宏扩展级别<4>的第102741行找到它。 scrolling up, we find the level 2 instruction at line 102668 as extractps [%3 + %4], %1, 1 and the level 1 instruction at line 102583, STORE m6, m7, outq + 16*SBLIMIT, 4*SBLIMIT . 向上滚动,我们在第102668行找到了第二级指令extractps [%3 + %4], %1, 1并在第102583行找到了1级指令, STORE m6, m7, outq + 16*SBLIMIT, 4*SBLIMIT

so we go back to libavcodec/x86/imdct36.asm, search for STORE, and find it at line 145. sure enough, we find 3 extractps instructions under it: 因此,我们返回libavcodec / x86 / imdct36.asm,搜索STORE,然后在第145行找到它。果然,我们在其下找到3个extractps指令:

extractps [%3 +   %4], %1, 1
extractps [%3 + 2*%4], %1, 2
extractps [%3 + 3*%4], %1, 3

we change them to: 我们将它们更改为:

extractps dword [%3 +   %4], %1, 1
extractps dword [%3 + 2*%4], %1, 2
extractps dword [%3 + 3*%4], %1, 3

assuming 32-bit operands. 假设32位操作数。 and sure enough, it finishes the build after that, without having to install yasm . 并且可以肯定的是,它随后完成了构建,而无需安装yasm

how do I know it shouldn't be qword instead? 我怎么知道它不应该是qword呢? I don't, but it doesn't make sense, since extractps only uses 32 bit destinations: "Extract a single-precision floating-point value from xmm2 at the source offset specified by imm8 and store the result to reg or m32. The upper 32 bits of r64 is zeroed if reg is r64." 我没有,但这没有意义,因为extractps仅使用32位目标地址:“从xmm2提取imm8指定的源偏移处的单精度浮点值,并将结果存储到reg或m32。如果reg为r64,则r64的高32位将清零。” ( http://www.felixcloutier.com/x86/EXTRACTPS.html ). http://www.felixcloutier.com/x86/EXTRACTPS.html )。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM