www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - dub configuration for a dependency?

reply joshuabarnes <miyaiskhailfa gmail.com> writes:
By default, DerelictODE is configured to load the 
double-precision version of ODE. If you want to load the 
single-precision version, declare "DerelictODE_Single" as a 
version in the build settings of your dub.json.

What does this actually mean?

I have

     "dependencies": {
         "derelict-glfw3": "~>4.0.0-beta.1",
         "derelict-gl3": "~>2.0.0-beta.7",
         "imageformats": "~>7.0.0",
         "derelict-ode:": "~>3.0.0-b"
     }
but have no idea what the above means? sadly the dub 
documentation didn't seem to be much help?
Sep 26 2018
parent reply Laurent =?UTF-8?B?VHLDqWd1aWVy?= <laurent.treguier.sink gmail.com> writes:
On Wednesday, 26 September 2018 at 10:41:36 UTC, joshuabarnes 
wrote:
 By default, DerelictODE is configured to load the 
 double-precision version of ODE. If you want to load the 
 single-precision version, declare "DerelictODE_Single" as a 
 version in the build settings of your dub.json.

 What does this actually mean?

 I have

     "dependencies": {
         "derelict-glfw3": "~>4.0.0-beta.1",
         "derelict-gl3": "~>2.0.0-beta.7",
         "imageformats": "~>7.0.0",
         "derelict-ode:": "~>3.0.0-b"
     }
 but have no idea what the above means? sadly the dub 
 documentation didn't seem to be much help?
From https://code.dlang.org/package-format?lang=json#configurations ``` { ... "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"] } ] } ``` Adding `"versions": ["DerelictODE_Single"]` in your dub file should do the trick.
Sep 26 2018
parent joshuabarnes <miyaiskhailfa gmail.com> writes:
On Wednesday, 26 September 2018 at 11:03:04 UTC, Laurent Tréguier 
wrote:
 On Wednesday, 26 September 2018 at 10:41:36 UTC, joshuabarnes 
 wrote:
 By default, DerelictODE is configured to load the 
 double-precision version of ODE. If you want to load the 
 single-precision version, declare "DerelictODE_Single" as a 
 version in the build settings of your dub.json.

 What does this actually mean?

 I have

     "dependencies": {
         "derelict-glfw3": "~>4.0.0-beta.1",
         "derelict-gl3": "~>2.0.0-beta.7",
         "imageformats": "~>7.0.0",
         "derelict-ode:": "~>3.0.0-b"
 
_____________________________________________________ thankyou so much!!!
Sep 27 2018