Release assets are now the programs themselves: SolveCraft and solvecraft-cli .exe for Windows,
plain Linux binaries plus the AppImage, a macOS .dmg (SolveCraft.app with an Applications link) and
the universal CLI binary; only the web app stays a zip. The notes template takes {tag}, says to
chmod +x on Linux and macOS, and GitHub adds the change list.
Since no LICENSE or NOTICE file rides along any more, the programs carry them:
THIRD-PARTY-LICENSES.txt (written by `cargo xtask licences` from cargo metadata and each shipped
crate's own licence files, 419 crates; `cargo xtask ci` checks it is current) is embedded with
LICENSE-MIT, LICENSE-APACHE and NOTICE in solvecraft_engine::licences, shown in Help ▸ About ▸
Licences (third-party text laid out by visible rows) and printed by `solvecraft-cli licences`.
Scenario s44_about_licences.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
36 lines
1.8 KiB
Bash
Executable File
36 lines
1.8 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Package the macOS release build: a universal (arm64 + x86_64) SolveCraft.app in a .dmg (with an
|
|
# Applications link to drag it onto), and the universal CLI as a plain binary.
|
|
# Usage: .github/release/package-macos.sh <tag> (from the repository root, after building both
|
|
# aarch64-apple-darwin and x86_64-apple-darwin). Writes out/. Neither is signed.
|
|
set -euo pipefail
|
|
tag=${1:?usage: package-macos.sh <tag>}
|
|
version=${tag#v}
|
|
t=${CARGO_TARGET_DIR:-target}
|
|
rm -rf stage out && mkdir -p stage/dmg out
|
|
app="stage/dmg/SolveCraft.app"
|
|
mkdir -p "$app/Contents/MacOS"
|
|
lipo -create -output "$app/Contents/MacOS/solvecraft" "$t/aarch64-apple-darwin/release/solvecraft" "$t/x86_64-apple-darwin/release/solvecraft"
|
|
lipo -create -output "out/solvecraft-cli-$tag-macos-universal" "$t/aarch64-apple-darwin/release/solvecraft-cli" "$t/x86_64-apple-darwin/release/solvecraft-cli"
|
|
cat > "$app/Contents/Info.plist" <<PLIST
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
<plist version="1.0">
|
|
<dict>
|
|
<key>CFBundleName</key><string>SolveCraft</string>
|
|
<key>CFBundleDisplayName</key><string>SolveCraft</string>
|
|
<key>CFBundleIdentifier</key><string>io.github.bherbruck.solvecraft</string>
|
|
<key>CFBundleExecutable</key><string>solvecraft</string>
|
|
<key>CFBundlePackageType</key><string>APPL</string>
|
|
<key>CFBundleVersion</key><string>$version</string>
|
|
<key>CFBundleShortVersionString</key><string>$version</string>
|
|
<key>LSMinimumSystemVersion</key><string>11.0</string>
|
|
<key>NSHighResolutionCapable</key><true/>
|
|
</dict>
|
|
</plist>
|
|
PLIST
|
|
lipo -info "$app/Contents/MacOS/solvecraft"
|
|
ln -s /Applications stage/dmg/Applications
|
|
hdiutil create -volname "SolveCraft $tag" -srcfolder stage/dmg -ov -format UDZO "out/SolveCraft-$tag-macos-universal.dmg"
|
|
ls -l out
|