Project ERROR: Unknown module(s) in QT: quick
-
Hi all,
i have compiled Qt5.1.1 with linaro toolchain.i compiled all the components/modules of Qt present in Qt5.1.1 including QtQuick1.Now after i do a qmake on qtdeclarative/tools/qmlscene i get this error "Project ERROR: Unknown module(s) in QT: quick".
I am also not able to Add Qt += quick in Qtcreator as its is giving error "Unknown module(s) in QT: quick" .All this is done on Ubuntu 12.04 LTS and Qtcreator 2.8.1.
Does anybody have any idea what iam doing wrong??Thanks in advance. -
The module name for QtQuick1 is "declarative", not "quick".
-
That's because QQuickView is from QtQuick2, not QtQuick1... you need to really decide what you want to use :D QQ1 equivalent is QDeclarativeView.
QtQuick1 (declarative) is provided for compatibility with Qt4. QtQuick2 (qml, quick modules) are the new shiny toys in introduced in Qt 5.
-
You need to include all those in .pro:
@
QT += core gui qml quick
@Then in C++ you need:
@
QQuickView; // or Window, etc. there are many ways to start the QML engine
@And in QML files you should be "including":http://qt-project.org/doc/qt-5.1/qtqml/qtqml-syntax-imports.html:
@
import QtQuick 2.0
@Also, see the "comparison":http://qt-project.org/wiki/QML1-vs-QML2.
-
Perhaps you've compiled Qt without it, or something went wrong during the compilation. See "this guide":http://qt-project.org/wiki/Building_Qt_5_from_Git.
-
Well, the fact that you are getting this error indicates quite clearly that it is not properly installed ;)
-
hey sierdzio during configure i got some errors but i was able to make && make install...After that i qmake rest of the QTModules successfully.But whenever i was doing qmake on qml scene i was getting Project ERROR: Unknown module(s) in QT: quick" error.So error in configure can be a issue even after it has successfully make && make install.
-
just for your information during configure i got these errors types
make: *** [pulseaudio.o] Error 1
compilation terminated.
make: *** [opengldesktop.o] Error 1opengles2.cpp:45:25: fatal error: GLES2/gl2.h: No such file or directory
#include <GLES2/gl2.h>
^
compilation terminated.
make: *** [opengles2.o] Error 1#include <ft2build.h>
^
compilation terminated.libudev.cpp:42:21: fatal error: libudev.h: No such file or directory
#include <libudev.h>
^
compilation terminated.
make: *** [libudev.o] Error 1
libudev disabled.
evdev auto-detection... ()
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -c -pipe -marm -mfpu=neon -mfloat-abi=hard -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o evdev.o evdev.cpp
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -Wl,-O1 -o evdev evdev.o
evdev enabled.
XLib auto-detection... ()
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -c -pipe -marm -mfpu=neon -mfloat-abi=hard -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o xlib.o xlib.cpp
xlib.cpp:42:22: fatal error: X11/Xlib.h: No such file or directory
#include <X11/Xlib.h>
^
compilation terminated.
make: *** [xlib.o] Error 1#include <xcb/xcb.h>
^
compilation terminated.
make: *** [xcb.o] Error 1
xcb disabled.
LinuxFB auto-detection... ()
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -c -pipe -marm -mfpu=neon -mfloat-abi=hard -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o linuxfb.o linuxfb.cpp
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -Wl,-O1 -o linuxfb linuxfb.o
LinuxFB enabled.
KMS auto-detection... ()
Project ERROR: Package libudev not found
make: *** No targets specified and no makefile found. Stop.openvg.cpp:48:23: fatal error: VG/openvg.h: No such file or directory
#include <VG/openvg.h>
^
compilation terminated.
make: *** [openvg.o] Error 1
OpenVG disabled.
OpenVG auto-detection... ()
/home/ubuntu/Raghaw/gcc-linaro-arm-linux-gnueabihf-4.8-2013.10_linux/bin/arm-linux-gnueabihf-g++ -c -pipe -marm -mfpu=neon -mfloat-abi=hard -O2 -Wall -W -fPIE -I../../../mkspecs/linux-arm-gnueabi-g++ -I. -o openvg.o openvg.cpp
openvg.cpp:48:23: fatal error: VG/openvg.h: No such file or directory
#include <VG/openvg.h>
^
compilation terminated.
make: *** [openvg.o] Error 1Build options:
Configuration .......... accessibility audio-backend c++11 clock-gettime clock-monotonic compile_examples concurrent cross_compile evdev eventfd freetype full-config getaddrinfo getifaddrs iconv inotify ipv6ifname large-config largefile linuxfb medium-config minimal-config mremap neon nis no-pkg-config pcre png precompile_header qpa qpa reduce_exports reduce_relocations release rpath shared small-config v8 v8snapshot zlib
Build parts ............ libs
Mode ................... release
Using C++11 ............ yes
Using PCH .............. yes
Target compiler supports:
iWMMXt/Neon .......... no/yesQt modules and options:
Qt D-Bus ............... no
Qt Concurrent .......... yes
Qt GUI ................. yes
Qt Widgets ............. yes
JavaScriptCore JIT ..... yes (To be decided by JavaScriptCore)
QML debugging .......... yes
Use system proxies ..... noSupport enabled for:
Accessibility .......... yes
ALSA ................... no
CUPS ................... no
FontConfig ............. no
Iconv .................. yes
ICU .................... no
Image formats:
GIF .................. yes (plugin, using system library)
JPEG ................. yes (plugin, using bundled copy)
PNG .................. yes (in QtGui, using bundled copy)
Glib ................... no
GStreamer .............. no
GTK theme .............. no
Large File ............. yes
libudev ................ no
Networking:
getaddrinfo .......... yes
getifaddrs ........... yes
IPv6 ifname .......... yes
OpenSSL .............. no
NIS .................... yes
OpenGL ................. no
OpenVG ................. no
PCRE ................... yes (bundled copy)
pkg-config ............. no
PulseAudio ............. no
QPA backends:
DirectFB ............. no
EGLFS ................ no
KMS .................. no
LinuxFB .............. yes
XCB .................. no
Session management ..... yes
SQL drivers:
DB2 .................. no
InterBase ............ no
MySQL ................ no
OCI .................. no
ODBC ................. no
PostgreSQL ........... no
SQLite 2 ............. no
SQLite ............... yes (plugin, using bundled copy)
TDS .................. no
udev ................... no
xkbcommon .............. no
zlib ................... yes (bundled copy)Qt is now configured for building. Just run 'make'.
Once everything is built, you must run 'make install'.
Qt will be installed into /usr/local/Qt-5.1.1Prior to reconfiguration, make sure you remove any leftovers from
the previous build.So does this is source of problem??But after this also i was able to make && make install.
-
Compile Qt with -opengl desktop. You don't have OpenGL ES 2 on your PC, and rightly so: if desktop OpenGL is available, it's better to use that.
Check out the compilation guide I have provided, it lists all dependencies and how to install them on Ubunutu.
-
Classes? In C++? Most of them are private and you can't officially access them. The ones blessed with being public are QQml* classes, and QQuickView, QQuickItem, QQuickPaintedItem.
No plugins are required here. if you compile Qt correctly, it will all be there by default.
-
I tried compiling with -opengl desktop flag but in the end i got this message
"You might need to modify the include and library search paths by editing
QMAKE_INCDIR_OPENGL, QMAKE_LIBDIR_OPENGL and QMAKE_LIBS_OPENGL in
/home/ubuntu/Raghaw/Qt5.1.1/qtbase/mkspecs/linux-arm-gnueabi-g++."What to do with these???
-
This has something to do with cross-compiling. I have somehow assumed you are compiling for the desktop, my bad. I don't know how to help you in this case, sorry.