Skip to content

Commit c989329

Browse files
committed
fix: resolve release workflow build errors
- macOS: use 'shasum -a 256' instead of 'sha256sum' (not available on macOS) - Windows: disable ccache to fix .rc resource file compilation conflict with Ninja - Add -DCMAKE_C_COMPILER_LAUNCHER="" and -DCMAKE_CXX_COMPILER_LAUNCHER="" - Add -DCCACHE_PROGRAM=OFF - Split Unix and Windows CMake configuration into separate steps (matching ci.yml)
1 parent 7c9ffe1 commit c989329

File tree

1 file changed

+30
-20
lines changed

1 file changed

+30
-20
lines changed

.github/workflows/release.yml

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,8 @@ jobs:
188188
run: |
189189
sudo softwareupdate --install-rosetta --agree-to-license || true
190190
191-
- name: Configure CMake (Release)
191+
- name: Configure CMake (Release - Unix)
192+
if: runner.os != 'Windows'
192193
shell: bash
193194
run: |
194195
mkdir build
@@ -209,25 +210,32 @@ jobs:
209210
LINUX_STATIC_FLAG="-DEXTENSION_STATIC_BUILD=ON"
210211
fi
211212
212-
if [[ "${{ runner.os }}" == "Windows" ]]; then
213-
cmake .. \
214-
-DCMAKE_BUILD_TYPE=Release \
215-
-DBUILD_CPP_TESTS=OFF \
216-
-DBUILD_DUCKDB=ON \
217-
-G "Ninja" \
218-
-DCMAKE_C_COMPILER=cl \
219-
-DCMAKE_CXX_COMPILER=cl \
220-
-DRust_CARGO_TARGET="${{ matrix.target }}"
221-
else
222-
cmake .. \
223-
-DCMAKE_BUILD_TYPE=Release \
224-
-DBUILD_CPP_TESTS=OFF \
225-
-DBUILD_DUCKDB=ON \
226-
${LINUX_PLATFORM_FLAG} \
227-
${LINUX_STATIC_FLAG} \
228-
-DRust_CARGO_TARGET="${{ matrix.target }}" \
229-
${OSX_ARCH:+-DCMAKE_OSX_ARCHITECTURES=${OSX_ARCH}}
230-
fi
213+
cmake .. \
214+
-DCMAKE_BUILD_TYPE=Release \
215+
-DBUILD_CPP_TESTS=OFF \
216+
-DBUILD_DUCKDB=ON \
217+
${LINUX_PLATFORM_FLAG} \
218+
${LINUX_STATIC_FLAG} \
219+
-DRust_CARGO_TARGET="${{ matrix.target }}" \
220+
${OSX_ARCH:+-DCMAKE_OSX_ARCHITECTURES=${OSX_ARCH}}
221+
222+
- name: Configure CMake (Release - Windows)
223+
if: runner.os == 'Windows'
224+
run: |
225+
if (-not (Test-Path -Path "build")) { New-Item -ItemType Directory -Path "build" | Out-Null }
226+
cd build
227+
cmake .. `
228+
-DCMAKE_BUILD_TYPE=Release `
229+
-DBUILD_CPP_TESTS=OFF `
230+
-DBUILD_DUCKDB=ON `
231+
-DEXTENSION_STATIC_BUILD=ON `
232+
-G "Ninja" `
233+
-DCMAKE_C_COMPILER=cl `
234+
-DCMAKE_CXX_COMPILER=cl `
235+
-DCMAKE_C_COMPILER_LAUNCHER="" `
236+
-DCMAKE_CXX_COMPILER_LAUNCHER="" `
237+
-DCCACHE_PROGRAM=OFF `
238+
-DRust_CARGO_TARGET="${{ matrix.target }}"
231239
232240
- name: Build extension (Release)
233241
run: |
@@ -350,6 +358,8 @@ jobs:
350358
cd release-package
351359
if [[ "${{ runner.os }}" == "Windows" ]]; then
352360
certutil -hashfile "${{ matrix.extension-name }}" SHA256 > "${{ matrix.extension-name }}.sha256"
361+
elif [[ "${{ runner.os }}" == "macOS" ]]; then
362+
shasum -a 256 "${{ matrix.extension-name }}" > "${{ matrix.extension-name }}.sha256"
353363
else
354364
sha256sum "${{ matrix.extension-name }}" > "${{ matrix.extension-name }}.sha256"
355365
fi

0 commit comments

Comments
 (0)