Skip to content

Commit 7381ac9

Browse files
committed
Added powershell script to download and extract the FFMPEG Windows builds
1 parent ffc8a37 commit 7381ac9

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

ffmpeg/download.ps1

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
$tempPath = Join-Path -Path $(Get-Location) -ChildPath "tmp"
2+
3+
New-Item -ItemType Directory -Path $tempPath -Force | Out-Null
4+
5+
$devZipPath = Join-Path -Path $tempPath -ChildPath "ffmpeg.dev.zip"
6+
$binZipPath = Join-Path -Path $tempPath -ChildPath "ffmpeg.bin.zip"
7+
8+
(new-object System.Net.WebClient).DownloadFile('https://ffmpeg.zeranoe.com/builds/win64/dev/ffmpeg-20190320-0739d5c-win64-dev.zip', $devZipPath);
9+
Expand-Archive $devZipPath -DestinationPath $tempPath -Force
10+
11+
(new-object System.Net.WebClient).DownloadFile('https://ffmpeg.zeranoe.com/builds/win64/shared/ffmpeg-20190320-0739d5c-win64-shared.zip', $binZipPath);
12+
Expand-Archive $binZipPath -DestinationPath $tempPath -Force
13+
14+
Remove-Item -Path include -Force -Recurse -ErrorAction Ignore
15+
Remove-Item -Path lib -Force -Recurse -ErrorAction Ignore
16+
Remove-Item -Path bin -Force -Recurse -ErrorAction Ignore
17+
18+
Get-ChildItem -Path "tmp/ffmpeg-*-win64-dev/lib" | Move-Item -Destination $(Get-Location) -Force
19+
Get-ChildItem -Path "tmp/ffmpeg-*-win64-dev/include" | Move-Item -Destination $(Get-Location) -Force
20+
Get-ChildItem -Path "tmp/ffmpeg-*-win64-shared/bin" | Move-Item -Destination $(Get-Location) -Force
21+
22+
Remove-Item -Path $tempPath -Force -Recurse -ErrorAction Ignore
23+
24+
25+
26+
27+

0 commit comments

Comments
 (0)