QtCreator subdirs project
-
30-06-2021 - |
문제
I'm going to achieve the following hierarchy in my QtCreator project based on subdirs template:
Project:
- subproject1 - static library
- subproject2 - static library
- subproject3 - unittests executable
The only one executable will be in subproject3, which will link against subproject1 and subproject 2.
However build works fine I've noticed some usability issue. When I run the whole project it tries to find executables in my libraries - and fails. I have to run subproject3 instead of the main one. Is it possible to avoid such situation?
올바른 솔루션이 없습니다
다른 팁
I am using a similar hierarchy for the unit-tests - and the .pro file should have the following lines in it
INCLUDEPATH += ../subproject1/ \
../subproject2/
After adding the folders in the INCLUDEPATH variable, you can add the sources and header that you need using the SOURCES and HEADERS variables. Hope it helps you
제휴하지 않습니다 StackOverflow