2026-10-01 23:12:21 +03:00
|
|
|
{
|
|
|
|
|
"$schema": "https://raw.githubusercontent.com/jetify-com/devbox/0.17.2/.schema/devbox.schema.json",
|
2026-10-07 19:45:20 +03:00
|
|
|
"packages": {
|
|
|
|
|
"rustc": "latest",
|
|
|
|
|
"cargo": "latest",
|
|
|
|
|
"pkg-config": "latest",
|
|
|
|
|
"rustfmt": "latest",
|
|
|
|
|
"gtk4": {
|
|
|
|
|
"version": "latest",
|
|
|
|
|
"platforms": ["x86_64-linux", "aarch64-linux"],
|
|
|
|
|
"outputs": ["out", "dev"]
|
|
|
|
|
},
|
|
|
|
|
"libadwaita": {
|
|
|
|
|
"version": "latest",
|
|
|
|
|
"platforms": ["x86_64-linux", "aarch64-linux"],
|
|
|
|
|
"outputs": ["out", "dev"]
|
2026-10-07 21:26:53 +03:00
|
|
|
},
|
|
|
|
|
"appstream": {
|
|
|
|
|
"version": "latest",
|
|
|
|
|
"platforms": ["x86_64-linux", "aarch64-linux"]
|
2026-10-07 19:45:20 +03:00
|
|
|
}
|
|
|
|
|
},
|
feat: simplify devbox config for macOS aarch64
On Apple Silicon Macs, many GTK-related nixpkgs packages are marked as
unsupported on aarch64-darwin. Instead of using nixpkgs for the GUI stack,
use Homebrew which provides pre-built bottles for gtk4, libadwaita, and
all their dependencies (glib, pango, cairo, gdk-pixbuf, graphene, etc.).
The devbox config now provides only the Rust toolchain (rustc, cargo,
pkg-config, rustfmt) and sets environment variables to locate the
Homebrew-installed libraries:
- PKG_CONFIG_PATH: /opt/homebrew/lib/pkgconfig
- PKG_CONFIG_PATH_arm64_apple_darwin: /opt/homebrew/lib/pkgconfig
- PATH: Includes /opt/homebrew/bin and /opt/homebrew/sbin
This allows building the project with: devbox run build
All 16 tests pass with: devbox run check
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
2026-10-07 12:48:09 +03:00
|
|
|
"env": {
|
2026-10-07 19:45:20 +03:00
|
|
|
"PATH": "/opt/homebrew/bin:/opt/homebrew/sbin:$PATH"
|
feat: simplify devbox config for macOS aarch64
On Apple Silicon Macs, many GTK-related nixpkgs packages are marked as
unsupported on aarch64-darwin. Instead of using nixpkgs for the GUI stack,
use Homebrew which provides pre-built bottles for gtk4, libadwaita, and
all their dependencies (glib, pango, cairo, gdk-pixbuf, graphene, etc.).
The devbox config now provides only the Rust toolchain (rustc, cargo,
pkg-config, rustfmt) and sets environment variables to locate the
Homebrew-installed libraries:
- PKG_CONFIG_PATH: /opt/homebrew/lib/pkgconfig
- PKG_CONFIG_PATH_arm64_apple_darwin: /opt/homebrew/lib/pkgconfig
- PATH: Includes /opt/homebrew/bin and /opt/homebrew/sbin
This allows building the project with: devbox run build
All 16 tests pass with: devbox run check
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
2026-10-07 12:48:09 +03:00
|
|
|
},
|
2026-10-01 23:12:21 +03:00
|
|
|
"shell": {
|
2026-10-07 19:45:20 +03:00
|
|
|
"init_hook": [
|
|
|
|
|
"export PKG_CONFIG_PATH=\"$DEVBOX_PACKAGES_DIR/lib/pkgconfig:$PKG_CONFIG_PATH\"",
|
|
|
|
|
"if [[ \"$(uname)\" == \"Darwin\" ]]; then export PKG_CONFIG_PATH=\"/opt/homebrew/lib/pkgconfig:$PKG_CONFIG_PATH\"; export PKG_CONFIG_PATH_arm64_apple_darwin=\"/opt/homebrew/lib/pkgconfig\"; fi"
|
|
|
|
|
],
|
2026-10-01 23:12:21 +03:00
|
|
|
"scripts": {
|
|
|
|
|
"build": [
|
|
|
|
|
"cargo build --release"
|
|
|
|
|
],
|
|
|
|
|
"run": [
|
|
|
|
|
"cargo build --release && ./target/release/carrier"
|
|
|
|
|
],
|
|
|
|
|
"dev": [
|
|
|
|
|
"cargo build && ./target/debug/carrier"
|
|
|
|
|
],
|
|
|
|
|
"test": [
|
|
|
|
|
"cargo test"
|
|
|
|
|
],
|
|
|
|
|
"check": [
|
|
|
|
|
"cargo fmt --check && cargo build && cargo test"
|
2026-10-03 11:29:06 +03:00
|
|
|
],
|
|
|
|
|
"package": [
|
|
|
|
|
"flatpak-builder --force-clean --user --install-deps-from=flathub --install .flatpak com.randogoth.carrier.json"
|
2026-10-07 20:39:57 +03:00
|
|
|
],
|
|
|
|
|
"bundle-flatpak": [
|
2026-10-07 21:26:53 +03:00
|
|
|
"flatpak-builder --force-clean --user --disable-rofiles-fuse --repo=.flatpak-repo --install-deps-from=flathub .flatpak-build com.randogoth.carrier.json",
|
2026-10-07 20:39:57 +03:00
|
|
|
"flatpak build-bundle .flatpak-repo carrier-x86_64.flatpak com.randogoth.carrier"
|
2026-10-01 23:12:21 +03:00
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|