Skip to content

Commit

Permalink
ci/win32: add zlib
Browse files Browse the repository at this point in the history
It should work out of the box, but upstream meson wrap is not robust in
this case.
  • Loading branch information
kasper93 committed May 6, 2024
1 parent 37eb997 commit fb07c43
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions ci/build-win32.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,19 @@ git clone https://github.com/arch1t3cht/Aegisub --depth 1
Copy-Item -Path "Aegisub/subprojects/packagefiles/luajit/*" `
-Destination "$subprojects/packagefiles/luajit" -Force

# Patch for ffmpeg wrap to allow internal meson dependencies (needed for zlib)
if (-not (Test-Path "$subprojects/packagefiles/ffmpeg")) {
New-Item -Path "$subprojects/packagefiles/ffmpeg" -ItemType Directory | Out-Null
}
Copy-Item -Path "Aegisub/subprojects/packagefiles/ffmpeg/0001.patch" `
-Destination "$subprojects/packagefiles/ffmpeg" -Force

$projects = @(
@{
Path = "$subprojects/ffmpeg.wrap"
URL = "https://gitlab.freedesktop.org/gstreamer/meson-ports/ffmpeg.git"
Revision = "meson-6.1"
Patch = "ffmpeg/0001.patch"
Provides = @(
"libavcodec = libavcodec_dep",
"libavdevice = libavdevice_dep",
Expand Down Expand Up @@ -134,6 +142,9 @@ clone-recursive = true
if ($project.ContainsKey('PatchDir')) {
$content += "`npatch_directory = $($project.PatchDir)"
}
if ($project.ContainsKey('Patch')) {
$content += "`ndiff_files = $($project.Patch)"
}
if ($project.ContainsKey('Provides')) {
$provide = "[provide]`n$($project.Provides -join "`n")"
$content += "`n$provide"
Expand All @@ -142,6 +153,7 @@ clone-recursive = true
}

meson setup build `
--force-fallback-for=zlib `
-Ddefault_library=static `
-Dlibmpv=true `
-Dtests=true `
Expand Down

0 comments on commit fb07c43

Please sign in to comment.