build: reimplement the OSS checks using a more declarative approach

Hopefully this change will bring balance to the force and drive chaos out of
our OSS checks.