Correct homebrew path on arm macOS. By @sammcj (#1760)

This commit is contained in:
Sam 2023-07-31 06:22:28 +10:00 committed by GitHub
parent 25b4cc0b8b
commit 0e37e1cf90
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 1 deletions

View File

@ -5,12 +5,19 @@ VERSION := $(shell python -c "from src.vorta._version import __version__; print(
.PHONY : help clean lint test
.DEFAULT_GOAL := help
# Set Homebrew location to /opt/homebrew on Apple Silicon, /usr/local on Intel
ifeq ($(shell uname -m),arm64)
export HOMEBREW = /opt/homebrew
else
export HOMEBREW = /usr/local
endif
clean:
rm -rf dist/*
dist/Vorta.app: ## Build macOS app locally (without Borg)
pyinstaller --clean --noconfirm package/vorta.spec
cp -R /usr/local/Caskroom/sparkle/*/Sparkle.framework dist/Vorta.app/Contents/Frameworks/
cp -R ${HOMEBREW}/Caskroom/sparkle/*/Sparkle.framework dist/Vorta.app/Contents/Frameworks/
rm -rf build/vorta dist/vorta
dist/Vorta.dmg: dist/Vorta.app ## Create notarized macOS DMG for distribution.