shakespeare: depends on flex

Fixes #24763.