I use qmake to build a project. The project contains several static libs and a executable. The executable links to the static libraries and therefore has the path of the library added to the INCLUDEPATH variable.
When I change something in the header files of the executable everything is rebuild as expected. When changing a header file of the library it just rebuilds the library and relinks the executable. Source files in the executable that include header files from the library are not rebuild correctly.
After investigating the problem I saw that the generated makefiles do not track the dependencies correctly. Only files included with a relative path are tracked. Any header included via INCLUDEPATH is not tracked. Is there something I can do to make it work as expected?
You should add the paths you added to INCLUDEPATH
to DEPENDPATH
as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With