Fix #927: Use a macro to automatically depend on right artifact

Ah, no, it's called by the generated code. Never mind, then.