[FFmpeg-user] Unable to configure ffmpeg on FreeBSD

Tom Evans tevans.uk at googlemail.com
Wed Nov 7 11:16:05 CET 2012


On Tue, Nov 6, 2012 at 5:21 PM, Tom Evans <tevans.uk at googlemail.com> wrote:
> Hi all
>
> I have a problem getting ffmpeg's configure to work properly when
> specifying "--cc" and "--as" on the configure line.
>
> What seems to happen is that configure thinks that the "--as" argument
> supplied is actually a c compiler, and tests to see if it is LLVM etc.
>
> This hangs, because 'as -v' prints the version and then waits for
> input ('cc -v' prints the version and exits).
>
> Eg:
>
>> $ ./configure --as=/usr/local/bin/as --cc=/usr/local/bin/gcc46 --extra-libs=-L/usr/local/lib --extra-cflags="-I/usr/local/include"
>
>
>> $ pstree 43143
> -+= 43143 tom /bin/sh ./configure --as=/usr/local/bin/as
> --cc=/usr/local/bin/gcc46 --extra-libs=-L/usr/local/lib
> --extra-cflags=-I/usr/local/include
>  |--- 43280 tom /usr/local/bin/as -v
>  \--- 43281 tom grep -q ^gcc.*LLVM
>
> This check is around line 2486 in my current sources (pulled today):
>
>> $ grep -A 4 -B 1 -n gcc\.\*LLVM configure
> 2485-
> 2486:    if $_cc -v 2>&1 | grep -q '^gcc.*LLVM'; then
> 2487-        _type=llvm_gcc
> 2488-        gcc_extra_ver=$(expr "$($_cc --version | head -n1)" : '.*\((.*)\)')
> 2489-        _ident="llvm-gcc $($_cc -dumpversion) $gcc_extra_ver"
> 2490-        _depflags='-MMD -MF $(@:.o=.d) -MT $@'
>
>
> I've tried re-ordering where --cc and --as appear, with no effect.
> There are no CC or AS environment variables set.
>
> Cheers
>
> Tom

Having done a git bisect, the error was introduced in:


a758c5e2594893c0e7e1c5d966d6e486e2a77bb3 is the first bad commit
commit a758c5e2594893c0e7e1c5d966d6e486e2a77bb3
Author: Mans Rullgard <mans at mansr.com>
Date:   Fri Jul 20 13:43:07 2012 +0100

    build: do full flag handling for all compiler-type tools

    This adds a full identification probe of CC, AS, LD and HOSTCC,
    and sets up correct flags and dependency tracking for each.

    Signed-off-by: Mans Rullgard <mans at mansr.com>

:100644 100644 478ffcab4b2bc3fe98fd62e852ef6f765bcd1796
90b90fc18406b284db463c5e4e7019ce4d0bd4cf M      Makefile
:100755 100755 c91b5f1ef2c057775d85b2d16884b3aab6c20db0
fd903692122baf0b3e16234974554e6987ab1dd8 M      configure

I've not yet looked at the commit..

Cheers

Tom


More information about the ffmpeg-user mailing list