Skip to content

gfx: no dev-trigger name in an embedded shader source (fixes the nightly package scan) - #994

Merged
GLinnik21 merged 1 commit into
mainfrom
gfx/shader-sources-name-no-trigger
Oct 24, 2026
Merged

GLinnik21 merged 1 commit into
mainfrom
gfx/shader-sources-name-no-trigger

Conversation

@GLinnik21

Copy link
Copy Markdown
Collaborator

What broke

#981 (65e976b) added rust-modules/gfx/src/shaders/fs_ramp.frag, whose line-8 comment spells the dev-trigger name plxnative-hwcnt. glsl! embeds a shader source whole (concat!(include_str!(..), "\0"), comments included; nothing strips them), so the name was compiled into the binary. The Nightly workflow's make ipk step then failed ci/check-package.py's packaged-binary scan:

the com.beb.plxnative.nightly package carries no dev-trigger surface ... (found plxnative-hwcnt)

(seen on PR #991's "ARM build + gates / build + verify" job). #981's only other plxnative-hwcnt is a plain // comment in gfx.rs, which is not compiled in.

The fix

  • fs_ramp.frag: line 8 now reads (HWCNT, 2026-10-24) instead of naming the trigger. A comment only, so the compiled program is unchanged.
  • New test gfx::tests::no_shader_source_names_a_dev_trigger reads EVERY file under rust-modules/gfx/src/shaders/ (it lists the directory, so a new shader is covered by being added; that is the only shaders/ directory in the tree) and fails on any plxnative-. The scan matches the dev-trigger catalog's names (dev.rs DIAG + devtrig.rs CONTROLLED, minus the release-legitimate allowlist); the test matches the whole prefix, a superset that nothing in a shader needs, and the failure message says why.

Red / green

Red, before the reword (make test-crate C=plx_gfx T=no_shader_source_names_a_dev_trigger):

test gfx::tests::no_shader_source_names_a_dev_trigger ... FAILED
.../rust-modules/gfx/src/shaders/fs_ramp.frag:8: // arithmetic words (`plxnative-hwcnt`, 2026-10-24) where one `mix` is 1-1.5: the three uniform
test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 163 filtered out; finished in 0.00s

Green, after:

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 163 filtered out; finished in 0.00s

Whole crate (make test-crate C=plx_gfx): test result: ok. 164 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out. make check-nodef passes. Full make check is left to CI.

No linked issue.

🤖 Generated with Claude Code

…tly package scan)

#981's fs_ramp.frag comment spelled the dev-trigger name plxnative-hwcnt. The glsl! macros
embed a shader source whole (include_str!, comments included), so the name was compiled into
the binary and the Nightly `make ipk` step failed ci/check-package.py's packaged-binary
dev-trigger scan ("the com.beb.plxnative.nightly package carries no dev-trigger surface ...
(found plxnative-hwcnt)").

Reword the comment to "(HWCNT, 2026-10-24)"; the compiled program is unchanged. Add
no_shader_source_names_a_dev_trigger, which reads every file under gfx/src/shaders/ and fails
on any "plxnative-", so a later shader comment is caught on the host and not by the ARM build.
It failed on fs_ramp.frag:8 before the reword.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@GLinnik21
GLinnik21 merged commit 9bc127f into main Oct 24, 2026
26 of 28 checks passed
@GLinnik21
GLinnik21 deleted the gfx/shader-sources-name-no-trigger branch October 24, 2026 12:30
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