On 19/01/2015 1:59 p.m., cal wrote:
Given myapp and a dependency, specified by dub.json's:
myapp: dub.json
{
...
"dependencies": {
"dependency_a": ">=0.6.0"
}
...
}
dependency_a: dub.json
{
...
"configurations": [
{
"name": "config_a",
"targetType": "library",
...
},
{
"name": "config_b",
"targetType": "executable",
...
},
...
}
How do I specify (in myapp: dub.json) that I want the "config_a"
configuration of dependency_a?
I just want to verify, you are using configurations only to determine if
its being built a certain way?
And not lets say as a subpackage?
Ignoring that, there is something called subConfigurations section.
Example from: http://code.dlang.org/package-format
{
...
"name": "somepackage"
"configurations": [
{
"name": "metro-app",
"targetType": "executable",
"platforms": ["windows"],
"versions": ["MetroApp"],
"libs": ["d3d11"]
},
{
"name": "desktop-app",
"targetType": "executable",
"platforms": ["windows"],
"versions": ["DesktopApp"],
"libs": ["d3d9"]
},
{
"name": "glut-app",
"targetType": "executable",
"versions": ["GlutApp"]
}
]
}
{
...
"dependencies": {
"somepackage": ">=1.0.0"
},
"subConfigurations": {
"somepackage": "glut-app"
}
}