问题
When a QML program (e.g. Ethereum, installed from the PPA in this case) tries to
import QtWebEngine 1.0
import QtWebEngine.experimental 1.0
Then I get these errors
file:////usr/share/mist/qml/views/browser.qml:5 module "QtWebEngine" is not installed
file:////usr/share/mist/qml/views/browser.qml:6 module "QtWebEngine.experimental" is not installed
QtWebEngine is in Qt 5.4 which is what I have installed
#> qmake --version
QMake version 3.0
Using Qt version 5.4.0 in /usr/lib/x86_64-linux-gnu
I tried to build QtWebEngine myself but no joy:
#> git clone git@gitorious.org:qt-labs/qtwebengine.git
Cloning into 'qtwebengine'...
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
1) Why isn't QtWebEngine installed if it's in Qt 5.4, which is installed?
2) Is there a way to install it other than building it myself?
3) What is wrong with the git clone
command?
Thanks for reading. I'm doing this on Ubuntu 14.10.
回答1:
This is specific to Ethereum and the ethereum-qt PPA, which was being upgraded from Qt 5.4.0 to 5.4.1, something that takes many hours to complete. Just apt-get update && apt-get upgrade
and everything should be fixed.
回答2:
I found that another cause of this 'module "Qt*" is not installed' class of problems on Ubuntu at least is the environment variable LD_LIBRARY_PATH
not being set. It should include the path to the lib directory of your Qt installation, e.g.
if [ "x$LD_LIBRARY_PATH" = "x" ]; then
export LD_LIBRARY_PATH=/home/username/Qt5.4.1/5.4/gcc_64/lib
else
export LD_LIBRARY_PATH=/home/username/Qt5.4.1/5.4/gcc_64/lib:$LD_LIBRARY_PATH
fi
来源:https://stackoverflow.com/questions/29088564/how-can-i-install-qtwebengine-on-ubuntu