[FFmpeg-devel] [PATCH v12] - Added Turing codec interface for ffmpeg
Saverio Blasi
Saverio.Blasi at bbc.co.uk
Wed Jul 5 17:56:16 EEST 2017
>>So I did try to build this, but the ffmpeg configure check apparently fails at picking it up and dumps 3.5MB of C++ linker errors into the config.log. And I have no idea why it does that. configure actually prints "ERROR: libturing not found using pkg-config", but the .pc part seems to be ok, but maybe the check_cpp_condition call tries to link.
>>
>>The first error is:
>>
>>lib/libturing.a(encode.cpp.o): In function `operator<<(std::ostream&, res
idual_coding)': encode.cpp:(.text+0xf6e): undefined reference to `std::basic_ostream<char, std::char_traits<char>
>>& std::operator<< <std::char_traits<char> >(std::basic_ostream<char, std::char_traits<char> >&, char const*)'
>>
>>The .pc file actually contains -lstdc++. Going by the linker error, this is probably what's needed?
>>
>>I have no idea why this error happens, but it seems a deal breaker. I'm using gcc on Debian, and built libturing with a standard cmake invocation.
Thanks a lot for trying this out. I am struggling a bit to replicate this error. I am using Ubuntu in my local machine but I have also just tried with a clean Debian installation in a Docker container. The Dockerfile clones both ffmpeg and Turing repositories, applies the patch as from the email, builds and installs the Turing library in a specific folder, and finally configures and builds ffmpeg succesfully. I am not quite sure what the difference could be with your workflow. Which version of gcc are you using? I have tested this with gcc 6. .I have also tried with an old Linux machine with 4.8.2 and that works as well. If I understand correctly, you are able to successfully build Turing and the problem happens later when configuring ffmpeg, is this correct?
Below is the Dockerfile I have used for your reference, maybe I am doing something wrong in there which prevents me from catching this error.
Any help in resolving this would be very much appreciated. Thanks a lot for your help, and sorry for using up your time.
Saverio
FROM debian:latest
RUN apt-get -y update && \
apt-get -y install cmake && \
apt-get -y install git && \
apt-get -y install build-essential && \
apt-get -y install pkg-config && \
apt-get -y install yasm
RUN mkdir source
WORKDIR /source/
RUN mkdir /source/ffmpeg && git clone https://github.com/FFmpeg/FFmpeg.git /source/ffmpeg && \
mkdir /source/turingcodec && git clone https://github.com/bbc/turingcodec.git /source/turingcodec && \
mkdir /source/ffmpeg/ffmpeg_build && \
mkdir /source/turingcodec/build
WORKDIR /source/turingcodec/build
RUN cmake -DCMAKE_INSTALL_PREFIX="/source/ffmpeg/ffmpeg_build" .. && \
make && \
make install
WORKDIR /source/ffmpeg
COPY 0001-Added-Turing-codec-interface-for-ffmpeg.patch /source/ffmpeg
RUN git apply 0001-Added-Turing-codec-interface-for-ffmpeg.patch && \
PKG_CONFIG_PATH="/source/ffmpeg/ffmpeg_build/lib/pkgconfig" ./configure --prefix="/source/ffmpeg/ffmpeg_build" \
--pkg-config-flags="--static" --extra-cflags="-I/source/ffmpeg/ffmpeg_build/include" \
--extra-ldflags="-L/source/ffmpeg/ffmpeg_build/lib" --bindir="/source/ffmpeg" --enable-gpl --enable-libturing && \
make
More information about the ffmpeg-devel
mailing list