source navigator

 
source navigator
2007-04-25 16:17
http://www.cublog.cn/u/17532/showart_226007.html
By daiban ( daiban2@tom.com)
Note before reading this mini manual:
Kernel version: 2.6.17-13
gcc version: gcc-4.1.1
shell version: bash-3.1.7
If your tool-chains don't match, reference this manual at your own risk.
=====================================================

1 Download sourcenav-5.2b2.tar.gz from http://sourcenav.sourceforge.net.
2 [root@maya ~]# tar -zxvf sourcenav-5.2b2.tar.gz
Note: The following approach of making a new build directory instead of building
the system comes from INSTALL.TXT. Actually you don't need to make a new
building dir at all.
3 [root@maya ~]# mkdir ~/snbuild; cd ~/snbuild
4 [root@maya snbuild]# ../sourcenav-5.2b2/configure --prefix=/opt/sourcenav

As the same reason, the --prefix option is not needed at all, by default all binaries
are installed into /usr or /usr/local.
5 [root@maya snbuild]# There is a great chance that you encounter the following error report:
.......
checking for net/errno.h... no
checking for socket libraries... checking for connect... yes
checking for gethostbyname... yes
checking if 64bit support is requested... no
checking if 64bit Sparc VIS support is requested... no
checking system version (for dynamic loading)... ./configure: line 6046: syntax
error near unexpected token `)'
./configure: line 6046: `       OSF*)'
configure: error: ./configure failed for unix
configure: error: ./configure failed for tcl
However, if you don't encounter this error message, you are lucky, guy.
At this time, two configure files need to be modified:
6 [root@maya snbuild]# cd ../sourcenav-5.2b2/tcl/unix
7 [root@maya unix]# cp configure{,.orig} && sed "s/relid'/relid/" configure.orig > configure
8 [root@maya unix]# cd ../../tk/unix
9 [root@maya unix]# cp configure{,.orig} && sed "s/relid'/relid/" configure.orig > configure
Then reconfigure again.
10 [root@maya unix]# cd ../../../snbuild
11 [root@maya snbuild]# ../sourcenav-5.2b2/configure --prefix=/opt/sourcenav
That frastrating error message should not appear any more.
12 [root@maya snbuild]# make
After a long time compiling, another error message appears (note that I have
wrapped the long lines to fit the displa):
gcc -pipe -c -fwritable-strings -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1
-DUCHAR_SUPPORTED=1   -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1
-DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1
-DHAVE_PW_GECOS=1 -DSTATIC_BUILD=1   -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1
-DHAVE_GETCWD=1 -DHAVE_OPENDIR=1 -DHAVE_STRSTR=1 -DHAVE_STRTOL=1
-DHAVE_TMPNAM=1 -DHAVE_WAITPID=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_PARAM_H=1
-DUSE_TERMIOS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_TM_ZONE=1
-DHAVE_TM_GMTOFF=1 -DHAVE_TIMEZONE_VAR=1 -DHAVE_TIMEZONE_DECL=1
-DHAVE_ST_BLKSIZE=1 -DSTDC_HEADERS=1 -DNEED_MATHERR=1 -DRETSIGTYPE=void
-DHAVE_SIGNED_CHAR=1 -DHAVE_SYS_IOCTL_H=1 -DSTATIC_BUILD=1
-I/root/sourcenav-5.2b2/tcl/generic -I/root/sourcenav-5.2b2/tcl/unix -I/root/
sourcenav-5.2b2/tk/generic -I/root/sourcenav-5.2b2/tk/unix -I/root/sourcenav-5.2
b2/tix/generic -I/root/sourcenav-5.2b2/tix/unix   /root/sourcenav-5.2b2/tix/generic
/tixClass.c
cc1: error: unrecognized command line option "-fwritable-strings"
make[3]: *** [tixClass.o] Error 1
make[3]: Leaving directory `/root/snbuild2/tix/unix/tk8.3'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/root/snbuild2/tix/unix'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/root/snbuild2/tix'
make: *** [all] Error 1
I guess this is caused by gcc inability of handling backward compitability problems, but
I'm not sure. For now, we need to find-out all these command-line options in Make-
files and delete them, then re-run make:
13 [root@maya snbuild]# find . -name "Makefile"|xargs grep -n "fwritable-strings"
./tix/unix/tk8.3/Makefile:51:TIX_CFLAGS = $(CFLAGS) -fwritable-strings
./libgui/Makefile:74:LIBGUI_CFLAGS = -fwritable-strings
./libgui/src/Makefile:133:LIBGUI_CFLAGS = -fwritable-strings
./libgui/library/Makefile:73:LIBGUI_CFLAGS = -fwritable-strings
14 Follow the tips shown above and delete the -fwritable-strings option in all
     of the Makefiles
15 [root@maya snbuild]# make
At this time you should have no problems passing through the compiling process.
17 [root@maya snbuild]# change to root (Only if you are not yet)
18 [root@maya snbuild]# make install
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值