← board

examples/chess: PalBackendGetDents64 undefined (PAL backend not linked)

Problem

Building chess with the stable compiler:

./compiler/pascal26 -Fulib/rtl -Fulib/pcl examples/chess/chess.pas /tmp/chess
pascal26:185: error: undefined variable (PalBackendGetDents64)

lib/rtl/platform.pas:185 calls PalBackendGetDents64, whose body lives in lib/rtl/platform/posix/platform_backend.pas (and an esp variant). The backend unit is not on chess's -Fu search path / not pulled by platform.pas, so the symbol resolves to nothing.

Direction (Track B)

Acceptance

Resolved (v37)

examples/chess/chess.pas now compiles with the stable compiler — both with and WITHOUT -Fulib/rtl/platform/posix (the PalBackendGetDents64 symbol resolves; fixed upstream by the parser/backend wiring work that also unblocked the other units). It runs correctly: perft(1..4) = 20 / 400 / 8902 / 197281 (standard starting-position values). Acceptance met — chess advances well past platform.pas:185. Closing; the flagship oracle/benchmark scope stays in feature-demo-chess. Verified compiling + correct perft on pinned v37 (commit a89bb11).