tar zxf kchmviewer-.tar.gz > mkdir build > cd build > cmake .. > make > sudo make install For KDE version the installation is required, since the KHTML KIO slave cannot be used in place."/> kchmviewer-7.1安装错误的解决方法 – 海南仙岛

kchmviewer-7.1安装错误的解决方法

2014年11月15日

原创内容,转载请注明出处: http://www.myzhenai.com.cn/post/1925.html http://www.myzhenai.com/thread-16360-1-1.html
kchmviewer官方下载地址: http://sourceforge.net/projects/kchmviewer/files/kchmviewer/
kchmviewer依赖QT,所以在安装之前您必须先要安装QT,请参考官方安装包里的README文档.

3. INSTALLATION
  Usually kchmviewer is distributed in source code archive, so you need to compile it first. It requires Qt version 
  4.4 or higher. Note that you need to install qt4-devel and qt4-tools packages (the last one might be included in 
  qt4-devel in your distribution), not just qt package.
  Also make sure you have chmlib-devel (some distros have it as libchm-devel) package installed. KDE build will check 
  for its presence, but qmake does not have necessary functionality to do so. If you are getting errors regarding missing 
  chm_lib.h file this means chmlib-devel is not installed.
3.1. Qt-only version
  To compile Qt-only version of kchmviewer, follow the procedure:
  > tar zxf kchmviewer-<version>.tar.gz
  > cd kchmviewer-</version><version>
  > qmake
  > make
    The compiled binary is in bin/kchmviewer. You could copy it somewhere, or use it as-is. It does not require installation.
  If QtWebKit module is not found, you will get the following error:
  > kchmviewwindow_qtwebkit.h:25:21: error: QWebView: No such file or directory
  Either install QtWebKit module, or remove "webkit" from QT+= line in src/src.pro

3.2 KDE4 version
  To compile the version of kchmviewer with KDE4 support, follow the procedure:
  > tar zxf kchmviewer-</version><version>.tar.gz
  > mkdir build
  > cd build
  > cmake ..
  > make
  > sudo make install
  For KDE version the installation is required, since the KHTML KIO slave cannot be used in place.
</version>

安装方法如下:
# yum install libzip* chmlib -y
# wget http://softlayer-sng.dl.sourceforge.net/project/kchmviewer/kchmviewer/7.1/kchmviewer-7.1-1.i586.rpm
# rpm -ivh kchmviewer-7.1-1.i586.rpm
如果出现以下错误,请将您的libzip卸载再重新安装新版本.
error: Failed dependencies:
libzip.so.2 is needed by kchmviewer-7.1-1.i586
解决方法:
# yum remove libzip* -y
# wget ftp://ftp.muug.mb.ca/mirror/fedora/linux/development/rawhide/i386/os/Packages/l/libzip-0.11.2-3.fc22.i686.rpm
# rpm -ivh libzip-0.11.2-3.fc22.i686.rpm
# rpm -ivh kchmviewer-7.1-1.i586.rpm
如果您是升级kchmviewer-7.1的,升级前您必须要yum remove kchmviewer* -y 才能进行下一步操作.
Libzip:http://rpm.pbone.net/index.php3/stat/3/srodzaj/1/search/libzip.so.2

我前两天升级kchmviewer-7.1的时候就遇到一堆问题,因为我是使用Centos6.6的默认源进行安装的libzip,所以导致安装版本太低,解决方法很简单,yum remove libzip* -y 然后重新安装就可以了.我的安装日志如下.

[root@localhost RucLinux]# rpm -qa |grep qt
qt-sqlite-4.6.2-28.el6_5.i686
qtlockedfile-2.4-3.el6.leigh123linux.i686
qt3-devel-3.3.8b-30.el6.i686
qt47-4.7.2-1_18.el6.i686
qt47-devel-4.7.2-1_18.el6.i686
poppler-qt4-devel-0.12.4-3.el6_0.1.i686
qt47-x11-4.7.2-1_18.el6.i686
qt47-webkit-4.7.2-1_18.el6.i686
qt-4.6.2-28.el6_5.i686
libqtxdg-devel-0.5.2-13.el6.i686
dbus-qt-0.70-7.2.el6.i686
dbus-qt-devel-0.70-7.2.el6.i686
poppler-qt4-0.12.4-3.el6_0.1.i686
qtsingleapplication-2.6.1-5.el6.leigh123linux.i686
libqtxdg-0.5.2-13.el6.i686
qt47-designer-plugin-phonon-4.7.2-1_18.el6.i686
poppler-qt-devel-0.12.4-3.el6_0.1.i686
qt47-webkit-devel-4.7.2-1_18.el6.i686
poppler-qt-0.12.4-3.el6_0.1.i686
qt3-3.3.8b-30.el6.i686
zlibrary-ui-qt-0.12.10-5.el6.i686

[root@localhost RucLinux]# rpm -qa |grep libzip
libzip-0.9-3.1.el6.i686
libzip-devel-0.9-3.1.el6.i686

[root@localhost RucLinux]# rpm -qa |grep chmlib
chmlib-0.40-3.el6.i686
chmlib-devel-0.40-3.el6.i686

[root@localhost RucLinux]# ln -s /usr/bin/qmake-qt47 /etc/alternatives/qmake
[root@localhost RucLinux]# ls -l /etc/alternatives/qmake
lrwxrwxrwx. 1 root root 19 11月 10 03:06 /etc/alternatives/qmake -> /usr/bin/qmake-qt47

[root@localhost RucLinux]# wget http://softlayer-sng.dl.sourceforge.net/project/kchmviewer/kchmviewer/7.1/kchmviewer-7.1.tar.gz
[root@localhost RucLinux]# tar zxf kchmviewer-7.1.tar.gz
[root@localhost RucLinux]# cd kchmviewer-7.1
[root@localhost kchmviewer-7.1]# /usr/bin/qmake-qt47
[root@localhost kchmviewer-7.1]# make
cd lib/ && /usr/bin/qmake-qt47 /home/RucLinux/kchmviewer-7.1/lib/lib.pro -o Makefile
cd lib/ && make -f Makefile 
make[1]: Entering directory `/home/RucLinux/kchmviewer-7.1/lib'
cd libebook/ && /usr/bin/qmake-qt47 /home/RucLinux/kchmviewer-7.1/lib/libebook/libebook.pro -o Makefile
cd libebook/ && make -f Makefile 
make[2]: Entering directory `/home/RucLinux/kchmviewer-7.1/lib/libebook'
g++ -c -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables -fPIC -D_REENTRANT -Wall -W -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/lib/qt47/mkspecs/linux-g++ -I. -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include -I../../src -I. -o ebook_chm.o ebook_chm.cpp
g++ -c -pipe -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables -fPIC -D_REENTRANT -Wall -W -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/lib/qt47/mkspecs/linux-g++ -I. -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include -I../../src -I. -o ebook_epub.o ebook_epub.cpp
ebook_epub.cpp: In member function ‘virtual bool EBook_EPUB::load(const QString&)’:
ebook_epub.cpp:55: Error:‘zip_fdopen’In this role has not been declared in the domain
ebook_epub.cpp: In member function ‘bool EBook_EPUB::getFileAsBinary(QByteArray&, const QString&) const’:
ebook_epub.cpp:308: Error:‘struct zip_stat’Members are not called 'valid' in
ebook_epub.cpp:308: Error:‘ZIP_STAT_SIZE’In this role has not been declared in the domain
ebook_epub.cpp:308: Error:‘struct zip_stat’Members are not called 'valid' in
ebook_epub.cpp:308: Error:‘ZIP_STAT_INDEX’In this role has not been declared in the domain
make[2]: *** [ebook_epub.o] Error 1
make[2]: Leaving directory `/home/RucLinux/kchmviewer-7.1/lib/libebook'
make[1]: *** [sub-libebook-make_default] Error 2
make[1]: Leaving directory `/home/RucLinux/kchmviewer-7.1/lib'
make: *** [sub-lib-make_default] Error 2

[root@localhost RucLinux]# wget http://softlayer-sng.dl.sourceforge.net/project/kchmviewer/kchmviewer/7.1/kchmviewer-7.1-1.i586.rpm
[root@localhost RucLinux]# rpm -ivh kchmviewer-7.1-1.i586.rpm
error: Failed dependencies:
	libzip.so.2 is needed by kchmviewer-7.1-1.i586
[root@localhost RucLinux]# 
kchmviewer-7.1 安装 错误 解决 方法

kchmviewer-7.1安装错误的解决方法


sicnature ---------------------------------------------------------------------
Your current IP address is: 54.198.158.24
Your IP address location: 美国
Your IP address country and region: 美国 美国
Your current browser is:
Your current system is:
Original content, please indicate the source:
同福客栈论坛 | 海南仙岛海南乡情论坛 | JiaYu Blog
sicnature ---------------------------------------------------------------------
Welcome to reprint. Please indicate the source http://www.myzhenai.com.cn/post/1925.html

没有评论

发表评论

电子邮件地址不会被公开。 必填项已用*标注