More like this:
# top.pro
include(common.pri)
TEMPLATE = subdirs
CONFIG += ordered
SUBDIRS = sub1
# top.pro
include(common.pri)
TEMPLATE = subdirs
CONFIG += ordered
SUBDIRS = sub1
To copy to clipboard, switch view to plain text mode
# common.pri
# You can use another method to locate the directories, e.g. full paths
MYBINDESTDIR = $$PWD/bin
MYDLLDESTDIR = $$PWD/bin
MYLIBDESTDIR = $$PWD/lib
# common.pri
# You can use another method to locate the directories, e.g. full paths
MYBINDESTDIR = $$PWD/bin
MYDLLDESTDIR = $$PWD/bin
MYLIBDESTDIR = $$PWD/lib
To copy to clipboard, switch view to plain text mode
# sub1/sub1.pro
include(../common.pri)
message( Sub1 MYBINDESTDIR is $$MYBINDESTDIR )
message( Sub1 MYDLLDESTDIR is $$MYDLLDESTDIR )
message( Sub1 MYLIBDESTDIR is $$MYLIBDESTDIR )
TEMPLATE = app
DESTDIR = $$MYBINDESTDIR
# Input
SOURCES += main.cpp
# sub1/sub1.pro
include(../common.pri)
message( Sub1 MYBINDESTDIR is $$MYBINDESTDIR )
message( Sub1 MYDLLDESTDIR is $$MYDLLDESTDIR )
message( Sub1 MYLIBDESTDIR is $$MYLIBDESTDIR )
TEMPLATE = app
DESTDIR = $$MYBINDESTDIR
# Input
SOURCES += main.cpp
To copy to clipboard, switch view to plain text mode
Bookmarks