sudo apt-get installkdelibs
sudo apt-get install xorg-dev (解決error:can't findX includes?)
sudo apt-get install kdelibs4-dev kdelibs4c2a (解決no KDE headersinstalled)
本 人在安裝這些庫的時候,也遇到了一些問題,安裝的時候出現了:0% [Waiting forheaders],然後就不動了。google了下,說是在apt-getinstall的過程中被中斷過(確實是這樣過),按照網上說的,把目錄下的/var/cache/apt/archives的一些文件刪除掉了,特別是/var/cache/apt/archives/partial目錄下的文件。
2.下載kscope-1.6.2
下載地址:http://download.chinaunix.net/download/0006000/5469.shtml
下載後,解壓縮,並進入到kscope-1.6.2的源碼根目錄中。
還可以在官網上下:
http://sourceforge.net/projects/kscope/files/kscope/
3.安裝:
A.配置.configure
用命令./configure --without-arts進行config
這個時候,會提示找不到這個,找不到那個,按照提示,將所需要的軟件包都 安裝上。列出幾個如下:
錯誤1: configure: error: C++ preprocessor "/lib/cpp" fails sanitycheck
解決方法:sudo apt-get install build-essential ,然後再./configure--without-arts
錯誤2: configure: error: Lex/Flex is required inorder to build KScope
解決方法:sudo apt-get install flex,然後再./configure --without-arts
錯誤3: configure: error: Yacc/Bison is required inorder to build KScope
解決方法:sudo apt-get install bison,然後再./configure --without-arts
安裝過程中,只記錄了這些錯誤,如果還出現其它錯誤,google下,一般都能找到。
在我安裝過程中報了:
1.checking for Qt... configure:error: Qt (>= Qt 3.3 and < 4.0)(headers and libraries) not found. Please check yourinstallation!
sudo apt-get installlibqt3-mt-dev
2.checking for KDE... configure:error:
in the prefix, you'vechosen, are no KDE headers installed. This willfail.
So, check this please anduse another prefix!
sudo apt-get installkdelibs4-dev
報錯後try:
sudo apt-get update
sudo apt-get installkdelibs4-dev
配置成功~
B.make
make時會出現的問題:
錯誤1: /usr/bin/ld: cannot find -lkateinterfaces
make時提示找不到-lkateinterfaces,不用擔心,該參數是要找動態鏈接庫,其實沒有動態鏈接庫,只有靜態鏈接庫,該庫位於/usr/lib/libkatepartinterfaces.la,這個時候,切換到src目錄下:
[ /home/lanch/Download/kscope-1.6.2]$cd src
[ /home/lanch/Download/kscope-1.6.2/src]$grep -n -lkateinterfacesMakefile(evisie注:這行命令並沒有起到實際作用,所以我直接在/src/Makefile文件中替換了-lkateinterfaces,查找方法和windows類似,Ctrl+F)
將Makefile文件中使用-lkateinterfaces的地方,替換爲/usr/lib/libkatepartinterfaces.la,接着,退回到上層目錄cd ..,進行make,就會大功告成。
C.sudo make install
4. 安裝cscope,ctags,graphviz
sudo apt-get install cscope ctags graphviz