Created
January 6, 2026 16:49
-
-
Save nubzzz/003ded4acfff267dd3aa4e1a3852a2f9 to your computer and use it in GitHub Desktop.
FFmpeg 7.1.2 build
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # ffmpeg - http://ffmpeg.org/download.html | |
| # | |
| # From https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu | |
| # | |
| # From https://hub.docker.com/r/jrottenberg/ffmpeg/ | |
| ARG RELEASE=software | |
| FROM ubuntu:22.04 AS base | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| WORKDIR /tmp/workdir | |
| RUN apt-get -yqq update && apt-get install -yq --no-install-recommends ca-certificates software-properties-common curl wget | |
| ARG INTEL_GFX_GPG_URL="https://repositories.intel.com/gpu/intel-graphics.key" | |
| ARG INTEL_GFX_DISTRIBUTION=jammy | |
| ARG INTEL_GFX_FLAVOR=unified | |
| ARG INTEL_GFX_APT_REPO="deb https://repositories.intel.com/gpu/ubuntu $INTEL_GFX_DISTRIBUTION $INTEL_GFX_FLAVOR" | |
| ARG AMD_ROCM_GPG="https://repo.radeon.com/rocm/rocm.gpg.key" | |
| ARG AMD_ROCM_DISTRIBUTION=jammy | |
| ARG AMD_ROCM_FLAVOR=main | |
| ARG AMD_ROCM_VERSION=6.4.3 | |
| ARG AMD_ROCM_APT_REPO="deb https://repo.radeon.com/rocm/apt/$AMD_ROCM_VERSION $AMD_ROCM_DISTRIBUTION $AMD_ROCM_FLAVOR" | |
| ARG CUDA_KEYRING_VERSION=1.1-1 | |
| ## INTEL repo install | |
| RUN \ | |
| if [ -n "$INTEL_GFX_GPG_URL" ]; then \ | |
| local_key=/usr/share/keyrings/intel-gfx.gpg && \ | |
| curl -s $INTEL_GFX_GPG_URL | gpg --dearmor | tee $local_key >/dev/null && \ | |
| repo=$(echo $INTEL_GFX_APT_REPO | sed "s@deb @deb [signed-by=$local_key] @") && \ | |
| echo "$repo" >> /etc/apt/sources.list; \ | |
| else \ | |
| echo "$INTEL_GFX_APT_REPO" >> /etc/apt/sources.list; \ | |
| fi | |
| ## AMD ROCM repo install | |
| RUN \ | |
| if [ -n "$AMD_ROCM_GPG" ]; then \ | |
| local_key=/usr/share/keyrings/rocm.gpg && \ | |
| curl -s $AMD_ROCM_GPG | gpg --dearmor | tee $local_key >/dev/null && \ | |
| repo=$(echo $AMD_ROCM_APT_REPO | sed "s@deb @deb [arch=amd64 signed-by=$local_key] @") && \ | |
| echo "$repo" >> /etc/apt/sources.list; \ | |
| else \ | |
| echo "$AMD_ROCM_APT_REPO" >> /etc/apt/sources.list; \ | |
| fi | |
| ## NVIDIA CUDA repo install | |
| RUN \ | |
| wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_${CUDA_KEYRING_VERSION}_all.deb && \ | |
| dpkg -i cuda-keyring_${CUDA_KEYRING_VERSION}_all.deb && \ | |
| apt-get -yqq update && \ | |
| rm cuda-keyring_${CUDA_KEYRING_VERSION}_all.deb | |
| FROM base AS build | |
| ENV SRC=/usr/local | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| ARG MAKEFLAGS="-j16" | |
| ARG PKG_CONFIG_PATH="/opt/ffmpeg/share/pkgconfig:/opt/ffmpeg/lib/pkgconfig:/opt/ffmpeg/lib/x86_64-linux-gnu/pkgconfig" | |
| ARG PREFIX="/opt/ffmpeg" | |
| ARG LD_LIBRARY_PATH="/opt/ffmpeg/lib:/opt/ffmpeg/lib64" | |
| RUN \ | |
| buildDeps="\ | |
| autoconf \ | |
| automake \ | |
| bzip2 \ | |
| cmake \ | |
| cuda-toolkit \ | |
| expat \ | |
| g++ \ | |
| gcc \ | |
| git \ | |
| gperf \ | |
| libdrm-dev \ | |
| libexpat1-dev \ | |
| libgomp1 \ | |
| libharfbuzz-bin \ | |
| libharfbuzz-dev \ | |
| libssl-dev \ | |
| libtheora-dev \ | |
| libtool \ | |
| libva-dev \ | |
| libvpl-dev \ | |
| libvpl2 \ | |
| make \ | |
| meson \ | |
| nasm \ | |
| patch \ | |
| perl \ | |
| pkg-config \ | |
| xz-utils \ | |
| yasm \ | |
| zlib1g-dev \ | |
| " && \ | |
| apt-get -yqq update && \ | |
| apt-get install -yq --no-install-recommends ${buildDeps} && \ | |
| apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* | |
| ## Install Rust | |
| ARG RUST_VERSION=1.90.0 | |
| RUN \ | |
| DIR=/tmp/rust && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://static.rust-lang.org/dist/rust-${RUST_VERSION}-x86_64-unknown-linux-gnu.tar.xz | \ | |
| tar -xJ --strip-components=1 && \ | |
| ./install.sh && \ | |
| rm -rf ${DIR} | |
| ## libvmaf https://github.com/Netflix/vmaf | |
| ARG LIBVMAF_VERSION=2.1.1 | |
| RUN \ | |
| if which meson || false; then \ | |
| echo "Building VMAF." && \ | |
| DIR=/tmp/vmaf && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/Netflix/vmaf/archive/v${LIBVMAF_VERSION}.tar.gz && \ | |
| tar -xz --strip-components=1 -f v${LIBVMAF_VERSION}.tar.gz && \ | |
| cd /tmp/vmaf/libvmaf && \ | |
| meson build --buildtype release --prefix=${PREFIX} && \ | |
| ninja -vC build && \ | |
| ninja -vC build install && \ | |
| mkdir -p ${PREFIX}/share/model/ && \ | |
| cp -r /tmp/vmaf/model/* ${PREFIX}/share/model/ && \ | |
| rm -rf ${DIR}; \ | |
| else \ | |
| echo "VMAF skipped."; \ | |
| fi | |
| ## opencore-amr https://sourceforge.net/projects/opencore-amr/ | |
| ARG OPENCOREAMR_VERSION=0.1.5 | |
| RUN \ | |
| DIR=/tmp/opencore-amr && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://sourceforge.net/projects/opencore-amr/files/opencore-amr/opencore-amr-${OPENCOREAMR_VERSION}.tar.gz/download | \ | |
| tar -zx --strip-components=1 && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## x264 http://www.videolan.org/developers/x264.html | |
| ARG X264_VERSION=20191217-2245-stable | |
| RUN \ | |
| DIR=/tmp/x264 && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://download.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-${X264_VERSION}.tar.bz2 | \ | |
| tar -jx --strip-components=1 && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared --enable-pic --disable-cli && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## x265 http://x265.org/ | |
| ARG X265_VERSION=3.4 | |
| RUN \ | |
| DIR=/tmp/x265 && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/videolan/x265/archive/refs/tags/${X265_VERSION}.tar.gz | \ | |
| tar -zx && \ | |
| cd x265-${X265_VERSION}/build/linux && \ | |
| sed -i "/-DEXTRA_LIB/ s/$/ -DCMAKE_INSTALL_PREFIX=\${PREFIX}/" multilib.sh && \ | |
| sed -i "/^cmake/ s/$/ -DENABLE_CLI=OFF/" multilib.sh && \ | |
| ./multilib.sh && \ | |
| make -C 8bit install && \ | |
| rm -rf ${DIR} | |
| ## SVT-AV1 https://gitlab.com/AOMediaCodec/SVT-AV1 | |
| ARG LIBSVTAV1_VERSION=3.1.0 | |
| RUN \ | |
| DIR=/tmp/svt-av1 && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v${LIBSVTAV1_VERSION}/SVT-AV1-v${LIBSVTAV1_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| cd Build && \ | |
| cmake .. -G"Unix Makefiles" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${PREFIX} && \ | |
| make -j $(nproc) && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libogg https://www.xiph.org/ogg/ | |
| ARG OGG_VERSION=1.3.2 | |
| ARG OGG_SHA256SUM="e19ee34711d7af328cb26287f4137e70630e7261b17cbe3cd41011d73a654692 libogg-1.3.2.tar.gz" | |
| RUN \ | |
| DIR=/tmp/ogg && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO http://downloads.xiph.org/releases/ogg/libogg-${OGG_VERSION}.tar.gz && \ | |
| echo ${OGG_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f libogg-${OGG_VERSION}.tar.gz && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libopus https://www.opus-codec.org/ | |
| ARG OPUS_VERSION=1.2 | |
| ARG OPUS_SHA256SUM="77db45a87b51578fbc49555ef1b10926179861d854eb2613207dc79d9ec0a9a9 opus-1.2.tar.gz" | |
| RUN \ | |
| DIR=/tmp/opus && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://archive.mozilla.org/pub/opus/opus-${OPUS_VERSION}.tar.gz && \ | |
| echo ${OPUS_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f opus-${OPUS_VERSION}.tar.gz && \ | |
| autoreconf -fiv && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libvorbis https://xiph.org/vorbis/ | |
| ARG VORBIS_VERSION=1.3.5 | |
| ARG VORBIS_SHA256SUM="6efbcecdd3e5dfbf090341b485da9d176eb250d893e3eb378c428a2db38301ce libvorbis-1.3.5.tar.gz" | |
| RUN \ | |
| DIR=/tmp/vorbis && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO http://downloads.xiph.org/releases/vorbis/libvorbis-${VORBIS_VERSION}.tar.gz && \ | |
| echo ${VORBIS_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f libvorbis-${VORBIS_VERSION}.tar.gz && \ | |
| ./configure --prefix="${PREFIX}" --with-ogg="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libvpx https://www.webmproject.org/code/ | |
| ARG VPX_VERSION=1.14.1 | |
| RUN \ | |
| DIR=/tmp/vpx && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://codeload.github.com/webmproject/libvpx/tar.gz/v${VPX_VERSION} | \ | |
| tar -zx --strip-components=1 && \ | |
| ./configure --prefix="${PREFIX}" --enable-vp8 --enable-vp9 --enable-vp9-highbitdepth --enable-pic --enable-shared \ | |
| --disable-debug --disable-examples --disable-docs --disable-install-bins && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libwebp https://developers.google.com/speed/webp/ | |
| ARG WEBP_VERSION=1.4.0 | |
| RUN \ | |
| DIR=/tmp/webp && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-${WEBP_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libmp3lame http://lame.sourceforge.net/ | |
| ARG LAME_VERSION=3.100 | |
| RUN \ | |
| DIR=/tmp/lame && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://sourceforge.net/projects/lame/files/lame/${LAME_VERSION}/lame-${LAME_VERSION}.tar.gz/download | \ | |
| tar -zx --strip-components=1 && \ | |
| ./configure --prefix="${PREFIX}" --bindir="${PREFIX}/bin" --enable-shared --enable-nasm --disable-frontend && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## xvid https://www.xvid.com/ | |
| ARG XVID_VERSION=1.3.4 | |
| ARG XVID_SHA256SUM="4e9fd62728885855bc5007fe1be58df42e5e274497591fec37249e1052ae316f xvidcore-1.3.4.tar.gz" | |
| RUN \ | |
| DIR=/tmp/xvid && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO http://downloads.xvid.org/downloads/xvidcore-${XVID_VERSION}.tar.gz && \ | |
| echo ${XVID_SHA256SUM} | sha256sum --check && \ | |
| tar -zx -f xvidcore-${XVID_VERSION}.tar.gz && \ | |
| cd xvidcore/build/generic && \ | |
| ./configure --prefix="${PREFIX}" --bindir="${PREFIX}/bin" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## fdk-aac https://github.com/mstorsjo/fdk-aac | |
| ARG FDKAAC_VERSION=0.1.6 | |
| RUN \ | |
| DIR=/tmp/fdk-aac && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/mstorsjo/fdk-aac/archive/v${FDKAAC_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| autoreconf -fiv && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared --datadir="${DIR}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## openjpeg https://github.com/uclouvain/openjpeg | |
| ARG OPENJPEG_VERSION=2.1.2 | |
| RUN \ | |
| DIR=/tmp/openjpeg && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/uclouvain/openjpeg/archive/v${OPENJPEG_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| cmake -DBUILD_THIRDPARTY:BOOL=ON -DCMAKE_INSTALL_PREFIX="${PREFIX}" . && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## freetype https://www.freetype.org/ | |
| ARG FREETYPE_VERSION=2.10.4 | |
| ARG FREETYPE_SHA256SUM="5eab795ebb23ac77001cfb68b7d4d50b5d6c7469247b0b01b2c953269f658dac freetype-2.10.4.tar.gz" | |
| RUN \ | |
| DIR=/tmp/freetype && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://download.savannah.gnu.org/releases/freetype/freetype-${FREETYPE_VERSION}.tar.gz && \ | |
| echo ${FREETYPE_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f freetype-${FREETYPE_VERSION}.tar.gz && \ | |
| ./configure --prefix="${PREFIX}" --disable-static --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libvstab https://github.com/georgmartius/vid.stab | |
| ARG LIBVIDSTAB_VERSION=1.1.0 | |
| ARG LIBVIDSTAB_SHA256SUM="14d2a053e56edad4f397be0cb3ef8eb1ec3150404ce99a426c4eb641861dc0bb v1.1.0.tar.gz" | |
| RUN \ | |
| DIR=/tmp/vid.stab && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/georgmartius/vid.stab/archive/v${LIBVIDSTAB_VERSION}.tar.gz && \ | |
| echo ${LIBVIDSTAB_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f v${LIBVIDSTAB_VERSION}.tar.gz && \ | |
| cmake -DCMAKE_INSTALL_PREFIX="${PREFIX}" . && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## fridibi https://www.fribidi.org/ | |
| ARG FRIBIDI_VERSION=0.19.7 | |
| ARG FRIBIDI_SHA256SUM="3fc96fa9473bd31dcb5500bdf1aa78b337ba13eb8c301e7c28923fea982453a8 0.19.7.tar.gz" | |
| RUN \ | |
| DIR=/tmp/fribidi && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/fribidi/fribidi/archive/${FRIBIDI_VERSION}.tar.gz && \ | |
| echo ${FRIBIDI_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f ${FRIBIDI_VERSION}.tar.gz && \ | |
| sed -i 's/^SUBDIRS =.*/SUBDIRS=gen.tab charset lib bin/' Makefile.am && \ | |
| ./bootstrap --no-config --auto && \ | |
| ./configure --prefix="${PREFIX}" --disable-static --enable-shared && \ | |
| make -j1 && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## fontconfig https://www.freedesktop.org/wiki/Software/fontconfig/ | |
| ARG FONTCONFIG_VERSION=2.12.4 | |
| RUN \ | |
| DIR=/tmp/fontconfig && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://www.freedesktop.org/software/fontconfig/release/fontconfig-${FONTCONFIG_VERSION}.tar.bz2 && \ | |
| tar -jx --strip-components=1 -f fontconfig-${FONTCONFIG_VERSION}.tar.bz2 && \ | |
| ./configure --prefix="${PREFIX}" --disable-static --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libass https://github.com/libass/libass | |
| ARG LIBASS_VERSION=0.17.3 | |
| ARG LIBASS_SHA256SUM="26fbfb7a7bd3e6d5c713f8a65a12b36084d1dde6efaed8a9996489054c4aeca0 0.17.3.tar.gz" | |
| RUN \ | |
| DIR=/tmp/libass && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/libass/libass/archive/refs/tags/${LIBASS_VERSION}.tar.gz && \ | |
| echo ${LIBASS_SHA256SUM} | sha256sum --check && \ | |
| tar -zx --strip-components=1 -f ${LIBASS_VERSION}.tar.gz && \ | |
| ./autogen.sh && \ | |
| ./configure --prefix="${PREFIX}" --disable-static --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## kvazaar https://github.com/ultravideo/kvazaar | |
| ARG KVAZAAR_VERSION=2.0.0 | |
| RUN \ | |
| DIR=/tmp/kvazaar && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/ultravideo/kvazaar/archive/v${KVAZAAR_VERSION}.tar.gz && \ | |
| tar -zx --strip-components=1 -f v${KVAZAAR_VERSION}.tar.gz && \ | |
| ./autogen.sh && \ | |
| ./configure --prefix="${PREFIX}" --disable-static --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libaom https://aomedia.googlesource.com/aom | |
| ARG AOM_VERSION=v3.8.3 | |
| RUN \ | |
| DIR=/tmp/aom && \ | |
| git clone --depth 1 --branch ${AOM_VERSION} https://aomedia.googlesource.com/aom ${DIR} ; \ | |
| cd ${DIR} ; \ | |
| rm -rf CMakeCache.txt CMakeFiles ; \ | |
| mkdir -p ./aom_build ; \ | |
| cd ./aom_build ; \ | |
| cmake -DCMAKE_INSTALL_PREFIX="${PREFIX}" -DBUILD_SHARED_LIBS=1 ..; \ | |
| make ; \ | |
| make install ; \ | |
| rm -rf ${DIR} | |
| ## libxcb (and supporting libraries) for screen capture https://xcb.freedesktop.org/ | |
| ARG XORG_MACROS_VERSION=1.19.2 | |
| RUN \ | |
| DIR=/tmp/xorg-macros && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://www.x.org/archive//individual/util/util-macros-${XORG_MACROS_VERSION}.tar.gz && \ | |
| tar -zx --strip-components=1 -f util-macros-${XORG_MACROS_VERSION}.tar.gz && \ | |
| ./configure --srcdir=${DIR} --prefix="${PREFIX}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## xproto | |
| ARG XPROTO_VERSION=7.0.31 | |
| RUN \ | |
| DIR=/tmp/xproto && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://www.x.org/archive/individual/proto/xproto-${XPROTO_VERSION}.tar.gz && \ | |
| tar -zx --strip-components=1 -f xproto-${XPROTO_VERSION}.tar.gz && \ | |
| ./configure --srcdir=${DIR} --prefix="${PREFIX}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## xau | |
| ARG XAU_VERSION=1.0.11 | |
| RUN \ | |
| DIR=/tmp/libXau && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://www.x.org/archive/individual/lib/libXau-${XAU_VERSION}.tar.gz && \ | |
| tar -zx --strip-components=1 -f libXau-${XAU_VERSION}.tar.gz && \ | |
| ./configure --srcdir=${DIR} --prefix="${PREFIX}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libpthread | |
| ARG LIBPTHREAD_STUBS_VERSION=0.4 | |
| RUN \ | |
| DIR=/tmp/libpthread-stubs && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://xcb.freedesktop.org/dist/libpthread-stubs-${LIBPTHREAD_STUBS_VERSION}.tar.gz && \ | |
| tar -zx --strip-components=1 -f libpthread-stubs-${LIBPTHREAD_STUBS_VERSION}.tar.gz && \ | |
| ./configure --prefix="${PREFIX}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libxml2 - for libbluray | |
| ARG LIBXML2_VERSION=2.9.12 | |
| RUN \ | |
| DIR=/tmp/libxml2 && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/GNOME/libxml2/archive/refs/tags/v${LIBXML2_VERSION}.tar.gz | \ | |
| tar -xz --strip-components=1 && \ | |
| ./autogen.sh --prefix="${PREFIX}" --with-ftp=no --with-http=no --with-python=no && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libbluray - Requires libxml, freetype, and fontconfig | |
| ARG LIBBLURAY_VERSION=1.1.2 | |
| ARG LIBBLURAY_SHA256SUM="a3dd452239b100dc9da0d01b30e1692693e2a332a7d29917bf84bb10ea7c0b42 libbluray-1.1.2.tar.bz2" | |
| RUN \ | |
| DIR=/tmp/libbluray && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://download.videolan.org/pub/videolan/libbluray/${LIBBLURAY_VERSION}/libbluray-${LIBBLURAY_VERSION}.tar.bz2 && \ | |
| echo ${LIBBLURAY_SHA256SUM} | sha256sum --check && \ | |
| tar -jx --strip-components=1 -f libbluray-${LIBBLURAY_VERSION}.tar.bz2 && \ | |
| ./configure --prefix="${PREFIX}" --disable-examples --disable-bdjava-jar --disable-static --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libzmq https://github.com/zeromq/libzmq/ | |
| ARG LIBZMQ_VERSION=4.3.2 | |
| ARG LIBZMQ_SHA256SUM="02ecc88466ae38cf2c8d79f09cfd2675ba299a439680b64ade733e26a349edeb v4.3.2.tar.gz" | |
| RUN \ | |
| DIR=/tmp/libzmq && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/zeromq/libzmq/archive/v${LIBZMQ_VERSION}.tar.gz && \ | |
| echo ${LIBZMQ_SHA256SUM} | sha256sum --check && \ | |
| tar -xz --strip-components=1 -f v${LIBZMQ_VERSION}.tar.gz && \ | |
| ./autogen.sh && \ | |
| ./configure --prefix="${PREFIX}" && \ | |
| make && \ | |
| make check && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libsrt https://github.com/Haivision/srt | |
| ARG LIBSRT_VERSION=1.4.1 | |
| RUN \ | |
| DIR=/tmp/srt && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/Haivision/srt/archive/v${LIBSRT_VERSION}.tar.gz && \ | |
| tar -xz --strip-components=1 -f v${LIBSRT_VERSION}.tar.gz && \ | |
| cmake -DCMAKE_INSTALL_PREFIX="${PREFIX}" . && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libpng | |
| ARG LIBPNG_VERSION=1.6.9 | |
| RUN \ | |
| DIR=/tmp/png && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| git clone --depth 1 --branch v${LIBPNG_VERSION} https://git.code.sf.net/p/libpng/code ${DIR} && \ | |
| ./autogen.sh && \ | |
| ./configure --prefix="${PREFIX}" && \ | |
| make check && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## libaribb24 | |
| ARG LIBARIBB24_VERSION=1.0.3 | |
| ARG LIBARIBB24_SHA256SUM="f61560738926e57f9173510389634d8c06cabedfa857db4b28fb7704707ff128 v1.0.3.tar.gz" | |
| RUN \ | |
| DIR=/tmp/b24 && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/nkoriyama/aribb24/archive/v${LIBARIBB24_VERSION}.tar.gz && \ | |
| echo ${LIBARIBB24_SHA256SUM} | sha256sum --check && \ | |
| tar -xz --strip-components=1 -f v${LIBARIBB24_VERSION}.tar.gz && \ | |
| autoreconf -fiv && \ | |
| ./configure CFLAGS="-I${PREFIX}/include -fPIC" --prefix="${PREFIX}" && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## zimg https://github.com/sekrit-twc/zimg | |
| ARG ZIMG_VERSION=3.0.5 | |
| RUN \ | |
| DIR=/tmp/zimg && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/sekrit-twc/zimg/archive/refs/tags/release-${ZIMG_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| ./autogen.sh && \ | |
| ./configure --prefix="${PREFIX}" --enable-shared && \ | |
| make && \ | |
| make install && \ | |
| rm -rf ${DIR} | |
| ## dav1d | |
| ARG DAV1D_VERSION=1.4.3 | |
| ARG DAV1D_REPO=https://github.com/videolan/dav1d/archive/refs/tags/${DAV1D_VERSION}.tar.gz | |
| RUN \ | |
| DIR=/tmp/dav1d && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL ${DAV1D_REPO} | tar -zx --strip-components=1 && \ | |
| meson build --prefix="${PREFIX}" --buildtype=plain && \ | |
| ninja -vC build && \ | |
| ninja -vC build install && \ | |
| rm -rf ${DIR} | |
| ## rav1e https://github.com/xiph/rav1e | |
| ARG RAV1E_VERSION=0.8.1 | |
| RUN \ | |
| DIR=/tmp/rav1e && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sL https://github.com/xiph/rav1e/archive/refs/tags/v${RAV1E_VERSION}.tar.gz | \ | |
| tar -zx --strip-components=1 && \ | |
| cargo install cargo-c && \ | |
| cargo cinstall --release --prefix=${PREFIX} && \ | |
| rm -rf ${DIR} | |
| ## NVENC BUILD | |
| FROM build AS build-nvenc | |
| ## Nvidia Codec Headers (https://medium.com/@multi.flexi/how-to-get-info-about-nvdec-and-nvenc-capabilities-of-your-gpu-6ecc9a5d4dac) | |
| ARG NVIDIA_HEADERS_VERSION=n12.1.14.0 | |
| RUN \ | |
| DIR=/tmp/nv-codec-headers && \ | |
| git clone --depth 1 --branch ${NVIDIA_HEADERS_VERSION} https://github.com/FFmpeg/nv-codec-headers ${DIR} && \ | |
| cd ${DIR} && \ | |
| make PREFIX="${PREFIX}" && \ | |
| make install PREFIX="${PREFIX}" && \ | |
| rm -rf ${DIR} | |
| ## Nvidia video info tool (Needed for media) | |
| RUN \ | |
| DIR=/tmp/nv-video-info && \ | |
| git clone --depth 1 https://github.com/philipl/nv-video-info.git ${DIR} && \ | |
| cd ${DIR} && \ | |
| gcc nvencinfo.c -I${PREFIX}/include -ldl -o nvencinfo && \ | |
| mv nvencinfo /usr/local/bin/ && \ | |
| rm -rf ${DIR} | |
| ## Build ffmpeg https://ffmpeg.org/ | |
| ARG FFMPEG_VERSION=n7.1.2 | |
| RUN \ | |
| DIR=/tmp/ffmpeg && \ | |
| git clone --depth 1 --branch ${FFMPEG_VERSION} https://github.com/ffmpeg/ffmpeg ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl https://gitlab.com/AOMediaCodec/SVT-AV1/-/raw/master/.gitlab/workflows/linux/ffmpeg_n7_fix.patch -o ffmpeg_n7_fix.patch && \ | |
| patch --ignore-whitespace --fuzz 3 libavcodec/libsvtav1.c ffmpeg_n7_fix.patch && \ | |
| ./configure \ | |
| --disable-debug \ | |
| --disable-doc \ | |
| --disable-ffplay \ | |
| --disable-static \ | |
| --enable-cuda \ | |
| --enable-cuvid \ | |
| --enable-nvenc \ | |
| --enable-fontconfig \ | |
| --enable-gpl \ | |
| --enable-libaom \ | |
| --enable-libaribb24 \ | |
| --enable-libass \ | |
| --enable-libbluray \ | |
| --enable-libdav1d \ | |
| --enable-libfdk_aac \ | |
| --enable-libfreetype \ | |
| --enable-libkvazaar \ | |
| --enable-libmp3lame \ | |
| --enable-libopencore-amrnb \ | |
| --enable-libopencore-amrwb \ | |
| --enable-libopenjpeg \ | |
| --enable-libopus \ | |
| --enable-librav1e \ | |
| --enable-libsrt \ | |
| --enable-libsvtav1 \ | |
| --enable-libtheora \ | |
| --enable-libvidstab \ | |
| --enable-libvmaf \ | |
| --enable-libvorbis \ | |
| --enable-libvpx \ | |
| --enable-libwebp \ | |
| --enable-libx264 \ | |
| --enable-libx265 \ | |
| --enable-libxvid \ | |
| --enable-libzimg \ | |
| --enable-libzmq \ | |
| --enable-nonfree \ | |
| --enable-openssl \ | |
| --enable-postproc \ | |
| --enable-shared \ | |
| --enable-small \ | |
| --enable-version3 \ | |
| --extra-cflags="-I${PREFIX}/include -I${PREFIX}/include/ffnvcodec -I/usr/local/cuda/include/" \ | |
| --extra-ldflags="-L${PREFIX}/lib -L/usr/local/cuda/lib64 -L/usr/local/cuda/lib" \ | |
| --extra-libs=-ldl \ | |
| --extra-libs=-lpthread \ | |
| --prefix="${PREFIX}" && \ | |
| make -j $(nproc --all) && \ | |
| make install && \ | |
| make tools/zmqsend && cp tools/zmqsend ${PREFIX}/bin/ && \ | |
| make distclean && \ | |
| hash -r && \ | |
| cd tools && \ | |
| make qt-faststart && cp qt-faststart ${PREFIX}/bin/ | |
| ## Library bullshit | |
| RUN \ | |
| ldd ${PREFIX}/bin/ffmpeg | grep opt/ffmpeg | cut -d ' ' -f 3 | xargs -i cp {} /usr/local/lib/ && \ | |
| cp /usr/lib/x86_64-linux-gnu/libvpl.so* /usr/local/lib && \ | |
| for lib in ${PREFIX}/lib/x86_64-linux-gnu/*.so.*; do cp $lib /usr/local/lib/; done && \ | |
| for lib in /usr/local/lib/*.so.*; do ln -s "${lib##*/}" "${lib%%.so.*}".so; done && \ | |
| cp ${PREFIX}/bin/* /usr/local/bin/ && \ | |
| cp -r ${PREFIX}/share/ffmpeg /usr/local/share/ && \ | |
| LD_LIBRARY_PATH=/usr/local/lib ffmpeg -buildconf && \ | |
| cp -r ${PREFIX}/include/libav* ${PREFIX}/include/libpostproc ${PREFIX}/include/libsw* /usr/local/include && \ | |
| mkdir -p /usr/local/lib/pkgconfig && \ | |
| for pc in ${PREFIX}/lib/pkgconfig/libav*.pc ${PREFIX}/lib/pkgconfig/libpostproc.pc ${PREFIX}/lib/pkgconfig/libsw*.pc; do \ | |
| sed "s:${PREFIX}:/usr/local:g" <"$pc" >/usr/local/lib/pkgconfig/"${pc##*/}"; \ | |
| done | |
| ## VAAPI BUILD | |
| FROM build AS build-vaapi | |
| ## AMF https://github.com/GPUOpen-LibrariesAndSDKs/AMF | |
| ARG AMF_VERSION=v1.4.36 | |
| RUN \ | |
| DIR=/tmp/amf && \ | |
| mkdir -p ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl -sLO https://github.com/GPUOpen-LibrariesAndSDKs/AMF/releases/download/${AMF_VERSION}/AMF-headers-${AMF_VERSION}.tar.gz && \ | |
| tar -xz --strip-components=1 -f AMF-headers-${AMF_VERSION}.tar.gz && \ | |
| mv AMF /usr/local/include/AMF && \ | |
| rm -rf ${DIR} | |
| ## Build ffmpeg https://ffmpeg.org/ | |
| ARG FFMPEG_VERSION=n7.1.2 | |
| RUN \ | |
| DIR=/tmp/ffmpeg && \ | |
| git clone --depth 1 --branch ${FFMPEG_VERSION} https://github.com/ffmpeg/ffmpeg ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl https://gitlab.com/AOMediaCodec/SVT-AV1/-/raw/master/.gitlab/workflows/linux/ffmpeg_n7_fix.patch -o ffmpeg_n7_fix.patch && \ | |
| patch --ignore-whitespace --fuzz 3 libavcodec/libsvtav1.c ffmpeg_n7_fix.patch && \ | |
| ./configure \ | |
| --disable-debug \ | |
| --disable-doc \ | |
| --disable-ffplay \ | |
| --disable-static \ | |
| --enable-amf \ | |
| --enable-fontconfig \ | |
| --enable-gpl \ | |
| --enable-libaom \ | |
| --enable-libaribb24 \ | |
| --enable-libass \ | |
| --enable-libbluray \ | |
| --enable-libdav1d \ | |
| --enable-libfdk_aac \ | |
| --enable-libfreetype \ | |
| --enable-libkvazaar \ | |
| --enable-libmp3lame \ | |
| --enable-libopencore-amrnb \ | |
| --enable-libopencore-amrwb \ | |
| --enable-libopenjpeg \ | |
| --enable-libopus \ | |
| --enable-librav1e \ | |
| --enable-libsrt \ | |
| --enable-libsvtav1 \ | |
| --enable-libtheora \ | |
| --enable-libvidstab \ | |
| --enable-libvmaf \ | |
| --enable-libvorbis \ | |
| --enable-libvpx \ | |
| --enable-libvpl \ | |
| --enable-libwebp \ | |
| --enable-libx264 \ | |
| --enable-libx265 \ | |
| --enable-libxvid \ | |
| --enable-libzimg \ | |
| --enable-libzmq \ | |
| --enable-nonfree \ | |
| --enable-openssl \ | |
| --enable-postproc \ | |
| --enable-shared \ | |
| --enable-small \ | |
| --enable-vaapi \ | |
| --enable-version3 \ | |
| --extra-cflags="-I${PREFIX}/include" \ | |
| --extra-ldflags="-L${PREFIX}/lib" \ | |
| --extra-libs=-ldl \ | |
| --extra-libs=-lpthread \ | |
| --prefix="${PREFIX}" && \ | |
| make -j $(nproc --all) && \ | |
| make install && \ | |
| make tools/zmqsend && cp tools/zmqsend ${PREFIX}/bin/ && \ | |
| make distclean && \ | |
| hash -r && \ | |
| cd tools && \ | |
| make qt-faststart && cp qt-faststart ${PREFIX}/bin/ | |
| ## Library bullshit | |
| RUN \ | |
| ldd ${PREFIX}/bin/ffmpeg | grep opt/ffmpeg | cut -d ' ' -f 3 | xargs -i cp {} /usr/local/lib/ && \ | |
| cp /usr/lib/x86_64-linux-gnu/libvpl.so* /usr/local/lib && \ | |
| for lib in ${PREFIX}/lib/x86_64-linux-gnu/*.so.*; do cp $lib /usr/local/lib/; done && \ | |
| for lib in /usr/local/lib/*.so.*; do ln -s "${lib##*/}" "${lib%%.so.*}".so; done && \ | |
| cp ${PREFIX}/bin/* /usr/local/bin/ && \ | |
| cp -r ${PREFIX}/share/ffmpeg /usr/local/share/ && \ | |
| LD_LIBRARY_PATH=/usr/local/lib ffmpeg -buildconf && \ | |
| cp -r ${PREFIX}/include/libav* ${PREFIX}/include/libpostproc ${PREFIX}/include/libsw* /usr/local/include && \ | |
| mkdir -p /usr/local/lib/pkgconfig && \ | |
| for pc in ${PREFIX}/lib/pkgconfig/libav*.pc ${PREFIX}/lib/pkgconfig/libpostproc.pc ${PREFIX}/lib/pkgconfig/libsw*.pc; do \ | |
| sed "s:${PREFIX}:/usr/local:g" <"$pc" >/usr/local/lib/pkgconfig/"${pc##*/}"; \ | |
| done | |
| ## SOFTWARE BUILD | |
| FROM build AS build-software | |
| ## Build ffmpeg https://ffmpeg.org/ | |
| ARG FFMPEG_VERSION=n7.1.2 | |
| RUN \ | |
| DIR=/tmp/ffmpeg && \ | |
| git clone --depth 1 --branch ${FFMPEG_VERSION} https://github.com/ffmpeg/ffmpeg ${DIR} && \ | |
| cd ${DIR} && \ | |
| curl https://gitlab.com/AOMediaCodec/SVT-AV1/-/raw/master/.gitlab/workflows/linux/ffmpeg_n7_fix.patch -o ffmpeg_n7_fix.patch && \ | |
| patch --ignore-whitespace --fuzz 3 libavcodec/libsvtav1.c ffmpeg_n7_fix.patch && \ | |
| ./configure \ | |
| --disable-debug \ | |
| --disable-doc \ | |
| --disable-ffplay \ | |
| --disable-static \ | |
| --enable-fontconfig \ | |
| --enable-gpl \ | |
| --enable-libaom \ | |
| --enable-libaribb24 \ | |
| --enable-libass \ | |
| --enable-libbluray \ | |
| --enable-libdav1d \ | |
| --enable-libfdk_aac \ | |
| --enable-libfreetype \ | |
| --enable-libkvazaar \ | |
| --enable-libmp3lame \ | |
| --enable-libopencore-amrnb \ | |
| --enable-libopencore-amrwb \ | |
| --enable-libopenjpeg \ | |
| --enable-libopus \ | |
| --enable-librav1e \ | |
| --enable-libsrt \ | |
| --enable-libsvtav1 \ | |
| --enable-libtheora \ | |
| --enable-libvidstab \ | |
| --enable-libvmaf \ | |
| --enable-libvorbis \ | |
| --enable-libvpx \ | |
| --enable-libwebp \ | |
| --enable-libx264 \ | |
| --enable-libx265 \ | |
| --enable-libxvid \ | |
| --enable-libzimg \ | |
| --enable-libzmq \ | |
| --enable-nonfree \ | |
| --enable-openssl \ | |
| --enable-postproc \ | |
| --enable-shared \ | |
| --enable-small \ | |
| --enable-vaapi \ | |
| --enable-version3 \ | |
| --extra-cflags="-I${PREFIX}/include" \ | |
| --extra-ldflags="-L${PREFIX}/lib" \ | |
| --extra-libs=-ldl \ | |
| --extra-libs=-lpthread \ | |
| --prefix="${PREFIX}" && \ | |
| make -j $(nproc --all) && \ | |
| make install && \ | |
| make tools/zmqsend && cp tools/zmqsend ${PREFIX}/bin/ && \ | |
| make distclean && \ | |
| hash -r && \ | |
| cd tools && \ | |
| make qt-faststart && cp qt-faststart ${PREFIX}/bin/ | |
| ## Library bullshit | |
| RUN \ | |
| ldd ${PREFIX}/bin/ffmpeg | grep opt/ffmpeg | cut -d ' ' -f 3 | xargs -i cp {} /usr/local/lib/ && \ | |
| cp /usr/lib/x86_64-linux-gnu/libvpl.so* /usr/local/lib && \ | |
| for lib in ${PREFIX}/lib/x86_64-linux-gnu/*.so.*; do cp $lib /usr/local/lib/; done && \ | |
| for lib in /usr/local/lib/*.so.*; do ln -s "${lib##*/}" "${lib%%.so.*}".so; done && \ | |
| cp ${PREFIX}/bin/* /usr/local/bin/ && \ | |
| cp -r ${PREFIX}/share/ffmpeg /usr/local/share/ && \ | |
| LD_LIBRARY_PATH=/usr/local/lib ffmpeg -buildconf && \ | |
| cp -r ${PREFIX}/include/libav* ${PREFIX}/include/libpostproc ${PREFIX}/include/libsw* /usr/local/include && \ | |
| mkdir -p /usr/local/lib/pkgconfig && \ | |
| for pc in ${PREFIX}/lib/pkgconfig/libav*.pc ${PREFIX}/lib/pkgconfig/libpostproc.pc ${PREFIX}/lib/pkgconfig/libsw*.pc; do \ | |
| sed "s:${PREFIX}:/usr/local:g" <"$pc" >/usr/local/lib/pkgconfig/"${pc##*/}"; \ | |
| done | |
| FROM base AS release-nvenc | |
| WORKDIR /tmp/workdir | |
| ENV LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib64 | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| RUN \ | |
| runtimeDeps="\ | |
| clinfo \ | |
| cuda-compat-13-1 \ | |
| cuda-cudart-13-1 \ | |
| cuda-libraries-13-1 \ | |
| cuda-nvrtc-13-1 \ | |
| cuda-nvtx-13-1 \ | |
| cuda-opencl-13-1 \ | |
| cuda-toolkit-13-1-config-common \ | |
| cuda-toolkit-13-config-common \ | |
| cuda-toolkit-config-common \ | |
| expat \ | |
| libcufile-13-1 \ | |
| libcusolver-13-1 \ | |
| libgomp1 \ | |
| libglib2.0-0 \ | |
| libharfbuzz-dev \ | |
| libigfxcmrt7 \ | |
| libmfx-gen1 \ | |
| libtheora-dev \ | |
| libx264-163 \ | |
| libx265-199 \ | |
| libxcb-shm0 \ | |
| libxcb-shape0-dev \ | |
| linux-tools-generic \ | |
| mesa-va-drivers \ | |
| pciutils \ | |
| python3 \ | |
| python3-pip \ | |
| va-driver-all \ | |
| vainfo \ | |
| " && \ | |
| apt-get -yqq update && \ | |
| apt-get install -yq --no-install-recommends ${runtimeDeps} && \ | |
| apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* | |
| COPY --from=build-nvenc /usr/local/bin /usr/local/bin/ | |
| COPY --from=build-nvenc /usr/local/share /usr/local/share/ | |
| COPY --from=build-nvenc /usr/local/lib /usr/local/lib/ | |
| COPY --from=build-nvenc /usr/local/include /usr/local/include/ | |
| FROM base AS release-vaapi | |
| WORKDIR /tmp/workdir | |
| ENV LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib64 | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| RUN \ | |
| runtimeDeps="\ | |
| clinfo \ | |
| expat \ | |
| i965-va-driver \ | |
| intel-media-va-driver-non-free \ | |
| libgomp1 \ | |
| intel-opencl-icd \ | |
| libglib2.0-0 \ | |
| libharfbuzz-dev \ | |
| libigfxcmrt7 \ | |
| libmfx-gen1 \ | |
| libtheora-dev \ | |
| libva-drm2 \ | |
| libva2 \ | |
| libva-glx2 \ | |
| libvpl-tools \ | |
| libvpl2 \ | |
| libx264-163 \ | |
| libx265-199 \ | |
| libxcb-shm0 \ | |
| libxcb-shape0-dev \ | |
| linux-tools-generic \ | |
| mesa-va-drivers \ | |
| pciutils \ | |
| python3 \ | |
| python3-pip \ | |
| rocm-opencl-runtime \ | |
| va-driver-all \ | |
| vainfo \ | |
| " && \ | |
| apt-get -yqq update && \ | |
| apt-get install -yq --no-install-recommends ${runtimeDeps} && \ | |
| apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* | |
| COPY --from=build-vaapi /usr/local/bin /usr/local/bin/ | |
| COPY --from=build-vaapi /usr/local/share /usr/local/share/ | |
| COPY --from=build-vaapi /usr/local/lib /usr/local/lib/ | |
| COPY --from=build-vaapi /usr/local/include /usr/local/include/ | |
| FROM base AS release-software | |
| WORKDIR /tmp/workdir | |
| ENV LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib64 | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| RUN \ | |
| runtimeDeps="\ | |
| expat \ | |
| libgomp1 \ | |
| libglib2.0-0 \ | |
| libharfbuzz-dev \ | |
| libigfxcmrt7 \ | |
| libmfx-gen1 \ | |
| libtheora-dev \ | |
| libx264-163 \ | |
| libx265-199 \ | |
| libxcb-shm0 \ | |
| libxcb-shape0-dev \ | |
| linux-tools-generic \ | |
| python3 \ | |
| python3-pip \ | |
| " && \ | |
| apt-get -yqq update && \ | |
| apt-get install -yq --no-install-recommends ${runtimeDeps} && \ | |
| apt-get autoremove -y && apt-get clean -y && rm -rf /var/lib/apt/lists/* | |
| COPY --from=build-software /usr/local/bin /usr/local/bin/ | |
| COPY --from=build-software /usr/local/share /usr/local/share/ | |
| COPY --from=build-software /usr/local/lib /usr/local/lib/ | |
| COPY --from=build-software /usr/local/include /usr/local/include/ | |
| FROM release-${RELEASE} AS final | |
| CMD ["--help"] | |
| ENTRYPOINT ["ffmpeg"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment