Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
[SOLVED] Qmake INCLUDEPATH does Not includes sub folders?
Its seems that adding all folder is by design (or lack of) and the
smart flag /folder/** is not supported.
Also I could use #include "../path/sub path/file.h" but
its less optimal if you refactor folder structure sometimes.
Trying to get my trace system up and running in Qt.
it has a folder structure like
Normally I would just add "Platform" to include path (for my current compiler) and any file under
would be found.
Seems QMake wants all listed
INCLUDEPATH += $$PWD/../AllPO/Source/Common/Platform/Trace
Which is kinda a nightmare as there are sub and sub-sub folders too.
So am I doing it wrong ?
ChrisW67 last edited by
We can guess Windows but have no idea what compilers are involved. I am not aware of any compiler that treats include path options recursively.
Take a look at the actual compiler command generated by qmake and make sure that $PWD is expanding to the place you think it is.
Sorry, forgot to mention platform. (facepalm)
win 7, mingw
Yes I did use $PWD and added each folder.
Just wanted an easier way, but that not possible.
C++ builder looks in sub folder for includes pr default/pr option.
I assume $PWD is always where the .pro file is.