Skip to content

feat: build-tree.sh compiles through ccache when CCACHE_DIR is set - #25

Merged
Xenolphthalein merged 1 commit into
mainfrom
feat/kernel-ccache
Nov 16, 2026
Merged

Xenolphthalein merged 1 commit into
mainfrom
feat/kernel-ccache

Conversation

@Xenolphthalein

Copy link
Copy Markdown
Contributor

What and why

overpressure/linux's check builds compile the whole kernel every time (about 22 minutes), even for a change to one driver.

  • build-tree.sh: with CCACHE_DIR set, the compiler runs through ccache (CC="ccache aarch64-linux-gnu-gcc", CCACHE_COMPILERCHECK=content, 3 GB). The objects carry over to the next build, also from another checkout, and the end of the build prints the hit rate.
    • Without CCACHE_DIR nothing changes. A release's two builds pass none, since they are the test that the kernel is reproducible.
    • An image without ccache warns and builds without it.
    • ccache gives the objects the compiler would; the banner's compiler text is the same, since ccache gcc -v is gcc's own.
  • docs/kernel.md:
    • build-tree.sh's row says how the repository's CI uses it.
    • The layers' paragraph: a layer pull request is built merged into phoenix/7.2, the Layers workflow starts its own pull requests' builds, and the rulesets require ci.

It takes effect with overpressure/builder#4 (ccache in the image, released and pinned in overpressure's overpressure/linux.py) and overpressure/linux's CI passing CCACHE_DIR for check builds (the follow-up PR into common/7.2).

Checks

  • Host tests pass (302); shellcheck at warning level and bash -n
  • No serials, vendor files or private data (python scripts/check-private.py --repo devices/phoenix --history)
  • Changes that write to a headset keep a recoverable path: build only; the kernel is the same

Hardware

Not needed. A full kernel build with ccache was not run locally; the first two check builds on GitHub after all parts are in show the hit rate.

…s overpressure/linux's check builds do; kernel.md describes the layers' checks
@Xenolphthalein
Xenolphthalein enabled auto-merge (rebase) November 16, 2026 10:49
@Xenolphthalein
Xenolphthalein merged commit 2bf8ada into main Nov 16, 2026
9 checks passed
@Xenolphthalein
Xenolphthalein deleted the feat/kernel-ccache branch November 16, 2026 10:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant