Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 27 additions & 11 deletions images/macos/scripts/build/install-common-utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,35 @@ source ~/utils/utils.sh
common_packages=$(get_toolset_value '.brew.common_packages[]')
for package in $common_packages; do
echo "Installing $package..."
if [[ $package == "packer" ]]; then
# Packer has been deprecated in Homebrew. Use tap to install Packer.
brew install hashicorp/tap/packer
else
if (is_VenturaX64 || is_SonomaX64) && [[ $package == "tcl-tk@8" ]]; then
case "$package" in
packer)
# Packer has been deprecated in Homebrew. Use tap to install Packer.
brew install hashicorp/tap/packer
;;

kotlin)
# Pin kotlin bottle to 2.1.10 due to an issue with the latest version
# https://youtrack.jetbrains.com/issue/KT-76169/kotlinc-js-version-and-kapt-version-returning-non-zero-status-code-on-v2.1.20
kotlin_commit="442af88a2925f8c0e079eaf4fa62261133d2d7c4"
kotlin_rb_link="https://raw.githubusercontent.com/Homebrew/homebrew-core/$kotlin_commit/Formula/k/kotlin.rb"
kotlin_rb_path=$(download_with_retry "$kotlin_rb_link")
brew install "$kotlin_rb_path"
;;

tcl-tk@8)
brew_smart_install "$package"
# Fix for https://github.com/actions/runner-images/issues/11074
ln -sf $(brew --prefix tcl-tk@8)/lib/libtcl8.6.dylib /usr/local/lib/libtcl8.6.dylib
ln -sf $(brew --prefix tcl-tk@8)/lib/libtk8.6.dylib /usr/local/lib/libtk8.6.dylib
else
if is_VenturaX64 || is_SonomaX64; then
# Fix for https://github.com/actions/runner-images/issues/11074
ln -sf "$(brew --prefix tcl-tk@8)/lib/libtcl8.6.dylib" /usr/local/lib/libtcl8.6.dylib
ln -sf "$(brew --prefix tcl-tk@8)/lib/libtk8.6.dylib" /usr/local/lib/libtk8.6.dylib
fi
;;

# Default behaviour for all other packages
*)
brew_smart_install "$package"
fi
fi
;;
esac
done

cask_packages=$(get_toolset_value '.brew.cask_packages[]')
Expand Down
3 changes: 0 additions & 3 deletions images/macos/scripts/build/install-homebrew.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,3 @@ brew_smart_install curl

echo "Installing wget..."
brew_smart_install "wget"

# init brew bundle feature
brew tap Homebrew/bundle