@@ -130,37 +130,43 @@ jobs:
130130 - name : Build release binary
131131 run : cmake --build build --config Release
132132
133- - name : Verify binary exists and check architecture
133+ - name : Verify binary exists and check architecture (Unix)
134+ if : runner.os != 'Windows'
134135 run : |
135- if [[ "${{ runner.os }}" == "Windows" ]]; then
136- if [[ ! -f "build/Release/netmgr.exe" ]]; then
137- echo "Error: Windows binary not found at build/Release/netmgr.exe"
138- ls -la build/
139- ls -la build/Release/ || echo "Release directory not found"
140- exit 1
141- fi
142- echo "Windows binary found"
143- file build/Release/netmgr.exe || echo "file command not available on Windows"
144- else
145- if [[ ! -f "build/netmgr" ]]; then
146- echo "Error: Binary not found at build/netmgr"
147- ls -la build/
148- exit 1
149- fi
150- echo "Binary found, checking architecture:"
151- file build/netmgr
152-
153- # Verify it's the correct architecture for cross-compilation
154- if [[ "${{ matrix.target }}" == "aarch64-linux-gnu" ]]; then
155- if file build/netmgr | grep -q "aarch64\|ARM aarch64"; then
156- echo "✓ ARM64 binary confirmed"
157- else
158- echo "⚠ Warning: Binary may not be ARM64 architecture"
159- file build/netmgr
160- fi
136+ if [[ ! -f "build/netmgr" ]]; then
137+ echo "Error: Binary not found at build/netmgr"
138+ ls -la build/
139+ exit 1
140+ fi
141+ echo "Binary found, checking architecture:"
142+ file build/netmgr
143+
144+ # Verify it's the correct architecture for cross-compilation
145+ if [[ "${{ matrix.target }}" == "aarch64-linux-gnu" ]]; then
146+ if file build/netmgr | grep -q "aarch64\|ARM aarch64"; then
147+ echo "✓ ARM64 binary confirmed"
148+ else
149+ echo "⚠ Warning: Binary may not be ARM64 architecture"
150+ file build/netmgr
161151 fi
162152 fi
163153
154+ - name : Verify binary exists (Windows)
155+ if : runner.os == 'Windows'
156+ shell : pwsh
157+ run : |
158+ if (-not (Test-Path "build/Release/netmgr.exe")) {
159+ Write-Host "Error: Windows binary not found at build/Release/netmgr.exe"
160+ Get-ChildItem build/
161+ if (Test-Path "build/Release/") {
162+ Get-ChildItem build/Release/
163+ } else {
164+ Write-Host "Release directory not found"
165+ }
166+ exit 1
167+ }
168+ Write-Host "Windows binary found"
169+
164170 - name : Strip binary (Unix)
165171 if : runner.os != 'Windows' && matrix.strip_cmd != ''
166172 run : |
@@ -185,9 +191,9 @@ jobs:
185191
186192 - name : Prepare binary (Windows)
187193 if : runner.os == 'Windows'
188- shell : cmd
194+ shell : pwsh
189195 run : |
190- copy build\ Release\ netmgr.exe ${{ matrix.name }}
196+ Copy-Item " build/ Release/ netmgr.exe" " ${{ matrix.name }}"
191197
192198 - name : Build Debian package (Linux x86_64 only)
193199 if : matrix.os == 'ubuntu-22.04' && matrix.target == 'x86_64-linux-gnu'
0 commit comments