diff options
author | metalstrolch <stefan.wildemann@metalstrolche.de> | 2021-12-17 11:10:18 +0100 |
---|---|---|
committer | jkoan <jkoan@users.noreply.github.com> | 2021-12-17 13:19:36 +0100 |
commit | 6f52bb5aa557ef025859b636f8f6f971e1119d67 (patch) | |
tree | de8c1f62e2aa8c8ee9ce466855049e4cca1bf44f | |
parent | ed26d58ddcf7d48352cdd9f673f3e9096df0c905 (diff) | |
download | navit-6f52bb5aa557ef025859b636f8f6f971e1119d67.tar.gz |
Fix:graphics_qt5: allow building without qml again
-rwxr-xr-x | CMakeLists.txt | 6 | ||||
-rw-r--r-- | navit/graphics/qt5/graphics_qt5.cpp | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 947ee1410..3f6e98403 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -386,9 +386,11 @@ if (Qt5Widgets_FOUND OR Qt5Quick_FOUND) set_with_reason(USE_QML "Qt5Quick found" TRUE) if(USE_QML) set(Qt5_ADDITIONAL_LIBRARIES ${Qt5_ADDITIONAL_LIBRARIES} ${Qt5Quick_LIBRARIES}) + set_with_reason(gui/qt5_qml "Qt5 found" TRUE + ${Qt5Quick_LIBRARIES}) + else() + set_with_reason(gui/qt5_qml "feature USE_QML disabled for graphics/qt5" FALSE) endif() - set_with_reason(gui/qt5_qml "Qt5 found" TRUE - ${Qt5Quick_LIBRARIES}) endif() set_with_reason(graphics/qt5 "Qt5 found" TRUE diff --git a/navit/graphics/qt5/graphics_qt5.cpp b/navit/graphics/qt5/graphics_qt5.cpp index e2747ff78..7d157935e 100644 --- a/navit/graphics/qt5/graphics_qt5.cpp +++ b/navit/graphics/qt5/graphics_qt5.cpp @@ -753,10 +753,12 @@ static void* get_data(struct graphics_priv* this_priv, char const* type) { resize_callback(this_priv, this_priv->pixmap->width(), this_priv->pixmap->height()); return win; } +#if USE_QML if (strcmp(type, "engine") == 0) { dbg(lvl_debug, "Hand over QQmlApplicationEngine"); return (this_priv->engine); } +#endif return NULL; } |