mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-07-26 06:38:42 +00:00
410bb9c103
* feat: add inheritable-only field to hide processor-level targets from listing Processor-level targets like esp32, rp2040, etc. have flash-method set so they leak through the existing heuristic filter in GetTargetSpecs and appear in `tinygo targets` output. Add an "inheritable-only" JSON field that is checked on raw JSON before inheritance resolution, preventing these non-board targets from being listed while keeping them loadable for direct builds and inheritance. Ref: tinygo-org/tinygo#5178 * fix: prevent inheritable-only from propagating to child targets The InheritableOnly bool field was propagating from parent to child targets through overrideProperties, which would hide board targets from GetTargetSpecs. Fix by preserving/restoring the field across resolveInherits. Also simplify GetTargetSpecs by removing the raw JSON pre-check workaround and remove nonexistent esp32c6 from tests. * prevent build commands to use inheritable only targets
23 lines
822 B
JSON
23 lines
822 B
JSON
{
|
|
"inherits": ["xtensa"],
|
|
"inheritable-only": true,
|
|
"cpu": "esp32",
|
|
"features": "+atomctl,+bool,+clamps,+coprocessor,+debug,+density,+dfpaccel,+div32,+exception,+fp,+highpriinterrupts,+interrupt,+loop,+mac16,+memctl,+minmax,+miscsr,+mul32,+mul32high,+nsa,+prid,+regprotect,+rvector,+s32c1i,+sext,+threadptr,+timerint,+windowed",
|
|
"build-tags": ["esp32", "esp"],
|
|
"scheduler": "tasks",
|
|
"serial": "uart",
|
|
"linker": "ld.lld",
|
|
"default-stack-size": 2048,
|
|
"rtlib": "compiler-rt",
|
|
"libc": "picolibc",
|
|
"linkerscript": "targets/esp32.ld",
|
|
"extra-files": [
|
|
"src/device/esp/esp32.S",
|
|
"src/internal/task/task_stack_esp32.S"
|
|
],
|
|
"binary-format": "esp32",
|
|
"flash-method": "esp32flash",
|
|
"emulator": "qemu-system-xtensa -machine esp32 -nographic -drive file={img},if=mtd,format=raw",
|
|
"gdb": ["xtensa-esp32-elf-gdb"]
|
|
}
|