Skip to content

Build and Install

Michal Švácha edited this page Oct 16, 2026 · 1 revision

Build and Install

Requirements: macOS 14 or later, Xcode 16 or later (Swift 6 toolchain). No Xcode project; it is a SwiftPM package.

git clone https://github.com/svachmic/EasyScan.git
cd EasyScan
./build.sh --install --run

build.sh:

Flag Effect
(none) release build, assemble build/EasyScan.app, ad-hoc sign
--install copy to ~/Applications/EasyScan.app (quits a running copy first, replaces atomically)
--run open the built or installed app
--debug use the debug build
--icon regenerate Packaging/AppIcon.icns from Packaging/make-icon.swift

Environment variables VERSION and BUILD_NUMBER override the version strings in the bundled Info.plist.

SANE (optional, but the long-term path)

brew install sane-backends
scanimage -L        # should list your scanner

EasyScan looks for scanimage in /opt/homebrew/bin, /usr/local/bin and PATH.

Development

swift build                                               # debug build
EASYSCAN_MOCK=1 .build/debug/EasyScan                     # synthetic scanner, no hardware needed
EASYSCAN_UI_DEMO=1 EASYSCAN_MOCK=1 .build/debug/EasyScan  # scripted tour of every UI state; prints WINDOW <id> for screencapture -l
EASYSCAN_SELFTEST_DIR=/tmp/scans build/EasyScan.app/Contents/MacOS/EasyScan --selftest

Clone this wiki locally