I have a project hierarchy like this:
file.pro
src/
files.cpp
include/
headers.h
build/
files.o
bin/
finalExecutable
What to specify in the .pro
file so that the Makefile generated by qmake
takes the .cpp
files from my src/
directory and put the executable in the build
directory?
For the include
part, I have added INCLUDEPATH += include/*
, and it seems to work other than the fact that while including any file.h
I have to write #include <include/file.h>
instead of #include <file.h>
.
How to put it in the .pro
file so that I can include headers like #include <file.h>
.
I tried to add SOURCES += src/*
, but it shows an error:
error: No rule to make target 'sourceFiles/*', needed by 'mydialog.o'. Stop.
How to go about specifying the include
, src
and the build
directories?