From 44008d11bb9f4b6538025528e947ffa45467bb12 Mon Sep 17 00:00:00 2001 From: sudden6 Date: Fri, 6 Nov 2020 20:45:36 +0100 Subject: [PATCH] chore: move OSX to use Brewfile --- .travis.yml | 4 ++++ .travis/build-osx.sh | 13 ------------- osx/Brewfile | 24 ++++++++++++++++++++++++ osx/qTox-Mac-Deployer-ULTIMATE.sh | 17 +---------------- 4 files changed, 29 insertions(+), 29 deletions(-) create mode 100644 osx/Brewfile diff --git a/.travis.yml b/.travis.yml index ed7f496ca..49356777e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -152,6 +152,10 @@ jobs: ccache: true directories: - $HOME/Library/Caches/Homebrew + addons: + homebrew: + brewfile: ./osx/Brewfile + update: true before_cache: - brew cleanup script: diff --git a/.travis/build-osx.sh b/.travis/build-osx.sh index 3ad40f89a..39f6b10ca 100755 --- a/.travis/build-osx.sh +++ b/.travis/build-osx.sh @@ -20,18 +20,6 @@ set -eu -o pipefail readonly BIN_NAME="qTox.dmg" -# accelerate builds with ccache -install_ccache() { - # manually update even though `install` will already update, due to bug: - # Please don't worry, you likely hit a bug auto-updating from an old version. - # Rerun your command, everything is up-to-date and fine now. - echo "Updating brew..." - brew update - echo "Installing ccache..." - brew install ccache - brew --cache -} - # Build OSX build() { bash ./osx/qTox-Mac-Deployer-ULTIMATE.sh -i @@ -54,7 +42,6 @@ make_hash() { } main() { - install_ccache build check make_hash diff --git a/osx/Brewfile b/osx/Brewfile new file mode 100644 index 000000000..d720f4442 --- /dev/null +++ b/osx/Brewfile @@ -0,0 +1,24 @@ +brew "git" +brew "wget" +brew "libtool" +brew "cmake" +brew "pkgconfig" +brew "check" +brew "libvpx" +brew "opus" +brew "libsodium" +brew "cmake" +brew "ffmpeg" +brew "libexif" +brew "qrencode" +brew "qt5" +brew "sqlcipher" +brew "openal-soft" +# accelerate builds with ccache +brew "ccache" + +# brew install #kf5-sonnet + +# needed for kf5-sonnet +# brew tap kde-mac/kde https://invent.kde.org/packaging/homebrew-kde.git +# brew "kf5-sonnet" diff --git a/osx/qTox-Mac-Deployer-ULTIMATE.sh b/osx/qTox-Mac-Deployer-ULTIMATE.sh index a25033b5c..6fb6aef2e 100755 --- a/osx/qTox-Mac-Deployer-ULTIMATE.sh +++ b/osx/qTox-Mac-Deployer-ULTIMATE.sh @@ -129,10 +129,8 @@ install() { fcho "Getting home brew formulas ..." if [[ $TRAVIS != true ]] then - sleep 3 - brew install git wget libtool cmake pkgconfig + brew bundle install -f ./osx/Brewfile fi - brew install check libvpx opus libsodium fcho "Starting git repo checks ..." @@ -178,19 +176,6 @@ install() { fi fi - if [[ $TRAVIS = true ]] - then - fcho "Updating brew formulas ..." - brew update > /dev/null - else - brew install cmake - fi - - # needed for kf5-sonnet - brew tap kde-mac/kde https://invent.kde.org/packaging/homebrew-kde.git - - brew install ffmpeg libexif qrencode qt5 sqlcipher openal-soft #kf5-sonnet - QT_VER=($(ls ${QT_DIR} | sed -n -e 's/^\([0-9]*\.([0-9]*\.([0-9]*\).*/\1/' -e '1p;$p')) QT_DIR_VER="${QT_DIR}/${QT_VER[1]}"