Skip to content

Commit

Permalink
build.ps1 - Fix build issue where there are multiple CEF builds with …
Browse files Browse the repository at this point in the history
…the same version number

- One is Stable and the other Beta, they're both the same build so just order and get the latest
  • Loading branch information
amaitland committed Jan 17, 2025
1 parent 8c8c1b7 commit 4ddf218
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
6 changes: 3 additions & 3 deletions NuGet/chromiumembeddedframework.runtime.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
"runtimes": {
"win-x64": {
"chromiumembeddedframework.runtime": {
"chromiumembeddedframework.runtime.win-x64": "121.2.14"
"chromiumembeddedframework.runtime.win-x64": "132.3.1"
}
},
"win-x86": {
"chromiumembeddedframework.runtime": {
"chromiumembeddedframework.runtime.win-x86": "121.2.14"
"chromiumembeddedframework.runtime.win-x86": "132.3.1"
}
},
"win-arm64": {
"chromiumembeddedframework.runtime": {
"chromiumembeddedframework.runtime.win-arm64": "121.2.14"
"chromiumembeddedframework.runtime.win-arm64": "132.3.1"
}
},
}
Expand Down
13 changes: 8 additions & 5 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ param(
[string] $CefBinaryDir = "../cefsource/chromium/src/cef/binary_distrib/",

[Parameter(Position = 3)]
$CefVersion = "121.2.14+ga44b59f+chromium-121.0.6167.75",
$CefVersion = "132.3.1+g144febe+chromium-132.0.6834.83",

[ValidateSet("tar.bz2","zip","7z")]
[Parameter(Position = 4)]
Expand Down Expand Up @@ -524,10 +524,13 @@ function DownloadCefBinaryAndUnzip()
Die "Build Unavailable - $arch has no files for version $CefVersion"
}

#TODO Duplication
$CefFileName = ($CefWinCefVersion.files | Where-Object {$_.type -eq "standard"}).name
$CefFileHash = ($CefWinCefVersion.files | Where-Object {$_.type -eq "standard"}).sha1
$CefFileSize = (($CefWinCefVersion.files | Where-Object {$_.type -eq "standard"}).size /1MB)
# CEF sometimes has multiple builds of the same version with one being Stable and one being Beta
# We'll take the newest build in that case
$CefStandardFiles = ($CefWinCefVersion.files | Where-Object {$_.type -eq "standard"} | Sort-Object -Descending -Property last_modified)[0];

$CefFileName = $CefStandardFiles.name
$CefFileHash = $CefStandardFiles.sha1
$CefFileSize = $CefStandardFiles.size /1MB

$LocalFile = Join-Path $WorkingDir $CefFileName
if (-not (Test-Path $LocalFile))
Expand Down

0 comments on commit 4ddf218

Please sign in to comment.