Skip to content

Commit bc3378b

Browse files
committed
ci: fix macos 13 brew installation
1 parent 06170ba commit bc3378b

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/build.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,16 @@ jobs:
165165
echo "CXX_LD=lld" >> "$GITHUB_ENV"
166166
echo "OBJC_LD=lld" >> "$GITHUB_ENV"
167167
168+
- name: Unbreak Python in GHA (MacOS 13 image)
169+
if: matrix.config.os == 'macos' && matrix.config.os-version == 13
170+
run: |
171+
# TODO: remove this, after it works again
172+
# A workaround for "The `brew link` step did not complete successfully" error.
173+
# See e.g. https://github.com/Homebrew/homebrew-core/issues/165793#issuecomment-1991817938
174+
find /usr/local/bin -lname '*/Library/Frameworks/Python.framework/*' -delete
175+
sudo rm -rf /Library/Frameworks/Python.framework/
176+
brew install --force python3 && brew unlink python3 && brew unlink python3 && brew link --overwrite python3
177+
168178
- name: Setup meson (MacOS)
169179
if: matrix.config.os == 'macos'
170180
run: |

0 commit comments

Comments
 (0)