1. install apache2sudoapt-getinstallapache22. install lxrsudoapt-getinstalllxr3. in/etc/apache2/httpd. add the following content to the end of conf: Alias/lxr/usr/share/lxr & lt; Directory/usr/share/lxr & gt; OptionsAllAllowOverrideAll & lt
1. Install apache2
Sudo apt-get install apache2
2. Install lxr
Sudo apt-get install lxr
3. Add the following content to the end of/etc/apache2/httpd. conf:
Alias/lxr/usr/share/lxr
Options All
AllowOverride All
In this way, [url] http: // localhost/lxr/[/url] =>/usr/share/lxr
4. Create the file. htaccess under/usr/share/lxr/http and write the following content:
SetHandler cgi -.
5.
Sudo/etc/init. d/apache2 restart
6. Create the/usr/share/lxr/source/XX directory (XX indicates the version number)
Mkdir/usr/share/lxr/source/2.6.22
Create a linux Symbolic connection under/usr/share/lxr/source/2.6.22
Ln-s/usr/src/linux-source-2.6.22/usr/share/lxr/source/2.6.22/linux
7. Create/usr/share/lxr/source/versions. All the versions to be viewed are recorded here. The content is
2.6.20
2.6.22
Ensure that 2.6.22 =>/usr/share/lxr/source/2.6.22
Create/usr/share/lxr/source/defversion. The default version is recorded here. The content is
2.6.22
For the two files, see the settings in/usr/share/lxr/http/lxr. conf.
8. Create an index
Cd/usr/share/lxr/source/2.6.22/
Sudo genxref 2.6.22 // This will generate fileidx and xref in the current directory
Sudo glimpseindex-H/usr/share/lxr/source/2.6.22 // usr/share/lxr/source/2.6.22/linux
(Wait for a while)
This directory (/usr/share/lxr/source/2.6.22/). For details, see the related settings in/usr/share/lxr/http/lxr. conf (database item)
8. modify attributes
Sudo chmod + r-R/usr/share/lxr/source/2.6.22 /*
9.
Sudo/etc/init. d/apache2 restart
Http: // localhost/lxr/http/blurb.html