Subject: misc/1315: whatis.db is not a dbm file.
To: None <gnats-bugs@NetBSD.ORG>
From: None <jarle@idt.unit.no>
List: netbsd-bugs
Date: 08/04/1995 20:03:51
>Number:         1315
>Category:       misc
>Synopsis:       whatis.db is not a dbm file.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    misc-bug-people (Misc Bug People)
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Fri Aug  4 09:35:01 1995
>Last-Modified:
>Originator:     
>Organization:
a body of persons organized for some end of work
>Release:        1.0
>Environment:
	
System: NetBSD darling.idt.unit.no 1.0A NetBSD 1.0A (DARLING) #21: Fri Jul 21 09:08:59 MET DST 1995 jarle@darling.idt.unit.no:/usr/src/sys/arch/i386/compile/DARLING i386

>Description:
The makewhatis script stores its output in a file named whatis.db.  There
are two problems with this:
1) It is inconsistent with other parts of the system that uses the .db
   extension to state that this is a Berkeley DB-file,
   e.g. /etc/aliases.db, /etc/pwd.db, and /var/run/dev.db.
2) It causes problems when some of our (local) software builds real dbm
   whatis files.  NetBSD apropos and whatis attempt to open this file as a
   ordinary text file, and subsequently complain that the lines in this
   file are too long (no kidding!).
	
>How-To-Repeat:
	
>Fix:
I propose that the makewhatis script be modified to store its output in
files named whatis.txt instead of whatis.db.  Diffs below (I don't have any
strong opinions regarding this extension; feel free to change it to
something more suitable if you fancy.)  

						-jarle
-- 
"There's no shortage of incomprehensive text, just visit your local
 university bookstore."
				-- Anders Christensen
				   Documentation for the 'svada' program
================================================================
*** man.conf.orig	Fri Aug  4 19:35:44 1995
--- man.conf	Fri Aug  4 19:35:58 1995
***************
*** 5,9 ****
  
  # The whatis/apropos database.
! _whatdb		/usr/share/man/whatis.db
  
  # Subdirectories for paths ending in '/', IN SEARCH ORDER.
--- 5,9 ----
  
  # The whatis/apropos database.
! _whatdb		/usr/share/man/whatis.txt
  
  # Subdirectories for paths ending in '/', IN SEARCH ORDER.
*** pathnames.h.orig	Fri Aug  4 19:28:23 1995
--- pathnames.h	Fri Aug  4 19:28:34 1995
***************
*** 37,39 ****
  #define	_PATH_PAGER	"/usr/bin/more -s"
  #define	_PATH_TMP	"/tmp/man.XXXXXX"
! #define	_PATH_WHATIS	"whatis.db"
--- 37,39 ----
  #define	_PATH_PAGER	"/usr/bin/more -s"
  #define	_PATH_TMP	"/tmp/man.XXXXXX"
! #define	_PATH_WHATIS	"whatis.txt"
*** makewhatis.sh.orig	Fri Aug  4 19:27:44 1995
--- makewhatis.sh	Fri Aug  4 19:28:13 1995
***************
*** 30,33 ****
  sort -u -o /tmp/whatis$$ /tmp/whatis$$
  
! install -o bin -g bin -m 444 /tmp/whatis$$ "$MANDIR/whatis.db"
  exit 0
--- 30,33 ----
  sort -u -o /tmp/whatis$$ /tmp/whatis$$
  
! install -o bin -g bin -m 444 /tmp/whatis$$ "$MANDIR/whatis.txt"
  exit 0
>Audit-Trail:
>Unformatted: