Skip to content

fix: label product-relative boot animation paths correctly - #110

Merged
0cwa merged 3 commits into
mainfrom
fix/boot-animation-product-context-20260925
Sep 25, 2026
Merged

0cwa merged 3 commits into
mainfrom
fix/boot-animation-product-context-20260925

Conversation

@0cwa

@0cwa 0cwa commented Sep 25, 2026

Copy link
Copy Markdown
Owner

Failure found by force-publish

The first force-publish attempt after PR #109 failed before publication with:

ExtInstallError: no file_contexts label matches installation path: /media/bootanimation.zip

That reveals a path-model mismatch in the pinned helper:

  • AFSR/product.img paths are partition-relative (/media/...);
  • SELinux file_contexts patterns are runtime Android paths (/product/media/...).

Using /product/media/... directly with ExtFs creates the wrong filesystem path, while using /media/... without a context alias cannot create a new inode.

Fix

Keep the correct partition-relative product image paths and add only exact context aliases for:

  • /media
  • /media/bootanimation.zip
  • /media/bootanimation-dark.zip

Each alias derives its label from the corresponding runtime /product/... path using the helper's loaded contexts. If GrapheneOS no longer has a runtime context matching the expected product path, the build fails closed.

No SELinux policy is modified, no broad regex is added, no bootanimation binary is patched, and the adapter still writes only through ExtFs.

The theme fallback from PR #109 remains:

  • one checked-in ZIP => both themes;
  • both ZIPs => distinct light/dark animations;
  • dark-only => both themes.

The selection contract is bumped to product-image-root-theme-context-stored-v6.

@coderabbitai

coderabbitai Bot commented Sep 25, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 8d3e0688-3b22-4a44-8158-b465f1a86cd6


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@0cwa
0cwa merged commit 1f31356 into main Sep 25, 2026
2 checks passed
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