forked from qt-creator/qt-creator
QmlDesigner: Improve Qt version check in plugins.pro
Reviewed-by: Thomas Hartmann
This commit is contained in:
@@ -31,6 +31,26 @@ defineReplace(qtLibraryName) {
|
||||
return($$RET)
|
||||
}
|
||||
|
||||
defineTest(minQtVersion) {
|
||||
maj = $$1
|
||||
min = $$2
|
||||
patch = $$3
|
||||
isEqual(QT_MAJOR_VERSION, $$maj) {
|
||||
isEqual(QT_MINOR_VERSION, $$min) {
|
||||
isEqual(QT_PATCH_VERSION, $$patch) {
|
||||
return(true)
|
||||
}
|
||||
greaterThan(QT_PATCH_VERSION, $$patch) {
|
||||
return(true)
|
||||
}
|
||||
}
|
||||
greaterThan(QT_MINOR_VERSION, $$min) {
|
||||
return(true)
|
||||
}
|
||||
}
|
||||
return(false)
|
||||
}
|
||||
|
||||
# For use in custom compilers which just copy files
|
||||
win32:i_flag = i
|
||||
defineReplace(stripSrcDir) {
|
||||
|
||||
@@ -38,20 +38,22 @@ SUBDIRS = plugin_coreplugin \
|
||||
plugin_tasklist \
|
||||
debugger/dumper.pro
|
||||
|
||||
contains(QT_CONFIG, declarative) {
|
||||
include(../../qtcreator.pri)
|
||||
|
||||
contains(QT_CONFIG, declarative) {
|
||||
SUBDIRS += \
|
||||
plugin_qmlprojectmanager \
|
||||
plugin_qmljsinspector
|
||||
|
||||
include(../private_headers.pri)
|
||||
exists($${QT_PRIVATE_HEADERS}/QtDeclarative/private/qdeclarativecontext_p.h) {
|
||||
isEqual(QT_MINOR_VERSION, 7):greaterThan(QT_PATCH_VERSION, 0) {
|
||||
|
||||
minQtVersion(4, 7, 1) {
|
||||
SUBDIRS += plugin_qmldesigner
|
||||
} else {
|
||||
warning()
|
||||
warning("QmlDesigner plugin has been disabled.")
|
||||
warning("Qt Version has to be 4.7.x with x > 0")
|
||||
warning("QmlDesigner requires Qt 4.7.1 or later.")
|
||||
}
|
||||
} else {
|
||||
warning()
|
||||
|
||||
Reference in New Issue
Block a user