forked from ayoy/qoauth
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
QOAUTH_INCDIR = $$[QT_INSTALL_HEADERS] | ||
QOAUTH_LIBDIR = $$[QT_INSTALL_LIBS] | ||
|
||
QOAUTH_INCDIR ~= s!/qt4!! | ||
QOAUTH_LIBDIR ~= s!/qt4!! | ||
|
||
CONFIG *= qt | ||
|
||
# if we are including oauth.prf from the qoauth tree (and not utilizing it as | ||
# an installed qmake CONFIG feature), then point to the tree. this allows our | ||
# qoauth tree apps to build before qoauth itself is installed. | ||
exists($$PWD/qoauth.pro) { | ||
QOAUTH_INCDIR = $$PWD/include | ||
QOAUTH_LIBDIR = $$PWD/lib | ||
} | ||
|
||
LINKAGE = | ||
|
||
# on mac, if qoauth was built as a framework, link against it | ||
mac: { | ||
framework_dir = $${QOAUTH_LIBDIR} | ||
exists($$framework_dir/qoauth.framework) { | ||
LIBS += -F$$framework_dir | ||
exists($$PWD/qoauth.pro): INCLUDEPATH += $$QOAUTH_INCDIR | ||
else: INCLUDEPATH += $$framework_dir/qoauth.framework/Headers | ||
LINKAGE = -framework qoauth | ||
} | ||
} | ||
|
||
# else, link normally | ||
isEmpty(LINKAGE) { | ||
exists($$PWD/qoauth.pro): INCLUDEPATH += $$QOAUTH_INCDIR | ||
else: INCLUDEPATH += $$QOAUTH_INCDIR/QtOAuth | ||
LIBS += -L$$QOAUTH_LIBDIR | ||
LINKAGE = -lqoauth | ||
CONFIG(debug, debug|release) { | ||
windows:LINKAGE = -lqoauthd | ||
mac:LINKAGE = -lqoauth_debug | ||
} | ||
} | ||
|
||
LIBS += $$LINKAGE |