您的位置:首页 > 运维架构 > Apache

lxr0.3安装方法(gentoo,apache2)

2011-06-20 20:04 357 查看
1、

安装
apache

服务器

2、 

解压缩
lxr0.3

3、 

编辑
lxr0.3 

目录下的
Makefile

文件修改

usr/bin/perl

是大多数情况下
perl

的默认路径

INSTALLPREFIX=/var/www/html/lxr  
(

安装路径,设置为
/var/www/localhost/htdocs/lxr)

4、            

修改
http

目录下的
lxr.conf

文件,将所有的
/local/lxr

改为
/var/www/localhost/htdocs/lxr

5

、修改
lxr.conf

文件中的
baseurl

http://localhost/lxr/http/
5、            

创建
$(INSTALLPREFIX)/http/.htaccess

文件内容如下
(


apache


cgi

方式执行
):

<Files
~ (search|source|ident|diff|find)$>

SetHandler cgi-script

</Files>

6、            


linux

源代码拷贝到
source

目录中并命名为
:linux-2.6.32

并在这个目录中执行
bin/genxref linux-2.6.32,

得到两个文件
fileidx


xref

,将两个文件权限设置为所有可读可写

7、            


lxr.conf

文件中的
sourceroot

设置为刚才
linux

源码的路径,别忘了最后加上
/

8、            


lxr.conf

中的
dbdir

设置为刚才的两个文件
fileidx,xref

的路径别忘了
/

9、            


apache

服务器的配置文件
httpd.conf

中(
/etc/apache2/httpd.conf

)中加入

<Directory
/var/www/html/lxr>

Options All

AllowOverride All

</Directory>

10


/etc/init.d/apache2 start

启动
apache

服务器

11

、访问
http://localhost/lxr/http/source

开始吧

 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息