spb/zyquo-agent Public MIT
The autonomous agent that actually operates your Mac — plans, runs real commands, verifies its own work.
Swift 94.7%
Shell 4.1%
Python 0.7%
Makefile 0.5%
1#2# Makefile3# Zyquo Agent4#5# Author: Simon-Pierre Boucher6# Mail: contact@spboucher.ai7#8# make / make dev → release build, assemble dist/Zyquo Agent.app, ad-hoc sign (fast local iteration)9# make release → universal binary, Developer ID sign, notarize, staple (Phase 8)10# make icon → regenerate AppIcon.icns from assets/icon/zyquo-agent.svg (Phase 5)11# make test → swift test12# make clean → remove build products13#1415# CLT-only toolchain: SDK 27's SwiftUI declares @State & co. as macros whose16# plugin (libSwiftUIMacros.dylib) ships only with Xcode. SDK 26 keeps the17# property-wrapper forms, so all builds pin to it.18export SDKROOT := /Library/Developer/CommandLineTools/SDKs/MacOSX26.sdk1920APP_NAME := Zyquo Agent21EXEC_NAME := ZyquoAgent22BUNDLE_ID := com.zyquo.agent23VERSION := 1.0.024BUILD_NUM := 125MIN_MACOS := 13.026DIST := dist27APP_DIR := $(DIST)/$(APP_NAME).app28IDENTITY := Developer ID Application: Simon-Pierre Boucher (3YM54G49SN)29NOTARY_PROFILE:= MacLustr-Notarize30ENTITLEMENTS := Resources/ZyquoAgent.entitlements3132.PHONY: dev build bundle release universal icon test clean run3334dev: build bundle35 @echo "=== Ad-hoc signing (dev) ==="36 codesign --force --deep --sign - "$(APP_DIR)"37 codesign --verify --deep --strict "$(APP_DIR)"38 @echo "Packaged: $(APP_DIR) — launch with: open \"$(APP_DIR)\""3940build:41 swift build -c release4243test:44 swift test4546run: dev47 open "$(APP_DIR)"4849bundle:50 @echo "=== Assembling $(APP_DIR) ==="51 rm -rf "$(APP_DIR)"52 mkdir -p "$(APP_DIR)/Contents/MacOS" "$(APP_DIR)/Contents/Resources"53 cp .build/release/$(EXEC_NAME) "$(APP_DIR)/Contents/MacOS/$(EXEC_NAME)"54 @for b in .build/release/*.bundle; do [ -e "$$b" ] && cp -R "$$b" "$(APP_DIR)/Contents/Resources/" || true; done55 @if [ -f Resources/AppIcon.icns ]; then cp Resources/AppIcon.icns "$(APP_DIR)/Contents/Resources/AppIcon.icns"; fi56 @for r in Resources/MenuBarIcon.png Resources/MenuBarIcon@2x.png; do [ -f "$$r" ] && cp "$$r" "$(APP_DIR)/Contents/Resources/" || true; done57 scripts/write-info-plist.sh "$(APP_DIR)" "$(APP_NAME)" "$(EXEC_NAME)" "$(BUNDLE_ID)" "$(VERSION)" "$(BUILD_NUM)" "$(MIN_MACOS)"5859# Both arch builds land in .build/out/Products/Release with this build system,60# so each slice is copied aside before lipo. The -U flag allows the61# swiftCompatibility56 force-load symbol (CLT ships it arm64-only; it is never62# referenced at runtime on macOS 13+).63universal:64 @echo "=== Building universal binary (arm64 + x86_64) ==="65 mkdir -p .build/universal66 swift build -c release --arch arm6467 cp .build/out/Products/Release/$(EXEC_NAME) .build/universal/$(EXEC_NAME).arm6468 swift build -c release --arch x86_64 -Xlinker -U -Xlinker '__swift_FORCE_LOAD_$$_swiftCompatibility56'69 cp .build/out/Products/Release/$(EXEC_NAME) .build/universal/$(EXEC_NAME).x86_6470 lipo -create \71 .build/universal/$(EXEC_NAME).arm64 \72 .build/universal/$(EXEC_NAME).x86_64 \73 -output .build/universal/$(EXEC_NAME)74 lipo -archs .build/universal/$(EXEC_NAME)7576release: universal77 @echo "=== Assembling $(APP_DIR) (universal) ==="78 rm -rf "$(APP_DIR)"79 mkdir -p "$(APP_DIR)/Contents/MacOS" "$(APP_DIR)/Contents/Resources"80 cp .build/universal/$(EXEC_NAME) "$(APP_DIR)/Contents/MacOS/$(EXEC_NAME)"81 @for b in .build/out/Products/Release/*.bundle; do [ -e "$$b" ] && cp -R "$$b" "$(APP_DIR)/Contents/Resources/" || true; done82 @if [ -f Resources/AppIcon.icns ]; then cp Resources/AppIcon.icns "$(APP_DIR)/Contents/Resources/AppIcon.icns"; fi83 @for r in Resources/MenuBarIcon.png Resources/MenuBarIcon@2x.png; do [ -f "$$r" ] && cp "$$r" "$(APP_DIR)/Contents/Resources/" || true; done84 scripts/write-info-plist.sh "$(APP_DIR)" "$(APP_NAME)" "$(EXEC_NAME)" "$(BUNDLE_ID)" "$(VERSION)" "$(BUILD_NUM)" "$(MIN_MACOS)"85 scripts/notarize.sh "$(APP_DIR)" "$(IDENTITY)" "$(NOTARY_PROFILE)" "$(ENTITLEMENTS)"8687icon:88 scripts/generate-icon.sh8990clean:91 rm -rf .build $(DIST)92