Cmake-based GCC embedded build skill that scans projects, configures, builds, rebuilds, cleans, and analyzes ELF size.
- CCM score
- 58 of 100
- skills.sh installs
- 770
- GitHub stars
- 815
- last updated
- Aug 21, 2026
Own this skill? Claim it
What it does
- Covers CMake-based arm-none-eabi-gcc embedded projects, with scan, presets, configure, build, rebuild, clean, and size subcommands
- Provides three scripts (
gcc_project.py,gcc_build.py,gcc_size.py) built on the Python standard library, returning JSON results - Enforces an operation mode (direct, risk summary, or confirm-first) and never auto-guesses project paths or presets when ambiguous
- Designed for embedded teams using CMake presets and Ninja, and reports
elf_filefor use by downstream flashing or debug tools
Install
$ npx -y skills add zhinkgit/embeddedskills --skill gcc -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
GCC 嵌入式工程构建
本 skill 提供基于 CMake + arm-none-eabi-gcc 的嵌入式工程发现、preset 枚举、配置生成、增量编译、全量重建、清理和 ELF 大小分析能力。
范围说明:当前仅支持 CMake 型 GCC 嵌入式工程,不覆盖纯 Makefile 工程。
运行依赖
Windows 或 Linux,Python 3.10+、CMake、工程的生成器与 ARM GCC 工具链。
配置
环境级配置(skill/config.json)
skill 目录下的 config.json(可按需从 config.example.json 复制创建)包含环境级配置,工具未加入 PATH 时可在此配置 cmake_exe:
{
"cmake_exe": "cmake",
"toolchain_prefix": "arm-none-eabi-",
"toolchain_path": "",
"operation_mode": 1
}
cmake_exe:cmake 可执行文件路径,默认从 PATH 查找toolchain_prefix:工具链前缀,默认arm-none-eabi-,用于定位 size 等工具toolchain_path:工具链 bin 目录,为空时从 PATH 查找operation_mode:1直接执行 /2输出风险摘要但不阻塞 /3执行前确认
工程级配置(workspace/.embeddedskills/config.json)
工程级共享配置统一保存在工作区的 .embeddedskills/config.json 中:
{
"gcc": {
"project": "",
"preset": "",
"log_dir": ".embeddedskills/build"
}
}
project:默认工程路径(相对 workspace),构建成功后会自动更新preset:默认 CMake preset 名称,构建成功后会自动更新log_dir:构建日志输出目录,默认.embeddedskills/build
参数解析优先级
参数解析顺序(从高到低):
- CLI 显式参数
- 工程级配置(.embeddedskills/config.json)
- .embeddedskills/state/gcc.json(上次构建记录)
- 搜索/询问
工具路径依次读取 CLI、本机配置和 PATH。
Details
- Repository
- github.com/zhinkgit/embeddedskills
- Categories
- CLI & Terminal, DevOps & Cloud
- First seen
- Jun 3, 2026
More from zhinkgit/embeddedskills
All 9Similar to Gcc
More CLI & TerminalkeilSkillzhinkgit/embeddedskills984 installsKeil MDK project build tool that scans uvprojx/uvproj/uvmpw projects, enumerates targets, and runs build, rebuild, or clean.
workflowSkillzhinkgit/embeddedskills761 installsRead-only planner and diagnostic tool that maps embedded projects to native build, flash, debug, and observe commands.
ninjaSkillmohitmishra786/low-level-dev-skills778 installsNinja build executor skill covering CMake generation, parallelism tuning, diagnostics, and build.ninja internals.
cmakeSkillmohitmishra786/low-level-dev-skills2K installsModern target-first CMake guidance for C/C++ builds, from project setup through cross-compilation and presets.
xcode-build-skillsPluginAvdLee/Xcode-Build-Optimization-Agent-Skill1.3K starsSix Xcode build optimization skills in one plugin: benchmark, compilation analysis, project analysis, SPM build analysis, a recommend-first orchestrator, and a
makefile-generatorSkillakin-ozer/cc-devops-skills715 installsCreate, generate, or scaffold Makefiles with .PHONY targets and standard build automation.