From 4c9245737744d7749de9ab6537a19a201fda68dc Mon Sep 17 00:00:00 2001 From: James Ketrenos Date: Thu, 15 Jul 2021 12:22:00 -0700 Subject: [PATCH] Added centos solution Signed-off-by: James Ketrenos --- Dockerfile.solution.centos | 56 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 Dockerfile.solution.centos diff --git a/Dockerfile.solution.centos b/Dockerfile.solution.centos new file mode 100644 index 0000000..114e85d --- /dev/null +++ b/Dockerfile.solution.centos @@ -0,0 +1,56 @@ +# Docker.solution based on the Intel-Media-SDK instructions available here: +# +# https://github.com/Intel-Media-SDK/MediaSDK/wiki/Build-and-use-ffmpeg-with-MediaSDK +FROM xe-user-stage AS solution-build + +USER root + +# Install git and build tools, clone ffmpeg, and get ready to build it +RUN dnf groupinstall -y 'Development Tools' + +# Install all required common packages: +# Adapted from +RUN dnf install -y \ + libva-devel$LIBVA_DEV_VERSION \ + intel-mediasdk-devel$INTEL_MEDIASDK_DEVEL_VERSION \ + libva-utils$LIBVA_UTILS_VERSION + +USER user + +# Clone ffmpeg +# NOTE: This explicitly clones the FFMPEG_TAG_VERSION (see SOLUTIONS) +RUN git clone --depth 1 --branch $FFMPEG_TAG_VERSION https://github.com/ffmpeg/ffmpeg /home/user/ffmpeg + +# Build FFmpeg +WORKDIR /home/user/ffmpeg + +ENV LIBVA_DRIVER_NAME=iHD + +RUN ./configure --arch=x86_64 --disable-x86asm --enable-vaapi --enable-libmfx \ + && make -j $(nproc --all) \ + && sudo make install + +FROM xe-user-stage + +USER root + +# Update and install the Mesa, OpenCL, and Media from repositories.intel.com +# +# NOTE: libva requires libpciaccess0, however it doesn't depend on it +# so explicitly install it. +RUN dnf install -y \ + intel-media$INTEL_MEDIA_VERSION \ + libva$LIBVA_VERSION \ + intel-mediasdk$INTEL_MEDIASDK_VERSION \ + libva-utils$LIBVA_UTILS_VERSION \ + libpciaccess \ + pciutils + +# Copy ffmpeg and ffprobe from build container +COPY --from=solution-build /usr/local/bin/ /usr/local/bin/ + +RUN dnf clean all + +ENV LIBVA_DRIVER_NAME=iHD + +USER user