1#!/bin/sh 2# 3# Release automation script for MacOS builds. This should be run 4# after the Linux build has created the staging repository and 5# selected the BoringSSL revision. Must be run from the top-level 6# conscrypt directory, which should be synced to the appropriate 7# release branch. 8 9set -e 10 11if [ -z "$2" ]; then 12 echo "Usage: $0 <boringssl revision> <repository ID>" 13 exit 1 14fi 15 16if [ -z "$JAVA_HOME" ]; then 17 export JAVA_HOME=$(/usr/libexec/java_home) 18fi 19 20# If BORINGSSL_HOME isn't set, assume it's located at ../boringssl 21if [ -z "$BORINGSSL_HOME" ]; then 22 export BORINGSSL_HOME=$(cd ../boringssl; pwd -P) 23fi 24 25pushd "$BORINGSSL_HOME" >/dev/null 26git checkout master 27git pull 28git checkout $1 29cd build64 30ninja 31popd >/dev/null 32 33./gradlew conscrypt-openjdk:build 34./gradlew conscrypt-openjdk:publish -Dorg.gradle.parallel=false -PrepositoryId="$2" 35