You are not logged in.

1

Wednesday, July 14th 2010, 3:09pm

Common include directory in Qt workspace

Let's say I have Qt workspace which contains two projects. In the root directory I have .pro file with TEMPLATE=subdirs and SUBDIRS=Server Client
Now I want to create common Include directory, which contains h-files used by all projects. I want to see these h-files in Qt creator. How can I do this? For example, I can add Include to SUBDIRS, in this case I need to write some kind of "do nothing" .pro file in the Include directory.

2

Wednesday, July 14th 2010, 3:26pm

Use the INCLUDEPATH variable int the .pro file like this: INCLUDEPATH += /home/foobar/big_qt_project/common_includes/

3

Thursday, July 15th 2010, 5:42am

Thanks, INCLUDEPATH is necessary for compilation. I ask how to see h-files from include directory in the Project pane of Qt Creator.

Similar threads

Rate this thread