forked from mirrors/gstreamer-rs
windows: Install dav1d in the docker image
Also to be used in the gst-plugins-rs CI Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1084>
This commit is contained in:
parent
29bc304c88
commit
8ca9692924
3 changed files with 33 additions and 4 deletions
|
@ -1,4 +1,4 @@
|
||||||
variables:
|
variables:
|
||||||
GST_RS_IMG_TAG: '2022-08-23.2'
|
GST_RS_IMG_TAG: '2022-08-31.1'
|
||||||
GST_RS_STABLE: '1.63.0'
|
GST_RS_STABLE: '1.63.0'
|
||||||
GST_RS_MSRV: '1.60.0'
|
GST_RS_MSRV: '1.60.0'
|
||||||
|
|
|
@ -9,15 +9,16 @@ SHELL ["powershell","-NoLogo", "-NonInteractive", "-Command"]
|
||||||
ARG DEFAULT_BRANCH="main"
|
ARG DEFAULT_BRANCH="main"
|
||||||
ARG RUST_VERSION="invalid"
|
ARG RUST_VERSION="invalid"
|
||||||
|
|
||||||
RUN choco install -y pkgconfiglite
|
RUN choco install -y pkgconfiglite nasm llvm
|
||||||
|
|
||||||
# https://stackoverflow.com/a/50716450
|
# https://stackoverflow.com/a/50716450
|
||||||
RUN setx PATH '%PATH%;C:\gst-install\bin'
|
RUN setx PATH '%PATH%;C:\Program Files\NASM;C:\gst-install\bin'
|
||||||
ENV PKG_CONFIG_PATH="C:\gst-install\lib\pkgconfig"
|
ENV PKG_CONFIG_PATH="C:\gst-install\lib\pkgconfig"
|
||||||
|
|
||||||
COPY install_gst.ps1 install_gtk.ps1 C:\
|
COPY install_gst.ps1 install_gtk.ps1 install_dav1d.ps1 C:\
|
||||||
RUN C:\install_gst.ps1
|
RUN C:\install_gst.ps1
|
||||||
RUN C:\install_gtk.ps1
|
RUN C:\install_gtk.ps1
|
||||||
|
RUN C:\install_dav1d.ps1
|
||||||
|
|
||||||
RUN Invoke-WebRequest -Uri https://win.rustup.rs/x86_64 -OutFile C:\rustup-init.exe
|
RUN Invoke-WebRequest -Uri https://win.rustup.rs/x86_64 -OutFile C:\rustup-init.exe
|
||||||
RUN C:\rustup-init.exe -y --profile minimal --default-toolchain $env:RUST_VERSION
|
RUN C:\rustup-init.exe -y --profile minimal --default-toolchain $env:RUST_VERSION
|
||||||
|
|
28
ci/windows-docker/install_dav1d.ps1
Normal file
28
ci/windows-docker/install_dav1d.ps1
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12;
|
||||||
|
|
||||||
|
# Download gstreamer and all its subprojects
|
||||||
|
git clone -b 1.0.0 --depth 1 https://code.videolan.org/videolan/dav1d.git C:\dav1d
|
||||||
|
if (!$?) {
|
||||||
|
Write-Host "Failed to clone dav1d"
|
||||||
|
Exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
Set-Location C:\dav1d
|
||||||
|
|
||||||
|
# This is fine, we are not going to use the GtkMedia* apis
|
||||||
|
$env:MESON_ARGS = "--prefix=C:\gst-install\"
|
||||||
|
|
||||||
|
Write-Output "Building dav1d"
|
||||||
|
cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=amd64 && meson _build $env:MESON_ARGS && meson compile -C _build && ninja -C _build install"
|
||||||
|
|
||||||
|
if (!$?) {
|
||||||
|
Write-Host "Failed to build and install dav1d"
|
||||||
|
Exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
cd C:\
|
||||||
|
cmd /c rmdir /s /q C:\dav1d
|
||||||
|
if (!$?) {
|
||||||
|
Write-Host "Failed to remove dav1d checkout"
|
||||||
|
Exit 1
|
||||||
|
}
|
Loading…
Reference in a new issue