diff --git a/build-app.sh b/build-app.sh index 6971da9..8ae2352 100755 --- a/build-app.sh +++ b/build-app.sh @@ -9,13 +9,6 @@ _error() { echo "\033[31m[ERROR]\033[0m $1" ; } _warn() { echo "\033[33m[WARN]\033[0m $1" ; } _logo() { echo "\033[1m $1\033[0m" ; } -target_arch=$(grep "app_arch = .*" < pyinstaller.spec | sed "s/^.*app_arch *= *'\(.*\)'$/\1/") -if [ "$(uname -m)" != "$target_arch" ]; then - _warn "You are using $(uname -m) architecture. This script will switch to $target_arch now." - arch -x86_64 "$0" $* - exit -fi - # Header echo "" echo "" @@ -137,7 +130,7 @@ rm -Rf build/* # Check if venv is created and do so if not. if ! [ -d "./venv" ] ; then _info "Creating virtual environment, so we do not pollute the system." - python3 -m venv venv + python3.11 -m venv venv else _ok "Looks like a virtual environment (venv) is already created." fi diff --git a/pyinstaller.spec b/pyinstaller.spec index 06dadf5..e9c41c2 100644 --- a/pyinstaller.spec +++ b/pyinstaller.spec @@ -73,7 +73,7 @@ hidden_imports = extract_modules() ########################## User Configuration ########################## # Intel: x86_64, Apple Silicon: arm64. -app_arch = 'x86_64' +app_arch = 'arm64' # Name. app_name = 'swiftGuard' @@ -99,7 +99,8 @@ added_files = [ ('README.md', '.'), ('LICENSE', '.'), ('ACKNOWLEDGMENTS', '.'), - ('/usr/local/bin/gpg', '.'), + ('/opt/homebrew/bin/gpg', '.'), + ('venv/lib/python3.11/site-packages/quickmachotkey', 'quickmachotkey'), # ('/usr/local/lib/libgcrypt.20.dylib', '.'), # ('/usr/local/lib/libassuan.0.dylib', '.'), # ('/usr/local/lib/libnpth.0.dylib', '.'), diff --git a/src/swiftguard/const.py b/src/swiftguard/const.py index e556392..88c0abe 100644 --- a/src/swiftguard/const.py +++ b/src/swiftguard/const.py @@ -133,7 +133,7 @@ os.makedirs(GPG_DIR, exist_ok=True) GPG_STORE = gnupg.GPG( gnupghome=GPG_DIR, - gpgbinary="/usr/local/bin/gpg", + gpgbinary="/opt/homebrew/bin/gpg", ) GPG_STORE.encoding = "utf-8" diff --git a/src/swiftguard/utils/helpers.py b/src/swiftguard/utils/helpers.py index 5bcf11e..abd2200 100644 --- a/src/swiftguard/utils/helpers.py +++ b/src/swiftguard/utils/helpers.py @@ -286,6 +286,7 @@ def apple_lookup(name, bcd): # sourcery skip: move-assign "15.05": "iPhone 15 Plus", "16.01": "iPhone 15 Pro", "16.02": "iPhone 15 Pro Max", + "17.01": "iPhone 16 Pro", } ipods = {