BlueMagma
BlueMagma

Reputation: 2495

How to add DLL to Qbs project

I have generated a DLL file.

I have a working Qbs project.

How can I add the DLL file to my project so that I can access the library's fonctions ?

Upvotes: 2

Views: 2884

Answers (1)

Nejat
Nejat

Reputation: 32635

If you want to link to a library with files theLibrary.lib and theLibrary.dll you can try :

import qbs 1.0

Application {
     name: "AppName"
     files: "main.cpp"
     Depends { name: "cpp" }

     cpp.includePaths: [".","Path/To/include"]

     cpp.libraryPaths: ["Path/To/lib"]

     cpp.dynamicLibraries: "theLibrary"
}

Here you specify the library include path, path to the library and the library name.

Upvotes: 3

Related Questions