Commit cb48aad9 authored by Kai Koehne's avatar Kai Koehne
Browse files

QmlDesigner: Improve Qt version check in plugins.pro

Reviewed-by: Thomas Hartmann
parent 8c956abe
...@@ -31,6 +31,26 @@ defineReplace(qtLibraryName) { ...@@ -31,6 +31,26 @@ defineReplace(qtLibraryName) {
return($$RET) 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 # For use in custom compilers which just copy files
win32:i_flag = i win32:i_flag = i
defineReplace(stripSrcDir) { defineReplace(stripSrcDir) {
......
...@@ -38,20 +38,22 @@ SUBDIRS = plugin_coreplugin \ ...@@ -38,20 +38,22 @@ SUBDIRS = plugin_coreplugin \
plugin_tasklist \ plugin_tasklist \
debugger/dumper.pro debugger/dumper.pro
contains(QT_CONFIG, declarative) { include(../../qtcreator.pri)
contains(QT_CONFIG, declarative) {
SUBDIRS += \ SUBDIRS += \
plugin_qmlprojectmanager \ plugin_qmlprojectmanager \
plugin_qmljsinspector plugin_qmljsinspector
include(../private_headers.pri) include(../private_headers.pri)
exists($${QT_PRIVATE_HEADERS}/QtDeclarative/private/qdeclarativecontext_p.h) { 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 SUBDIRS += plugin_qmldesigner
} else { } else {
warning() warning()
warning("QmlDesigner plugin has been disabled.") 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 { } else {
warning() warning()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment