You can now have SPM plugins that generate code. [Here's an example](https://github.com/dabrahams/citron/blob/master/Plugins/CitronParserGenerator/CitronParserGenerator.swift), and [here it is in use](https://github.com/val-lang/Lotsawa/blob/29e2812efff1e4efd483c28215f5db4e0dd3fddd/Package.swift#L26).