1
0
mirror of https://gitee.com/drabel/LibQQt.git synced 2025-01-04 10:18:44 +08:00
LibQQt/examples/qqtframe2/link_qqt_library.pri

82 lines
3.1 KiB
Plaintext
Raw Normal View History

2017-11-07 10:33:42 +08:00
#here is all your app common defination and configration
#you can modify this pri to link qqt_library
2017-11-26 09:47:57 +08:00
#this link need Qt Creator set default build directory, replace
#%{JS: Util.asciify("/your/local/path/to/build/root/%{CurrentProject:Name}/%{Qt:Version}/%{CurrentKit:FileSystemName}/%{CurrentBuild:Name}")}
2017-11-26 16:34:59 +08:00
#auto link QQt when build source
#auto copy QQt when deploy app
#-------------------------------------------------------------
#user computer path settings
2017-11-26 16:34:59 +08:00
#-------------------------------------------------------------
2017-11-07 10:33:42 +08:00
equals(QMAKE_HOST.os, Darwin) {
QQT_SOURCE_ROOT = $$PWD/../..
2017-11-07 10:33:42 +08:00
} else: equals(QMAKE_HOST.os, Linux) {
QQT_SOURCE_ROOT = $$PWD/../..
2017-11-07 10:33:42 +08:00
} else: equals(QMAKE_HOST.os, Windows) {
QQT_SOURCE_ROOT = $$PWD/../..
2017-11-07 10:33:42 +08:00
}
2017-11-26 09:47:57 +08:00
equals(QMAKE_HOST.os, Darwin) {
QQT_BUILD_ROOT = /Users/abel/Develop/c0-buildstation
} else: equals(QMAKE_HOST.os, Linux) {
QQT_BUILD_ROOT = /home/abel/Develop/c0-buildstation
} else: equals(QMAKE_HOST.os, Windows) {
QQT_BUILD_ROOT = C:/Users/Administrator/Develop/c0-build
}
#default sdk path is qqt-source/../qqt-std-dir
#user can modify this path
2017-11-26 16:34:59 +08:00
equals(QMAKE_HOST.os, Darwin) {
QQT_SDK_ROOT = $${QQT_SOURCE_ROOT}/..
2017-11-26 16:34:59 +08:00
} else: equals(QMAKE_HOST.os, Linux) {
QQT_SDK_ROOT = $${QQT_SOURCE_ROOT}/..
2017-11-26 16:34:59 +08:00
} else: equals(QMAKE_HOST.os, Windows) {
QQT_SDK_ROOT = $${QQT_SOURCE_ROOT}/..
2017-11-21 15:55:48 +08:00
}
#-------------------------------------------------------------
#include qqt's pri
#-------------------------------------------------------------
#qqt qkit
include($${QQT_SOURCE_ROOT}/src/qqt_qkit.pri)
#qqt version
include($${QQT_SOURCE_ROOT}/src/qqt_version.pri)
#qqt header
include($${QQT_SOURCE_ROOT}/src/qqt_header.pri)
#-------------------------------------------------------------
#link qqt settings: use source or link library?
#-------------------------------------------------------------
#if you want to build qqt source open this annotation
2017-11-26 16:34:59 +08:00
#CONFIG += LINK_QQT_SOURCE
contains (CONFIG, LINK_QQT_SOURCE) {
#if you want to build src but not link QQt lib in your project
2017-11-26 09:47:57 +08:00
#if you don't want to modify Qt Creator's default build directory, this maybe a choice.
2017-11-07 10:33:42 +08:00
include($${QQT_SOURCE_ROOT}/src/qqt_source.pri)
} else {
2017-11-26 16:34:59 +08:00
#if you want to link QQt library
#qqt will install sdk to sdk path you set, then link it, or link from build station
#qqt also can install sdk to qt library path, then to do that.
2017-11-26 16:34:59 +08:00
#need QQT_BUILD_ROOT
#need QKIT_PRIVATE from qqt_qkit.pri
2017-11-26 16:34:59 +08:00
#you can open one or more macro to make sdk or link from build.
2017-11-26 21:58:59 +08:00
#link from sdk is default setting
CONFIG += link_from_sdk
#CONFIG += link_from_build
2017-11-26 16:34:59 +08:00
#especially some occations need some sure macro.
contains(QKIT_PRIVATE, iOS|iOSSimulator) {
2017-11-13 10:00:48 +08:00
#mac ios .framework .a 里面的快捷方式必须使用里面的相对路径,不能使用绝对路径
#但是qtcreator生成framework的时候用了绝对路径所以导致拷贝后链接失败库不可用。
#qqt_install.pri 里面解决了framework的拷贝问题但是对于ios里.a的没做而.a被拷贝了竟然也不能用
#在build的地方link就可以了
CONFIG += link_from_build
}
2017-11-07 10:33:42 +08:00
include($${QQT_SOURCE_ROOT}/src/qqt_library.pri)
}