Commit afff3a98 authored by Josh Holmer's avatar Josh Holmer

Merge branch 'rav1e-image-fixes' into 'master'

Various updates for rav1e Docker image

See merge request !1
parents a46d9d48 554617a9
Pipeline #1224 passed with stage
in 15 minutes and 22 seconds
Rust rav1e image: variables:
# Workaround a bug in Gitlab CI
DOCKER_TLS_CERTDIR: ""
Docker build:
stage: build
tags:
- dind
- privileged
variables:
IMAGE_TAG: '1.37'
services:
- docker:dind
script:
- docker build ./rust-rav1e --build-arg IMAGE_TAG=$IMAGE_TAG
only:
- merge_requests
Latest stable Rust:
stage: build
tags:
- dind
- privileged
variables:
IMAGE_TAG: '1.37'
services:
- docker:dind
script:
- docker build -t $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG ./rust-rav1e --build-arg IMAGE_TAG=$IMAGE_TAG
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
- docker push $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG
only:
- master
Minimum supported Rust:
stage: build stage: build
tags: tags:
- dind - dind
...@@ -8,7 +42,7 @@ Rust rav1e image: ...@@ -8,7 +42,7 @@ Rust rav1e image:
services: services:
- docker:dind - docker:dind
script: script:
- docker build -t $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG ./rust-rav1e - docker build -t $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG ./rust-rav1e --build-arg IMAGE_TAG=$IMAGE_TAG
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
- docker push $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG - docker push $CI_REGISTRY_IMAGE/rust-rav1e:$IMAGE_TAG
only: only:
......
FROM rust:1.36 ARG IMAGE_TAG
FROM rust:${IMAGE_TAG}-buster
ARG NASM_VERSION=2.14
ARG KCOV_VERSION=36
ARG AOM_VERSION=v1.0.0-errata1
ARG DAV1D_VERSION=0.4.0
RUN apt-get update -qq && \ RUN apt-get update -qq && \
apt-get install -qqy \ apt-get install -qqy --no-install-recommends \
autoconf \ autoconf \
automake \ automake \
autopoint \ autopoint \
gettext \ gettext \
libtool-bin \ libtool-bin \
bzip2 \ bzip2 \
flex \ flex \
make \ make \
gcc \ gcc \
g++ \ g++ \
g++-multilib \ g++-multilib \
git \ git \
gperf \ gperf \
patch \ patch \
pkg-config \ pkg-config \
sed \ sed \
unzip \ unzip \
wget \ wget \
lzip \ lzip \
xz-utils \ xz-utils \
cmake \ cmake \
ninja-build \ ninja-build \
libclang-dev \ libclang-dev \
clang \ clang \
libelf-dev \ libelf-dev \
libdw-dev \ libdw-dev \
libiberty-dev \ libiberty-dev \
binutils-dev binutils-dev \
RUN rustup component add clippy && \ meson && \
curl -L https://download.videolan.org/contrib/nasm/nasm-2.14.tar.gz | tar xvz && \ rm -rf /var/lib/apt/lists/*
cd nasm-2.14 && \ RUN curl -L "https://download.videolan.org/contrib/nasm/nasm-$NASM_VERSION.tar.gz" | tar xvz && \
cd "nasm-$NASM_VERSION" && \
./configure && make -j2 && make install && \ ./configure && make -j2 && make install && \
cd .. && \ cd .. && \
curl -L https://github.com/SimonKagstrom/kcov/archive/v36.tar.gz | tar xvz && \ rm -rf "nasm-$NASM_VERSION"
cd kcov-36 && \ RUN curl -L "https://github.com/SimonKagstrom/kcov/archive/v$KCOV_VERSION.tar.gz" | tar xvz && \
cd "kcov-$KCOV_VERSION" && \
mkdir .build && cd .build && \ mkdir .build && cd .build && \
cmake -GNinja .. && \ cmake -GNinja .. && \
ninja && ninja install && \ ninja && ninja install && \
cd ../.. && \ cd ../.. && \
git clone --depth 1 -b v1.0.0-errata1 https://aomedia.googlesource.com/aom && \ rm -rf "kcov-$KCOV_VERSION"
RUN git clone --depth 1 -b "$AOM_VERSION" https://aomedia.googlesource.com/aom && \
cd aom && \ cd aom && \
mkdir -p .build && cd .build && \ mkdir -p .build && cd .build && \
cmake -GNinja .. \ cmake -GNinja .. \
-DCMAKE_BUILD_TYPE=Release \ -DCMAKE_BUILD_TYPE=Release \
-DENABLE_TESTS=0 \ -DENABLE_TESTS=0 \
-DENABLE_DOCS=0 \ -DENABLE_DOCS=0 \
-DCONFIG_LOWBITDEPTH=1 \ -DCONFIG_LOWBITDEPTH=1 \
-DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_PREFIX=/usr \
-DCONFIG_PIC=1 && \ -DCONFIG_PIC=1 && \
ninja && ninja install ninja && ninja install && \
cd ../.. && \
rm -rf aom
RUN curl -L "https://code.videolan.org/videolan/dav1d/-/archive/$DAV1D_VERSION/dav1d-$DAV1D_VERSION.tar.gz" | tar xvz && \
cd "dav1d-$DAV1D_VERSION" && \
meson build --buildtype release && \
ninja -C build install && \
cd ../.. && \
rm -rf "dav1d-$DAV1D_VERSION"
RUN rustup component add clippy rustfmt
RUN cargo install cargo-kcov
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment