几个月前,我将我的网络应用程序转换为Linux应用程序运行(有点,它只是在网络浏览器中,让人觉得它是一个完整的Linux应用程序)
我是在Ubuntu 14.04上制作的,现在我正在使用Elementary OS“Luna”。它预装了运行webkit的Midori Web浏览器。我也每天使用Chromium。
michael@michael-1619048:~/Documents/My_Sites/MMD/mmd-linux$ ./app.py
Traceback (most recent call last):
File "./app.py", line 3, in <module>
import webkit, gtk, os
ImportError: No module named webkit
michael@michael-1619048:~/Documents/My_Sites/MMD/mmd-linux$ sudo apt-get install webkit
[sudo] password for michael:
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package webkit
我安装了libwebkitgtk-dev
依赖项(也让我安装了一堆其他的,列在下面。
build-essential debhelper dh-apparmor dpkg-dev fakeroot g++ g++-4.6
gir1.2-atk-1.0 gir1.2-gdkpixbuf-2.0 gir1.2-javascriptcoregtk-1.0
gir1.2-webkit-1.0 html2text intltool-debian libalgorithm-diff-perl
libalgorithm-diff-xs-perl libalgorithm-merge-perl libatk1.0-0
libatk1.0-data libatk1.0-dev libcairo-script-interpreter2 libcairo2-dev
libdpkg-perl libexpat1-dev libfontconfig1-dev libfreetype6-dev
libgail-common libgail18 libgdk-pixbuf2.0-0 libgdk-pixbuf2.0-common
libgdk-pixbuf2.0-dev libglib2.0-0 libglib2.0-bin libglib2.0-dev libgtk2.0-0
libgtk2.0-dev libice-dev libjavascriptcoregtk-1.0-dev libmail-sendmail-perl
libpango1.0-dev libpcre3-dev libpcrecpp0 libpixman-1-0 libpixman-1-dev
libpng12-dev libpthread-stubs0 libpthread-stubs0-dev libsm-dev
libsoup2.4-dev libstdc++6-4.6-dev libsys-hostname-long-perl libx11-6
libx11-dev libx11-doc libxau-dev libxcb-render0-dev libxcb-shm0-dev
libxcb1-dev libxcomposite-dev libxcursor-dev libxdamage-dev libxdmcp-dev
libxext-dev libxfixes-dev libxfixes3 libxft-dev libxi-dev libxi6
libxinerama-dev libxml2 libxml2-dev libxml2-utils libxrandr-dev
libxrender-dev po-debconf x11proto-composite-dev x11proto-core-dev
x11proto-damage-dev x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev
x11proto-randr-dev x11proto-render-dev x11proto-xext-dev
x11proto-xinerama-dev xorg-sgml-doctools xtrans-dev zlib1g-dev
Suggested packages:
dh-make debian-keyring g++-multilib g++-4.6-multilib gcc-4.6-doc
libstdc++6-4.6-dbg libcairo2-doc libglib2.0-doc libgtk2.0-doc
libpango1.0-doc libsoup2.4-doc libstdc++6-4.6-doc libxcb-doc
libmail-box-perl
The following NEW packages will be installed:
build-essential debhelper dh-apparmor dpkg-dev fakeroot g++ g++-4.6
gir1.2-javascriptcoregtk-1.0 gir1.2-webkit-1.0 html2text intltool-debian
libalgorithm-diff-perl libalgorithm-diff-xs-perl libalgorithm-merge-perl
libatk1.0-dev libcairo-script-interpreter2 libcairo2-dev libdpkg-perl
libexpat1-dev libfontconfig1-dev libfreetype6-dev libgdk-pixbuf2.0-dev
libglib2.0-dev libgtk2.0-dev libice-dev libjavascriptcoregtk-1.0-dev
libmail-sendmail-perl libpango1.0-dev libpcre3-dev libpcrecpp0
libpixman-1-dev libpng12-dev libpthread-stubs0 libpthread-stubs0-dev
libsm-dev libsoup2.4-dev libstdc++6-4.6-dev libsys-hostname-long-perl
libwebkitgtk-dev libx11-dev libx11-doc libxau-dev libxcb-render0-dev
libxcb-shm0-dev libxcb1-dev libxcomposite-dev libxcursor-dev libxdamage-dev
libxdmcp-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev
libxml2-dev libxml2-utils libxrandr-dev libxrender-dev po-debconf
x11proto-composite-dev x11proto-core-dev x11proto-damage-dev
x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev
x11proto-render-dev x11proto-xext-dev x11proto-xinerama-dev
xorg-sgml-doctools xtrans-dev zlib1g-dev
The following packages will be upgraded:
gir1.2-atk-1.0 gir1.2-gdkpixbuf-2.0 libatk1.0-0 libatk1.0-data
libgail-common libgail18 libgdk-pixbuf2.0-0 libgdk-pixbuf2.0-common
libglib2.0-0 libglib2.0-bin libgtk2.0-0 libpixman-1-0 libx11-6 libxfixes3
libxi6 libxml2
答案 0 :(得分:3)
sudo apt-get install python-webkit python-webkit-dev
如果找不到包
,使用apt-cache search your_package
会很方便