From 27601a5527106a41bd7b6f7a87102d047286af51 Mon Sep 17 00:00:00 2001 From: Santiago Fernandez Madero Date: Tue, 8 Dec 2020 14:25:36 -0800 Subject: [PATCH 1/2] Add workarounds for brew on old OSX images --- eng/install-native-dependencies.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/eng/install-native-dependencies.sh b/eng/install-native-dependencies.sh index 927c4245cde44d..378f782cadee5e 100755 --- a/eng/install-native-dependencies.sh +++ b/eng/install-native-dependencies.sh @@ -30,6 +30,15 @@ if [ "$1" = "Linux" ]; then fi elif [ "$1" = "OSX" ] || [ "$1" = "tvOS" ] || [ "$1" = "iOS" ]; then engdir=$(dirname "${BASH_SOURCE[0]}") + + if [ "$3" = "azDO" ]; then + # workaround for old osx images on hosted agents + # piped in case we get an agent without these values installed + brew uninstall openssl@1.0.2t 2>&1 | true + rm -rf /usr/local/etc/openssl 2>&1 | true + rm -rf /usr/local/etc/openssl@1.1 2>&1 | true + fi + brew update --preinstall brew bundle --no-upgrade --no-lock --file "${engdir}/Brewfile" if [ "$?" != "0" ]; then From 5da3db0d026d111b36a3c23972141268a2bbff7c Mon Sep 17 00:00:00 2001 From: Santiago Fernandez Madero Date: Tue, 8 Dec 2020 15:40:45 -0800 Subject: [PATCH 2/2] Don't remove openssl directories --- eng/install-native-dependencies.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/eng/install-native-dependencies.sh b/eng/install-native-dependencies.sh index 378f782cadee5e..19ea810bb1c458 100755 --- a/eng/install-native-dependencies.sh +++ b/eng/install-native-dependencies.sh @@ -35,8 +35,6 @@ elif [ "$1" = "OSX" ] || [ "$1" = "tvOS" ] || [ "$1" = "iOS" ]; then # workaround for old osx images on hosted agents # piped in case we get an agent without these values installed brew uninstall openssl@1.0.2t 2>&1 | true - rm -rf /usr/local/etc/openssl 2>&1 | true - rm -rf /usr/local/etc/openssl@1.1 2>&1 | true fi brew update --preinstall