Chinaunix首页 | 论坛 | 博客
  • 博客访问: 122352
  • 博文数量: 31
  • 博客积分: 2551
  • 博客等级: 少校
  • 技术积分: 435
  • 用 户 组: 普通用户
  • 注册时间: 2007-12-18 15:52
文章分类

全部博文(31)

文章存档

2011年(5)

2010年(4)

2009年(12)

2008年(10)

我的朋友

分类: LINUX

2009-10-27 02:19:53

环境: opensuse 11.2 milestone8 + kde
今天发飙,要把stardict搞定才好。
下载了 stardict-3.0.1.tar.bz2
需要安装libsigc++2-devel

./configure --prefix=/usr/local/stardict --disable-gnome-support --disable-gucharmap --disable-festival --disable-espeak

make 出错:
g++ -DHAVE_CONFIG_H -I. -I../.. -I/usr/include/sigc++-2.0 -I/usr/lib64/sigc++-2.0/include   -Wall -pthread -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12       -g -O2 -MT data.o -MD -MP -MF .deps/data.Tpo -c -o data.o data.cpp                                                                        
data.cpp: In destructor ‘DictBase::~DictBase()’:                                                                            
data.cpp:40: error:  was not declared in this scope                                                                 
data.cpp: In member function ‘gchar* DictBase::GetWordData(guint32, guint32)’:                                              
data.cpp:50: error: ‘fseek’ was not declared in this scope                                                                  
data.cpp:57: error: ‘fread’ was not declared in this scope                                                                  
data.cpp:108: error: ‘strlen’ was not declared in this scope                                                                
data.cpp:109: error: ‘memcpy’ was not declared in this scope                           

google后
将出现报错的*.cpp统统添加
#include "stdio.h"
#include "stdlib.h"
#include "string.h"

然后又有报错
./../src/sigc++/signal.h:1675: error: declaration of ‘typedef struct sigc::slot_list > sigc::signal0::slot_list’
../../src/sigc++/signal.h:168: error: changes meaning of ‘slot_list’ from ‘struct sigc::slot_list >’
继续google,
这里列出的安装libsigc++2-devel是不适合的,因为已经安装好了。。。

在这里发现点端倪,说是gcc4.3的bug,但未在意;
直到看到http://blog.chinaunix.net/u2/68421/showart_1336049.html,才想起找里面的diff文件:
()
执行 patch -p1<474861.diff后,再编译通过;

make install 成功
然后在kmenu里面添加相关执行程序就好了~

(后记:装了opensuse的11.2正式版,stardict的安装就很顺溜了,gcc的版本应该有升级了)

阅读(1011) | 评论(0) | 转发(0) |
0

上一篇:下载天涯文章

下一篇:ssh

给主人留下些什么吧!~~