Make sure published platforms can be consumed as enforced platforms This commit introduces a similar strategy to what we do with Maven metadata, but for Gradle metadata, in order to force platforms. In fact, it uses the same code path since Gradle metadata also makes use of Maven immutable resolve metadata. The only difference then happens at parse time where we generate synthetic copies of platform variants.
Implement enforced platforms via variants instead of component metadata rules This commit replaces the component metadat rules implementation with proper variant based matching. It introduces a new attribute, the component category, which can currently be either a library or a platform. By default, components are assumed to be libraries.