Cmajor External Toolchain
Use this skill when a task involves Pulp's current Cmajor support lane.
Truthful Position
Pulp supports Cmajor as an external toolchain, not as a vendored runtime.
Supported now:
.cmajor/.cmajorpatchsource examples- patch-structure validation through
tools/scripts/cmajor_external.py doctor - generated-artifact invocation through a user-provided
cmaj - docs and workflow guidance for the MIT-safe lane
Not supported by this skill:
- shipping the Cmajor engine/JIT/runtime in Pulp core
- claiming a finished
Processoradapter for arbitrary Cmajor patches - blanket hot-reload claims
- broad multi-DSL parity claims
Core Files
docs/guides/cmajor.mdtools/scripts/cmajor_external.pydocs/contracts/pulp-dsl-v1.mdexamples/cmajor-gain/
Recommended Workflow
1. Validate the example or patch layout first
python3 tools/scripts/cmajor_external.py doctor \
--patch examples/cmajor-gain/CmajorGain.cmajorpatch
Use --require-tool when the next step truly depends on a real cmaj.
2. Keep `cmaj` external
Preferred resolution order:
--cmaj /path/to/cmajCMAJ_BIN=/path/to/cmajPATH
Do not turn the upstream Cmajor runtime/toolchain into a bundled dependency of
Pulp unless the repo's license policy changes.
3. Generate artifacts explicitly
python3 tools/scripts/cmajor_external.py generate \
--patch examples/cmajor-gain/CmajorGain.cmajorpatch \
--target cpp \
--output /tmp/CmajorGain.cpp
Pass through target-specific args with repeated --arg flags.
4. Keep docs truthful
When editing this lane, keep these in sync:
docs/guides/cmajor.mddocs/reference/capabilities.mddocs/guides/examples.mdplanning/v3-phase14-gap-closure-status.md
What To Check
For the current Cmajor lane, verify:
- patch manifest/source layout is valid
- missing-tool diagnostics are explicit
- helper commands target the user-supplied
cmaj, not an assumed bundled tool - docs do not imply a shipped runtime or checked-in generated output
Boundaries
This skill is for the MIT-safe external lane only.
If a user wants true runtime embedding:
- treat that as a separate BYO-runtime path
- keep it opt-in
- do not convert it into a default shipped dependency