Native artifacts not resolving correctly and Ivy Custom Attribute workarounds

We have a build that relies on binary artifacts published in invy format. As a result our dependencies look something like:

<dependency org="com.mycompany" name="MyDLL" rev="2.2.+" conf="nativeLinux32->runtime" e:os="linux" e:arch="ia32" e:compiler="gcc41"/>

The deployment is all custom as well when for example you look at the ivy file for that item you would see

<ivy-module xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:e="http://ant.apache.org/ivy/extra" version="2.0" xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd">
<info organisation="cpp.com.mycompany" module="CrawlerDLL" revision="2.2.20140915204242" status="integration" publication="20140915204243" e:mercurialId="830f6906b555" e:compiler="vc100" e:arch="amd64" e:os="win">
<configurations>
<conf name="runtime" visibility="public" description="Used for publishing. Describes the artifacts which are required to run a program which has been linked againts this module, i.e. the DSOs. "/>
<conf name="linktime" visibility="public" description="Used for publishing. Describes the artifacts of the module which are required to link it." extends="runtime"/>
</configurations>
<publications>
<artifact name="MyDllJNI" type="DSO" ext="dll" conf="runtime"/>
<artifact name="MyDllJNI" type="debug-information" ext="pdb" conf="runtime"/>
<artifact name="MyDllJNI" type="importLibrary" ext="lib" conf="linktime"/>
</publications>
<dependencies>
<dependency org="com.mycompany" name="MyLogging" rev="1.0.20140915203537" revConstraint="1.+" conf="runtime->runtime" e:os="win" e:arch="amd64" e:compiler="vc100"/>
</dependencies>
</ivy-module>

The ivy patterns used are

<property name="recommind.artifacts.layout" value="[organisation]/[module](/[branch])(/[os])(-[arch])(-[compiler])/[type]s/[artifact](-[classifier])-[revision](-[variant]).[ext]"/>
<property name="recommind.ivys.layout" value="[organisation]/[module](/[branch])(/[os])(-[arch])(-[compiler])/ivy-[revision].xml"/>

I already know that custom attributes for ivy are not supported yet. https://issues.gradle.org/browse/GRADLE-3060

My question is either: - How are others handling situations like this - Is it possible to have ivy calculate the whole dependency graph without trying to download the artifacts (which will fail) and then I can manage the downloads externally, if so how would I do this a code example would be appreciated. If I can do this I can put those items into a natives configuration and then create a separate task to fetch and install them. I have also tried

project(':myproject').configurations.nativeBinaries.incoming.each {
  println "************************\n${it.dependencies}"
 }

which in a bind should do but then I can’t make use of the dynamic versions also the published artifact names are different from the actual defined name in ivy.

I’m trying to avoid as much custom work as I can so any further tips would be appreciated

Update 2014-09-23:

I tried using the following

project(':myproject').configurations.nativeBinaries.resolvedConfiguration.resolvedArtifacts.each {
  println "\t${it}"
 }

for the above ivy xml that gets resolved theres actually a few issues - there are actuall 3 artifacts with different types yet I see only one it prints out as is below - the names of the artifcts are different MyDllJNI vs MyDll

[ResolvedArtifact dependency:org.gradle.api.internal.artifacts.ivyservice.dynamicversions.DefaultResolvedModuleVersion@30c8a604 name:MyDLL classifier:win-ia32-vc100 extension:dll type:dll]

in my dependency however I had to specify the extension otherwise it seems to default to jar

nativeBinaries group: 'cpp.com.recommind', name: 'CrawlerDLL', version: '2.2.+', configuration: 'runtime', ext: 'dll', classifier: 'win-ia32-vc100' // os: 'win', arch: 'ia32', compiler: 'vc100'

I am not sure if I’m not understanding correctly of if this is a bug