mirror of
https://github.com/openai/codex.git
synced 2026-05-20 19:23:21 +00:00
Prefer lld-link in MSVC setup action
This commit is contained in:
8
.github/actions/setup-msvc-env/action.yml
vendored
8
.github/actions/setup-msvc-env/action.yml
vendored
@@ -93,10 +93,14 @@ runs:
|
||||
throw "VCToolsInstallDir was not exported by VsDevCmd.bat"
|
||||
}
|
||||
|
||||
$linker = Join-Path $vcToolsInstallDir "bin\Host${hostArch}\${targetArch}\link.exe"
|
||||
$linker = Join-Path $installPath "VC\Tools\Llvm\x64\bin\lld-link.exe"
|
||||
if (-not (Test-Path $linker)) {
|
||||
throw "MSVC linker not found at $linker"
|
||||
$linker = Join-Path $vcToolsInstallDir "bin\Host${hostArch}\${targetArch}\link.exe"
|
||||
}
|
||||
if (-not (Test-Path $linker)) {
|
||||
throw "Windows linker not found at $linker"
|
||||
}
|
||||
|
||||
Write-Output "Using Windows linker: $linker"
|
||||
$cargoTarget = "${{ inputs.target }}".ToUpperInvariant().Replace("-", "_")
|
||||
"CARGO_TARGET_${cargoTarget}_LINKER=$linker" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
|
||||
|
||||
Reference in New Issue
Block a user