[FFmpeg-devel] Configure: commit 6dfcbd80ad446ff163b47f2bf432bbf706436ea8 broke my builds

Mark Himsley mark.himsley at gmail.com
Sat Oct 14 13:00:45 EEST 2017

I build FFmpeg and all the libraries I need every night. Since 08:00
BST on 12-Oct-2017 that build has not worked, the previous build on
11-Oct-2017 worked.

My configure command for building 64bit Linux that is run on an Ubuntu
16.04 system, which worked on Wednesday but not on Thursday, is:

./configure --extra-version=static_x86_64-pc-linux-gnu
--extra-cflags="--static -static" --extra-libs="-static"
--pkg-config-flags="--static" --cross-prefix= --arch=x86_64
--target-os=linux --prefix="/opt/bbc/ff_lib" --enable-gpl
--enable-nonfree --disable-ffplay --disable-dxva2 --enable-libmp3lame
--enable-libfdk-aac --enable-libspeex --enable-libtheora
--enable-libvorbis --enable-libopus --enable-libopenjpeg
--enable-libvpx --enable-libxvid --enable-libx264 --enable-libx265

(yes, the configure contains options, like cross-prefix and arch and
target that are not necessarily normally needed, but I build for
Linux, Windows 32 and 64 bit static binaries and macOS static binary
with the same configure command but with different variable

The configure.log extract is:

require libmp3lame >= 3.98.3 lame/lame.h lame_set_VBR_quality -lmp3lame
check_lib libmp3lame lame/lame.h lame_set_VBR_quality -lmp3lame
check_func_headers lame/lame.h lame_set_VBR_quality -lmp3lame
check_ld cc -lmp3lame
BEGIN /tmp/ffconf.Daqbd9DA/test.c
    1   #include <lame/lame.h>
    2   #include <stdint.h>
    3   long check_lame_set_VBR_quality(void) { return (long)
lame_set_VBR_quality; }
    4   int main(void) { int ret = 0;
    5    ret |= ((intptr_t)check_lame_set_VBR_quality) & 0xFFFF;
    6   return ret; }
END /tmp/ffconf.Daqbd9DA/test.c
gcc --static -static -I/opt/bbc/ff_lib/include -D_ISOC99_SOURCE
-D_XOPEN_SOURCE=600 --static -static -I/opt/bbc/ff_lib/include
--static -static -std=c11 -fomit-frame
-pointer -pthread -I/opt/bbc/ff_lib/include -c -o
/tmp/ffconf.Daqbd9DA/test.o /tmp/ffconf.Daqbd9DA/test.c
gcc -L/opt/bbc/ff_lib/lib -static -Wl,--as-needed -Wl,-z,noexecstack
-o /tmp/ffconf.Daqbd9DA/test /tmp/ffconf.Daqbd9DA/test.o -lmp3lame
/opt/bbc/ff_lib/lib/libmp3lame.a(gain_analysis.o): In function `AnalyzeSamples':
gain_analysis.c:(.text+0xedd): undefined reference to `log10'
/opt/bbc/ff_lib/lib/libmp3lame.a(gain_analysis.o): In function `analyzeResult':
gain_analysis.c:(.text+0x12aa): undefined reference to `ceil'
/opt/bbc/ff_lib/lib/libmp3lame.a(lame.o): In function `filter_coef':
lame.c:(.text+0xb1): undefined reference to `cos'
/opt/bbc/ff_lib/lib/libmp3lame.a(lame.o): In function `lame_init_params':
lame.c:(.text+0x320c): undefined reference to `pow'
lame.c:(.text+0x3463): undefined reference to `powf'
/opt/bbc/ff_lib/lib/libmp3lame.a(lame.o): In function `lame_print_internals':
lame.c:(.text+0x4613): undefined reference to `log10'

Etc. Which suggests to me that -lm is missing.

When I checkout 58143b15adda6391ec07f3eb19e80ed91d801edd, the parent
of 6dfcbd80ad446ff163b47f2bf432bbf706436ea8, my configure works.
When I checkout 6dfcbd80ad446ff163b47f2bf432bbf706436ea8 my configure fails.

If I edit configure to add -lm to the mp3lame tests, which works for
that library, the next library test fails in a similar way. I think
6dfcbd80ad446ff163b47f2bf432bbf706436ea8 has done sevear damage to the
configuration of FFmpeg. I wonder if building static was considered,
or whether my configure command line is not passing the right
parameters to make a static builds.

Mark Himsley

More information about the ffmpeg-devel mailing list