# Boost + Qt Creator

## Recommended Posts

VitaliBR    147
I'm using Qt Creator, and must include a boost in my project, how do I set the boost in qt creator?!

I am using the following functions:
#include <boost/filesystem/operations.hpp>#include <boost/filesystem/path.hpp>#include <boost/progress.hpp>

##### Share on other sites
Kambiz    758
And what is the problem? Have you already compiled boost? Do you get any compiler or link errors?

INCLUDEPATH += path/to/boost
to the project file.

##### Share on other sites
VitaliBR    147
Quote:
 Original post by KambizAnd what is the problem? Have you already compiled boost? Do you get any compiler or link errors?If boost headers cannot be found add INCLUDEPATH += path/to/boostto the project file.

I have compiled a boost on my computer using Visual Studio 2010, but how do I link the libs and includes the Qt Creator? I do not need to recompile boost using MinGW of Qt?

Sorry my poor english :(

##### Share on other sites
Emergent    982
Quote:
 Original post by VitaliBRI have compiled a boost on my computer using Visual Studio 2010, but how do I link the libs and includes the Qt Creator? I do not need to recompile boost using MinGW of Qt?

If you have Visual Studio, then you probably want to use it with the Qt plugin, rather than QtCreator. In that case, you'd need to compile Qt with Visual Studio. This blog post describes the procedure.

##### Share on other sites
Kambiz    758
LIBS += -L"path/to/boost/libs"
to the project file, and add libraries using the -l option to the same line.
I have never tries using libs compiled by VC with MinGW, it might well be that you need to recompile boost with MinGW.

##### Share on other sites
VitaliBR    147
Quote:
Original post by Emergent
Quote:
 Original post by VitaliBRI have compiled a boost on my computer using Visual Studio 2010, but how do I link the libs and includes the Qt Creator? I do not need to recompile boost using MinGW of Qt?

If you have Visual Studio, then you probably want to use it with the Qt plugin, rather than QtCreator. In that case, you'd need to compile Qt with Visual Studio. This blog post describes the procedure.

The Qt 4.6 don't support VS2010 :(

##### Share on other sites
I've never used boost before, but since I use QT Creator frequently, here's a visual explanation of what the others are saying since there seems to be some confusion:

(Where "path/to/boost" and "path/to/boost/lib" you change to fit the actual paths on your computer)

VitaliBR    147
Thanks! :D

I will try that!

##### Share on other sites
phresnel    953
Quote:
Original post by Emergent
Quote:
 Original post by VitaliBRI have compiled a boost on my computer using Visual Studio 2010, but how do I link the libs and includes the Qt Creator? I do not need to recompile boost using MinGW of Qt?

If you have Visual Studio, then you probably want to use it with the Qt plugin, rather than QtCreator.

I guess QtCreator is well enough suited for Qt development. The plugins and the external editors are basically stripped down versions of QtCreator. Or vice versa, QtCreator is the sum of plugins and editor.