Skip to content

Commit df9924d

Browse files
committed
Fix hanging PowerShell build capture
Replace complex Start-Process with output redirection that was causing the build to hang. Use simpler direct cmake execution that won't block on output capture. This should resolve the hanging issue during the build process.
1 parent 12c79ce commit df9924d

File tree

1 file changed

+8
-27
lines changed

1 file changed

+8
-27
lines changed

.github/workflows/build-windows.yml

Lines changed: 8 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -100,34 +100,15 @@ jobs:
100100
msbuild -version
101101
echo "=== Starting build with detailed logging ==="
102102
103-
# Try build with detailed diagnostics - capture full output
104-
$buildOutput = ""
105-
$buildError = ""
106-
try {
107-
# Use Start-Process to capture all output
108-
$process = Start-Process -FilePath "cmake" -ArgumentList "--build", ".", "--config", "Release", "--parallel", "4", "--verbose", "--", "/verbosity:detailed" -NoNewWindow -Wait -PassThru -RedirectStandardOutput "build-output.log" -RedirectStandardError "build-error.log"
109-
$buildOutput = Get-Content "build-output.log" -Raw -ErrorAction SilentlyContinue
110-
$buildError = Get-Content "build-error.log" -Raw -ErrorAction SilentlyContinue
111-
112-
if ($process.ExitCode -ne 0) {
113-
echo "=== BUILD FAILED - Exit Code: $($process.ExitCode) ==="
114-
echo "=== STDOUT OUTPUT ==="
115-
if ($buildOutput) { echo $buildOutput } else { echo "No stdout output" }
116-
echo "=== STDERR OUTPUT ==="
117-
if ($buildError) { echo $buildError } else { echo "No stderr output" }
118-
$buildFailed = $true
119-
} else {
120-
echo "=== BUILD SUCCEEDED ==="
121-
$buildFailed = $false
122-
}
123-
} catch {
124-
echo "=== BUILD PROCESS EXCEPTION ==="
125-
echo $_.Exception.Message
126-
$buildFailed = $true
127-
}
103+
# Try build with detailed diagnostics - use simpler approach
104+
echo "Starting CMake build..."
105+
$buildResult = $?
106+
cmake --build . --config Release --parallel 4 --verbose -- /verbosity:detailed
107+
$buildResult = $?
128108
129-
if ($buildFailed) {
130-
echo "=== First build attempt failed, checking atari800 status ==="
109+
if (-not $buildResult) {
110+
echo "=== BUILD FAILED - Checking atari800 status ==="
111+
echo "=== Build failed, checking atari800 status ==="
131112
132113
# Check if libatari800 was actually built despite the error
133114
if (Test-Path "atari800-src\src\libatari800.a") {

0 commit comments

Comments
 (0)