Load “legacy” (a.k.a. non-declarative) plugins through the buildscript mechanism.

Implementation is a bit of a mess, will be tidied in subsequent changes.