Date: Mon, 14 Jul 2003 01:41:27 +0200 From: Simon Barner <barner@in.tum.de> To: Priit Piipuu <priit.piipuu@mail.ee> Cc: hackers@freebsd.org Subject: Re: libedit and g++ Message-ID: <20030713234127.GA537@zi025.glhnet.mhn.de> In-Reply-To: <20030714014658.GD5738@minerva.meskaliin.ee> References: <20030714014658.GD5738@minerva.meskaliin.ee>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --]
Hi,
> > cat test.c
> #include <stdio.h>
> #include <histedit.h>
>
It will link, when you wrap the include with an extern "C" statement:
extern "C" {
#include <histedit.h>
}
This should probably by handled by the library header itself, here is a
patch:
--- histedit.h.orig Mon Jul 14 01:37:43 2003
+++ histedit.h Mon Jul 14 01:38:33 2003
@@ -48,6 +48,10 @@
#include <sys/types.h>
#include <stdio.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*
* ==== Editing ====
*/
@@ -178,5 +182,9 @@
#define H_LOAD 14 /* , const char *); */
#define H_SAVE 15 /* , const char *); */
#define H_CLEAR 16 /* , void); */
+
+#ifdef __cplusplus
+}
+#endif
#endif /* _h_editline */
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (FreeBSD)
iD8DBQE/Ee4nCkn+/eutqCoRAlq2AJ9c/tEXybnLoVhrHNHcwOgKCHqQbQCfR1SC
QpsJa7o6oRdd9rZqXPwzjeo=
=WNZH
-----END PGP SIGNATURE-----
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030713234127.GA537>
