cross-compile-matrix
БесплатноБез исполняемых скриптовНе проверенAdd a new target triple to the shipctl cross-platform build matrix — CI YAML, Makefile, and a smoke test. Use when adding support for a new OS/architecture…
от zakelfassi★ 18 звёзд на GitHubОб этом скилле
Cross-Compile Matrix
Add a new target triple to the build matrix so CI produces a binary for the new platform.
Inputs
- Target triple (e.g.,
aarch64-apple-darwin,x86_64-pc-windows-gnu) - Cross-compiler image (Docker image or
nativeif the runner natively supports the target) - Smoke test command (a simple invocation to verify the binary works, e.g.,
shipctl --version)
Steps
Verify the triple is valid
rustup target list | grep {triple}For Go: check
go tool dist list | grep {os}/{arch}.Add the target to the CI matrix Edit
.github/workflows/release.yml— add the triple to thematrix.targetarray:strategy: matrix: include: - target: {triple} runner: ubuntu-latest # or macos-latest, windows-latest cross: true # false if runner supports the target natively image: ghcr.io/cross-rs/{triple}:latest # omit if cross: falseAdd the Makefile target
build-{safe-triple}: cargo build --release --target {triple} mkdir -p dist cp target/{triple}/release/shipctl dist/shipctl-{triple}{safe-triple}replaces-with_in Make target names.Register the rustup target (Rust only)
rustup target add {triple}For CI: add to the
rustup target addstep in the workflow.Add a smoke test step in the workflow:
- name: Smoke test ({triple}) run: ./dist/shipctl-{triple} --version if: matrix.target == '{triple}'If cross-testing is not feasible (e.g., Windows binary on a Linux runner), document this in a comment.
Test locally (if the host supports the target)
make build-{safe-triple} ./dist/shipctl-{triple} --versionUpdate the release notes template Add a row to
docs/install.md:| {OS} | {Arch} | `{triple}` | `shipctl-{version}-{triple}.tar.gz` |
Conventions
- Target naming in artifacts:
shipctl-{version}-{triple}.tar.gz - Windows targets produce
.exeand are archived as.zipinstead of.tar.gz musltargets are preferred for Linux binaries to avoid glibc dependency issues- All targets are smoke-tested in CI before a release is published
Edge Cases
- Cross-compilation fails with linker errors: Switch to the
cross-rsDocker image for that triple; add theimage:field in the matrix. - Target is tier 3 (Rust): Add a comment noting reduced support guarantees; test manually before each release.
- macOS arm64 on amd64 runner: Use
--target aarch64-apple-darwinwith Rosetta or a self-hosted arm64 runner; document in the workflow. - Windows MSVC vs GNU: Prefer
x86_64-pc-windows-msvcfor best compatibility; GNU works but requires MinGW on the runner.
Установить cross-compile-matrix в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл cross-compile-matrix?
Add a new target triple to the shipctl cross-platform build matrix — CI YAML, Makefile, and a smoke test. Use when adding support for a new OS/architecture, when a user requests a new platform binary, or when a target triple is missing from the release artifacts.
Как установить скилл cross-compile-matrix?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл cross-compile-matrix запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic