agentleFS
D-RoboticsD-Robotics/dsh-plugin-rdk/skills/bsp-skills/bsp-kernel-build/SKILL.md

bsp-kernel-build

Skill1 starsChanged 3 months agoApache-2.0View on GitHub

Build the RDK Linux kernel, device tree, and driver modules with mk_kernel.sh (X5 also offers mk_kernel_rt.sh for the real-time kernel). Use when the user wants to compile the kernel, rebuild dtb, add driver modules, or needs kernel_headers for out-of-tree builds. 触发词:编译内核、内核、设备树、dtb、驱动模块、mk_kernel、实时内核、RT 内核、kernel headers. Do not use for full images (bsp-image-build), deb packaging (bsp-deb-build), or S-series (bsp-s-series).

1 other project uses a version of this, 1 of them edited.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Do not use for the whole image build or deb-only rebuilds — sibling skills handle those.

    line 25
  2. Distinctive:

    Run the kernel build from the workspace root:

    line 31
  3. Very specific:

    Verify outputs in deploy/kernel:

    line 37
  4. Distinctive:

    Do not modify kernel configs or dts files without showing the diff and getting user confirmation.

    line 49

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Kernel, Device Tree, and Driver Build

Purpose

Compile the Linux kernel, device tree, and driver modules, and understand how their outputs feed the hobot-boot / hobot-dtb / hobot-kernel-headers deb packages. Kernel work is the entry point for most deep BSP customization (device tree changes, new drivers, RT requirements).

When to use

Use when:

  • The user wants to build/modify the kernel, dtb, or driver modules
  • The kernel artifacts (deploy/kernel) are missing but deb packages are needed
  • Setting up out-of-tree module builds that need kernel_headers

Do not use for the whole image build or deb-only rebuilds — sibling skills handle those.

Instructions

  1. Prerequisites: one completed full image build (bsp-image-build) — it downloads the rootfs whose headers/libraries application packages use, plus the official debs.
  2. Run the kernel build from the workspace root:
    ./mk_kernel.sh          # kernel, dtb, driver modules
    ./mk_kernel_rt.sh       # X5 only: real-time kernel
  3. Verify outputs in deploy/kernel:
    dtb  Image  Image.lz4  kernel_headers  modules
  4. Explain the dependency chain (report this to the user): these outputs are consumed by the hobot-boot, hobot-dtb, and hobot-kernel-headers deb packages — so any customization of those three packages requires rebuilding the kernel first, then bsp-deb-build.
  5. For driver development: point the user to deploy/kernel/kernel_headers for out-of-tree module builds; do not invent include paths.

Safety

  • Kernel builds are CPU/disk heavy: confirm available resources before a long run.
  • Do not modify kernel configs or dts files without showing the diff and getting user confirmation.
  • RT kernel (mk_kernel_rt.sh) changes scheduling behavior on the target — flag the difference before switching.

Sources: x5-rdk-gen README v3.5.0「编译 kernel」; rdk-gen README v3.0.3「编译 kernel」。

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.