NativeLibrarySpec with dots causes IllegalArgumentException

Gradle Version: 2.14
Operating System: Windows
Is this a regression? Yes, worked with 2.13

Since 2.14 build fails if a NativeLibrarySpec contains dots in name like following:

    components {
        'foo.bar'(NativeLibrarySpec) {
            binaries.all {
java.lang.IllegalArgumentException: Element registration has a path (components.foo.bar.binaries) which is not a child of this node (components.foo.bar).
    at org.gradle.model.internal.registry.ModelElementNode.addNode(ModelElementNode.java:222)
    at org.gradle.model.internal.registry.ModelElementNode.addLink(ModelElementNode.java:216)
    at org.gradle.model.internal.core.ModelMaps.addModelMapNode(ModelMaps.java:33)
    at org.gradle.platform.base.component.BaseComponentSpec.<init>(BaseComponentSpec.java:42)
    at org.gradle.nativeplatform.internal.AbstractNativeComponentSpec.<init>(AbstractNativeComponentSpec.java:28)
    at org.gradle.nativeplatform.internal.AbstractTargetedNativeComponentSpec.<init>(AbstractTargetedNativeComponentSpec.java:28)
    at org.gradle.nativeplatform.internal.DefaultNativeLibrarySpec.<init>(DefaultNativeLibrarySpec.java:22)
    at org.gradle.internal.reflect.DirectInstantiator.newInstance(DirectInstantiator.java:42)
    at org.gradle.platform.base.component.internal.DefaultComponentSpec.create(DefaultComponentSpec.java:33)
    ... 75 more

Thanks for reporting this. Here’s the relevant ticket: https://issues.gradle.org/browse/GRADLE-3499