[QBS] How to use linking dependences of the third-party libraries

Denis Shienkov denis.shienkov at gmail.com
Tue May 27 19:49:30 CEST 2014


Christian,

 > Sorry, this is so weird I don't even know where to start.

A problem is in that I too don't know where to start. :)

 > Perhaps you want cpp.dynamicLibraries?

Yes, something like..

I want to create a some Product1, which can export a ready (source) of 
linking (*.lib) and runtime (*.dll) libraries.
And at "build" stage, the *.lib file should be copied into my output 
"/Project/Lib" directory, and the *.dll file should be copied into 
output "/Project" directory. And nothing anymore.

Then in the Product2 or Product3 I should be able to specify an 
dependence from Product1, like:

Product1 {
name: "foo"

// do something Rules/Transformer (yes??) to copy an *.lib and *.dll 
files into desired directories

// do something to export the cpp.dynamicLibraries ???
}

Product2 {
name: "myapp1"

Depends { name: "foo" }

}

Product3 {
name: "myapp2"

Depends { name: "foo" }

}

then in this case my "myapp1" and "myapp2" should be linked with the 
".lib", which provided from the "foo" Product1.

But I don't know how to implement the Product1 (or something else 
entity??) for my purpose. Maybe is a more elegant solution? I don't know..

Maybe I should to use:

      Export {
          Depends { name: "cpp" }
          cpp.dynamicLibraries: [<path to *.lib library>]
      }

in my Product1? But I do not understand how I can specify a full path (yes??) or name to my "/Project/Lib/foo.lib" which is copied to output "/Project/Lib/". And then where I should to specify my "*.lib/*.dll" libraries in my Product1?

BR,

Denis

27.05.2014 17:04, Christian Kandeler пишет:
> On 05/27/2014 12:03 PM, Denis Shienkov wrote:
>> Guys, can someone help me, please? :)
> Sorry, this is so weird I don't even know where to start. The fact that
> you add DLLs as source files takes me right out, for instance. Perhaps
> you want cpp.dynamicLibraries? I can only guess.
>
>
> Christian
> _______________________________________________
> QBS mailing list
> QBS at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/qbs




More information about the Qbs mailing list