On Mon, 21 Mar 2016 20:37:25 +0800 (CST) qw <applema...@163.com> wrote:
> Hi, > > I want to build ffmpeg without optimization options, which means compiling > flags uses O0 instead of O1-O3. I use the following command to build ffmpeg, > where O1 is used in config.mak. > > ./configure --enable-debug --disable-optimizations ...... > > I want to disable all optimization options to debug ffmpeg/ffmpeg_g program. > If I change optimization options in config.mak, i.e. using O0 instead of O1, > there will be some error messages during the building process: > > libavutil/libavutil.a(cpu.o): In function `av_get_cpu_flags': > /export/qiang/sourceCode/ffmpeg-2.8.3/libavutil/cpu.c:82: undefined reference > to `ff_get_cpu_flags_aarch64' > /export/qiang/sourceCode/ffmpeg-2.8.3/libavutil/cpu.c:84: undefined reference > to `ff_get_cpu_flags_arm' > /export/qiang/sourceCode/ffmpeg-2.8.3/libavutil/cpu.c:86: undefined reference > to `ff_get_cpu_flags_ppc' > > How to build ffmpeg with O0 option? > > B.R. FFmpeg can't be built without optimizations. It relies on trivial dead code elimination to make the code "simpler". So it will do things like this: #define ARCH_SOMETHING 0 ... if (SOMETHING) arch_specific_symbol(); And rely that arch_specific_symbol is not referenced on platforms where ARCH_SOMETHING is 0. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel