Next the last time, http://www.cnblogs.com/zjjcy/p/3384517.html
The last port transplanted ffmpeg on the ARM, but only the pure C code, without Assembly optimization. Because ffmpeg ARM assembly is GNU, Microsoft's built-in assembly compiler armasm does not support this style of Assembly syntax.
So I thought of two solutions. One is to rewrite the GNU-style assembly to the standard ARM Assembly format, and the other is to compile it with the GCC tool, and then convert the compiled file, from elf format to COFF format supported by Microsoft.
I am not very familiar with GCC, So I adopted the first solution. The first solution is the most troublesome one.
Special thanks to this great god http://www.cnblogs.com/zcmmwbd/p/windows-phone-8-armasm-guide.html#2842650 He guided me How to migrate, I did not understand assembly, the great god patiently explain to me, let me very touched.
Therefore, I think the migration results should be made public. As the saying goes, jide is doing well. I also have a wonderful new year. Please download them at this address.
Https://ffmpegwinrtarm.codeplex.com/
Next, let's talk about the compilation process.
4. Modify the config. mak and config. H files.
Enable HAVE_NEON
5. make
In the make process, an error similar to AS libavocodec/arm/aacpdsp_neon.o is encountered, because armasm cannot accept additional parameters.
In this case, use the console cd of VS13 ARM to the libavocodec/arm folder and run build. bat.
Make continues after running successfully. The same problem occurs in libavutil and libswresample.
6. make install
The second solution, which I have not tried, is the solution provided by ARM. objcopy can help with the conversion, that is, compile the neon with linux tools. o file, and then go to it and link it to ffmpeg of winrt.
Here we will talk about the changes. First, there will be an as check in the config file, but armasm cannot complete this check, so I will comment out the corresponding code. During compilation, the tool chain will pass a lot of parameters to armasm, which are not supported, but will be stopped halfway, and then call the build script, the purpose of this script is to compile the assembly code. o file. o file, and then make, the compiler can be linked in.
In the process of code conversion, one is the conversion of corresponding commands and corresponding syntax. You can refer to my conversion results, and the other is the data alignment. In the THUMB syntax, the DATA Alignment is automatically + 1, so the DATA segment must be placed under AREA. rodata, DATA, and ARM so that the compilation can be correct.
Finally, today is the last day of 2013. I am very happy to solve this problem today. It will take a good year. I wish you a complete family and a successful career in the New Year.