Subject: Re: bin/30500
To: None <gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, paul@Plectere.com>
From: Valeriy E. Ushakov <uwe@ptc.spbu.ru>
List: netbsd-bugs
Date: 10/20/2006 00:05:04
The following reply was made to PR bin/30500; it has been noted by GNATS.

From: "Valeriy E. Ushakov" <uwe@ptc.spbu.ru>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: bin/30500
Date: Fri, 20 Oct 2006 04:00:24 +0400

 This fix seems to bite us back.
 
 Newer readline versions have readline/tilde.h that declares
 tilde_expand with the const argument.  4.3 has it const.  4.1 is NOT
 const.
 
 gdb53 ships with readline 4.1 (argument is NOT const), but apparently
 the gdb/gdb itself can be built with older readline 2.2 too, hence the
 NON const prototype in defs.h
 
 It seems though that we link in-tree gdb against in-tree libedit
 instead of readline shipped as part of gdb.
 
 Anyway, gdb6 assumes new readline, and some cli/cli*.c files include
 readline/tilde.h
 
 So when I try to bootstrap gdb6 according to instructions in
 README.mknative I get:
 
 In file included from /usr/src/tools/gdb/../../gnu/dist/gdb6/gdb/cli/cli-cmds.c:25:
 /usr/src/tools/gdb/../../gnu/dist/gdb6/gdb/../readline/../readline/tilde.h:68: error: conflicting types for 'tilde_expand'
 /usr/nb/distrib/hpcsh/usr/include/readline/readline.h:155: error: previous declaration of 'tilde_expand' was here
 
 [As a side note, I wonder how other ports get gdb6 bootstrapped, given
 this problem]
 
 
 Anyway, I thing the right fix is to change the prototype in the gdb53
 defs.h file and revert the prototype change committed as a fix for
 this pr.
 
 -uwe