madhi
2007-07-20
I have configured lxr 0.3 and glimpse 4.18 to index my source code under Linux (SLES 9) with root privileges. File search & identifier works fine.
The first problem is that I am not able to work with free text search. Free text shows “ , line –“ as the result.
The next problem I am not open the .h files
Plz help me in addressing this issue.
The configuration of my lxr conf goes like this
Configuration file.
# Define typed variable "v", read valueset from file.
variable: v, Version, [/local/lxr/source/version], [/local/lxr/source/defversion]
# Define typed variable "a". First value is default.
#variable: a, Architecture, (i386, alpha, m68k, mips, ppc, sparc, sparc64)
# Define the base url for the LXR files.
baseurl: http://localhost/src/source
# These are the templates for the HTML heading, directory listing and
# footer, respectively.
htmlhead: /usr/www/lxrnew/http/template-head
htmltail: /usr/www/lxrnew/http/template-tail
htmldir: /usr/www/lxrnew/http/template-dir
# The source is here.
sourceroot: /usr/www/src/
#sourceroot: /usr/www/src1/
srcrootname: Path:
# "#include <foo.h>" is mapped to this directory (in the LXR source
# tree)
incprefix: /include
# The database files go here.
dbdir: /usr/www/dbdir/
# Glimpse can be found here.
glimpsebin: /usr/www/dbdir/glimpse
# The power of regexps. This is pretty Linux-specific, but quite
# useful. Tinker with it and see what it does. (How's that for
# documentation?)
map: /include/asm[^\/]*/ /include/asm-$a/
map: /arch/[^\/]+/ /arch/$a/
Toshiharu Harada
2007-07-23
Hi,
> The first problem is that I am not able to work with free text search. Free text shows “ , line –“ as the result.
This is easy to solve.
1. CD to /usr/www/dbdir/2.6.22 (or other version).
2. run the command, "glimpse -H . linux".
3. the above command should return hundreds of lines if everything is fine. LXR's role is just making fancy output. So if you fix the command to run, LXR works fine. I recommend you to first check the command path and access permissions of .glimpse* files.
> The next problem I am not open the .h files
what's the output of ls -l /usr/www/src/?
With your "lxr.conf", LXR expects to sess /usr/www/src/2.6.21, 2.6.22...
Again, check the access permissions of files.
Good luck. :)
madhi
2007-07-26
Hi Toshiharu Harada ,
I am happy to receive a reply from you I could able to fix the ".h files" issue by your guidance.
I am sorry to say that, in the previous posting instead of typing free text search I typed as file search.
I could able to generate the glimpse and now also I am getting the same display
as “, line –“ when I invoke free text search.I also checked the file permission for glimpse.
But u have stated to use the option "glimpse -H . linux".
What is the difference in using glimpse and glimpseindex to build the glimpseDB?
when I invoke free text search(search file) i have noticed in the line no :61
unless (open(GLIMPSE, "-|")) {
/****Control not going here*********/
open(STDERR, ">&STDOUT");
$!='';
exec($Conf->glimpsebin,"-H".$Conf->dbdir,'-y','-n',$searchtext);
print("Glimpse subprocess died unexpextedly: $!\n");
exit;
Control is not going inside the unless loop.
Also not able to get where the binary glimpsebin is located, which is stated in exec command.
I have installed glimpse in /usr/local/glimpse.
This is the ls –l of usr/www/src
total 12736
drwxrwxrwx 3 root root 4096 2007-07-26 16:52 .
drwxrwxrwx 8 root root 4096 2007-07-26 14:19 ..
-rwxrwxrwx 1 root root 348160 2007-07-26 16:52 fileidx
-rwxrwxrwx 1 root root 1117619 2007-07-26 15:11 .glimpse_filenames
-rwxrwxrwx 1 root root 45756 2007-07-26 15:11 .glimpse_filenames_index
-rwxrwxrwx 1 root root 0 2007-07-26 15:10 .glimpse_filetimes
-rwxrwxrwx 1 root root 5606854 2007-07-26 15:11 .glimpse_index
-rwxrwxrwx 1 root root 51486 2007-07-26 15:11 .glimpse_messages
-rwxrwxrwx 1 root root 848 2007-07-26 15:11 .glimpse_partitions
-rwxrwxrwx 1 root root 24172 2007-07-26 15:11 .glimpse_statistics
drwxrwxrwx 7 stunnel users 4096 2007-07-17 07:36 linux
-rwxrwxrwx 1 root root 7061504 2007-07-26 16:52 xref
plz help me in resolving free text search.
Regards,
Madhi,
Toshiharu Harada
2007-07-26
Hi Madhi,
> I am happy to receive a reply from you I could able to fix the ".h files" issue by your guidance.
Just my pleasure. :)
> What is the difference in using glimpse and glimpseindex to build the glimpseDB?
Read the f?cking manual! :(
http://bases.colnodo.org.co/prensa/glimpseindex.html
It is glimpseindex that build the glimpseDB.
Glimpse is a command to do the search, not building index.
If you search "linux" with LXR, what LXR does is invoke the "glimpse -H . linux" and some decorations for ouput.
File permissions look good to me.
--
Toshiharu Harada
madhi
2007-07-26
Hi Toshiharu Harada ,
I am glad to see your quick response.
I am going through the (manual)link and also follwing up the procedure to create search.
If u find any quick updates ping me in this Thred.
Take care,be happy
Regards,
Madhi
Toshiharu Harada
2007-07-26
Madhi,
glad to see you again, too.
I'm monitoring this forum, so changes are sent via e-mail.
(I live in Japan)
I think you are very close to the goal.
So don't give up and keep trying.
May the Force be with you...
Cheers,
Toshiharu Harada
madhi
2007-07-26
hi Toshiharu Harada ,
sure .I live in India.I will also keep monitoring the forum.
be happy always
Regards,
Madhi
Toshiharu Harada
2007-07-26
According to your lxr.conf,
"/usr/www/dbdir/glimpse"
must resides and must be executable from within CGI.
There's one very simple yet powerfull debug method.
% cd /usr/www/dbdir
% mv glimpse glimpse-bin
% vi glimpse
% chmod a+x glimpse
You can put whatever you need to debug your LXR.
You might want to include the code to redirect
the result to a temp file.
If you follow this way, you'll soon get to know what is happening.
--
Toshiharu Harada
madhi
2007-08-01
hi Toshiharu Harada ,
I still breaking with this file search option.I am not able to follow the debug method u have specified."glimpse -H" gives nice output but when i invoke through search its not dsiplaying the result,simpy getting output as ", line -- "
here is my new configuration file which i use for indexing different versions.
# Configuration file.
# Define typed variable "v", read valueset from file.
variable: v, Version, [/usr/www/lxrnew/source/version], [/usr/www/lxrnew/source/defversion]
# Define typed variable "a". First value is default.
#variable: a, Architecture, (i386, alpha, m68k, mips, ppc, sparc, sparc64)
# Define the base url for the LXR files.
baseurl: http://localhost/src/source
# These are the templates for the HTML heading, directory listing and
# footer, respectively.
htmlhead: /usr/www/lxrnew/http/template-head
htmltail: /usr/www/lxrnew/http/template-tail
htmldir: /usr/www/lxrnew/http/template-dir
# The source is here.
sourceroot: /usr/www/lxrnew/source/$v/source/
srcrootname: Path:
# "#include <foo.h>" is mapped to this directory (in the LXR source tree)
incprefix: /include
# The database files go here.
dbdir: /usr/www/lxrnew/source/$v/
# Glimpse can be found here.
glimpsebin: /usr/local/glimpse/bin
# The power of regexps. This is pretty Linux-specific, but quite
# useful. Tinker with it and see what it does. (How's that for
# documentation?)
map: /include/asm[^\/]*/ /include/asm-$a/
map: /arch/[^\/]+/ /arch/$a/
my glimpse binaries in "/usr/local/glimpse/bin" contain files as :
linux:/usr/local/glimpse/bin # ls -l
total 1924
drwxrwxrwx 2 root root 4096 2007-07-31 17:58 .
drwxr-xr-x 4 root root 4096 2007-07-17 20:18 ..
-rwxrwxrwx 1 root root 189655 2007-07-17 20:18 agrep
-rwxrwxrwx 1 root root 302011 2007-07-17 20:18 buildcast
-rwxrwxrwx 1 root root 62976 2007-07-17 20:18 cast
-rwxrwxrwx 1 root root 357645 2007-07-17 20:18 glimpse
-rwxrwxrwx 1 root root 305239 2007-07-17 20:18 glimpseindex
-rwxrwxrwx 1 root root 357816 2007-07-17 20:18 glimpseserver
-rwxrwxrwx 1 root root 31772 2007-07-17 20:18 tbuild
-rwxrwxrwx 1 root root 62978 2007-07-17 20:18 uncast
-rwxrwxrwx 1 root root 238368 2007-07-17 20:18 wgconvert
Is there any path for free text search?
--
Madhi
Toshiharu Harada
2007-08-01
Ah huh!
> # Glimpse can be found here.
> glimpsebin: /usr/local/glimpse/bin
glimpsebin: /usr/local/glimpse/bin/glimpse
Try it!
--
Toshiharu Harada
madhi
2007-08-01
Hi Toshiharu,
I have tried with ur glimpsebin path[glimpsebin: /usr/local/glimpse/bin/glimpse].
but now i am getting ", line -- " printed twice.
--
Madhi
Toshiharu Harada
2007-08-01
Hum..., very weird.
Have you seen and tried http://sourceforge.net/forum/message.php?msg_id=4432898?
--
Toshiharu Harada
madhi
2007-08-01
hi Buddy good news.......,
The path "glimpsebin: /usr/local/glimpse/bin/glimpse" which u gave worked very well.At first sight i dint check it.Now it works for all versions which i have indexed.
Thanks Harada, for the help provided and relived me from the weired situation.
Take care.Be happy.......
Cheers,
Madhi.
Toshiharu Harada
2007-08-02
Good news, finally!
I believed you could make it, and you did it.
LXR is one of the greatest programs and I love it.
Enjoy!
--
Toshiharu Harada
madhi
2007-08-02
I too like this LXR which has reduced the burden of searching the repository.
be happy...
--
Madhi.
madhi
2007-08-07
hi,
I'm facing alignment problem in diff markup.
The two columns are mixing up.
How do i solve this.
Regards,
Madhi