Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
makewhatis dont do is job riht
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
EAD
Guru
Guru


Joined: 05 Jul 2006
Posts: 352

PostPosted: Wed Jul 19, 2006 5:28 pm    Post subject: makewhatis dont do is job riht Reply with quote

Hi, I have run makewhatis severl times, and it does something, but when comeing to use whatis or aprops like whatis gcc, it can't find a thing.
What can I do please?
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Wed Jul 19, 2006 5:50 pm    Post subject: Reply with quote

Moved from Installing Gentoo to Other Things Gentoo.
postinstallation problem, so moved here.
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
EAD
Guru
Guru


Joined: 05 Jul 2006
Posts: 352

PostPosted: Wed Jul 19, 2006 7:09 pm    Post subject: Reply with quote

Well? any one know what to do please?
Back to top
View user's profile Send private message
wynn
Advocate
Advocate


Joined: 01 Apr 2005
Posts: 2421
Location: UK

PostPosted: Wed Jul 19, 2006 7:29 pm    Post subject: Reply with quote

Code:
$ whatis whatis
whatis               (1)  - search the whatis database for complete words
$ apropos gcc
gccmakedep           (1x)  - create dependencies in makefiles using 'gcc -M'
This is what I get here.
Do you have /usr/share/man/whatis and /usr/local/man/whatis? These are the databases created by makewhatis ("man makewhatis" told me :) )
Back to top
View user's profile Send private message
EAD
Guru
Guru


Joined: 05 Jul 2006
Posts: 352

PostPosted: Wed Jul 19, 2006 9:10 pm    Post subject: Reply with quote

wynn wrote:
Code:
$ whatis whatis
whatis               (1)  - search the whatis database for complete words
$ apropos gcc
gccmakedep           (1x)  - create dependencies in makefiles using 'gcc -M'
This is what I get here.
Do you have /usr/share/man/whatis and /usr/local/man/whatis? These are the databases created by makewhatis ("man makewhatis" told me :) )


No, and I have the second one, but is empty
What to do please?
Back to top
View user's profile Send private message
yabbadabbadont
Advocate
Advocate


Joined: 14 Mar 2003
Posts: 4791
Location: 2 exits past crazy

PostPosted: Wed Jul 19, 2006 9:35 pm    Post subject: Reply with quote

Does running, "makewhatis -u", help?
_________________
Bones McCracker wrote:
On the other hand, regex is popular with the ladies.
Back to top
View user's profile Send private message
EAD
Guru
Guru


Joined: 05 Jul 2006
Posts: 352

PostPosted: Thu Jul 20, 2006 6:57 am    Post subject: Reply with quote

yabbadabbadont wrote:
Does running, "makewhatis -u", help?


No I have tried makewhatis -uv and so on
and nadda, any one?
Back to top
View user's profile Send private message
wynn
Advocate
Advocate


Joined: 01 Apr 2005
Posts: 2421
Location: UK

PostPosted: Thu Jul 20, 2006 9:07 am    Post subject: Reply with quote

Some local results:
Code:
# makewhatis --version
makewhatis from man-1.6b

Code:
# makewhatis -h
Usage: makewhatis [-u] [-v] [-w] [manpath] [-c [catpath]]
       This will build the whatis database for the man pages
       found in manpath and the cat pages found in catpath.
       -u: update database with new pages
       -v: verbose
       -w: use manpath obtained from `man --path`
       [manpath]: man directories (default: /usr/local/man:/usr/share/man)
       [catpath]: cat directories (default: the first existing
           directory in /usr/local/man:/usr/share/man)

The first should show whether your man pages and makewhatis, which is included in it, are up to date.

The second shows the value of MANPATH and CATPATH that it is using.

"makewhatis -u", as you can see, just looks for any pages newer that the existing whatis and adds them and is probably not going to be useful.

If you run "makewhatis -v" you should get something like
Code:
about to enter /usr/share/man
adding /usr/share/man/man1/./watch.1.gz
adding /usr/share/man/man1/./pod2text.1.gz
adding /usr/share/man/man1/./perlcc.1.gz
adding /usr/share/man/man1/./perlfunc.1.gz
adding /usr/share/man/man1/./cmp.1.gz
&c. &c.
I expect, however, that you don't.
As it is a shell script, /usr/sbin/makewhatis, you can get it to display every line as it is executed, which should show where the problem is. To do this you need to edit the file and add
Code:
set -x
just before the line
Code:
program=`basename $0`
Adding "-x" to the "#|/bin/sh" line doesn't seem to work.

The output here starts
Code:
+++ basename /usr/sbin/makewhatis
++ program=makewhatis
++ dm=
++ for d in /usr/local/man /usr/share/man
++ '[' -d /usr/local/man ']'
++ '[' x = x ']'
++ dm=/usr/local/man
Back to top
View user's profile Send private message
EAD
Guru
Guru


Joined: 05 Jul 2006
Posts: 352

PostPosted: Thu Jul 20, 2006 10:12 pm    Post subject: Reply with quote

Its weird, I have some things that aprops work, and other that don't for example aprops gcc give me one thing only, and it's not GCC :?
Back to top
View user's profile Send private message
gi1242
Tux's lil' helper
Tux's lil' helper


Joined: 29 Jul 2004
Posts: 146

PostPosted: Mon Dec 25, 2006 5:32 am    Post subject: Reply with quote

The problem here is a stupid bug in the makewhatis install script. The first few lines of /usr/sbin/makewhatis are
Code:
#
# Generated automatically from makewhatis.in by the
# configure script.
#
#!/bin/sh
# makewhatis: create the whatis database


The line #!/bin/sh should come FIRST!

Normally this will not be a problem if your shell is /bin/sh compatible (e.g. bash). But if you use tcsh, then you will get the above error messages. Make the first line
Code:
#!/bin/sh

and your problems should go away :).

GI
Back to top
View user's profile Send private message
gi1242
Tux's lil' helper
Tux's lil' helper


Joined: 29 Jul 2004
Posts: 146

PostPosted: Wed Dec 27, 2006 9:09 am    Post subject: Reply with quote

On digging a little more, it seems that there is a fundamental error the way the makewhatis cronjob is setup. See https://bugs.gentoo.org/show_bug.cgi?id=159192.

The problem can be temporarily fixed by running

makewhatis -v -w

as root

GI
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum