Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Feb 2011 15:17:34 -0800
From:      Chip Camden <sterling@camdensoftware.com>
To:        questions@freebsd.org
Subject:   Re: problem when including readline.h
Message-ID:  <20110213231734.GH2807@libertas.local.camdensoftware.com>
In-Reply-To: <19800.24972.729085.774767@jerusalem.litteratus.org>
References:  <19800.23295.265146.528435@jerusalem.litteratus.org> <20110213223959.GF2807@libertas.local.camdensoftware.com> <19800.24972.729085.774767@jerusalem.litteratus.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--kHRd/tpU31Zn62xO
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Quoth Robert Huff on Sunday, 13 February 2011:
> Chip Camden writes:
>=20
> >  > 	I'm writing a C program which, for various reasons, has the
> >  > warning level turned _way_ up.
> >  > 	I'm now getting this:
> >  >=20
> >  > /usr/include/readline/readline.h:336: warning: redundant redeclarati=
on of 'rl_make_bare_keymap'
> >  > /usr/include/readline/keymaps.h:74: warning: previous declaration of=
 'rl_make_bare_keymap' was here
> >  >=20
> >  > 	and more like it.
> >  > 	Other than turning down the warning level, what's wrong and how
> >  > do I fix it?
> > =20
> >  Both keymaps.h and readline.h declare rl_make_bare_keymap as an extern=
al
> >  function.  Perhaps you shouldn't be including both files?
>=20
> 	Except I don't.  The include list:
>=20
> #include <sys/types.h>
> #include <ctype.h>
> #include <limits.h>
> #include <mysql/mysql.h>
> #include <stdio.h>
> #include <stdlib.h>
> #include <string.h>
> #include <strings.h>
> #include <sys/param.h>
> #include <unistd.h>
> #include <readline/readline.h>
> #include <readline/history.h>
>=20
> 	No second "keymap.h" visible.
>=20
>=20
> 				Robert Huff
>=20

Ah -- readline.h includes keymaps.h.  You're SOL.

--=20
Sterling (Chip) Camden | sterling@camdensoftware.com | 2048D/3A978E4F
http://chipsquips.com  | http://camdensoftware.com   | http://chipstips.com

--kHRd/tpU31Zn62xO
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (FreeBSD)

iQEcBAEBAgAGBQJNWGaOAAoJEIpckszW26+RxYUIALkY8RRjLrJUUft5nfC2IkY9
dUxi12oXrtOf8qBbIhQM+juGewon4eOVysbOfdDjDAB7X4xgpzBHZTZCoIqniMFP
6JqZ2S3yJi/2sAIzTHlIFLAvMRAt4j6o/XkL9GPZRT7I793I4T/PR4crTxySWkdY
W0qkkolsP9sDzJ6cO+cTFdfuFN/rlg1zrTxWrusDf0iixhk/+z6CTeXrcEP5GNug
3JDd4k6meZTMfDclPsWTv2JKm2sf+ougJdXWMnYHnF7YWJX2jlDrNYBqoNlF6sjx
ar6vzQY1LSriCkKSciH1VEXFg2d/6TsikAl9tFSKeWZSS0rW19RK5mOC8H/F7UA=
=us9i
-----END PGP SIGNATURE-----

--kHRd/tpU31Zn62xO--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110213231734.GH2807>