summaryrefslogtreecommitdiff
path: root/lib/libedit/sys.h
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2010-06-30 00:05:36 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2010-06-30 00:05:36 +0000
commit4e317cd7d599f8bfe9b7906ba2f75a82e29a5f7a (patch)
tree7381b8c061e5ffffa2117ee119ec36681dde870f /lib/libedit/sys.h
parenta6429617a1d028ff60e599bcc583a0b56c844d85 (diff)
Update libedit to bring it into sync with the latest version from NetBSD.
ok deraadt
Diffstat (limited to 'lib/libedit/sys.h')
-rw-r--r--lib/libedit/sys.h27
1 files changed, 25 insertions, 2 deletions
diff --git a/lib/libedit/sys.h b/lib/libedit/sys.h
index 1335d61c12b..cb01859112a 100644
--- a/lib/libedit/sys.h
+++ b/lib/libedit/sys.h
@@ -1,5 +1,5 @@
-/* $OpenBSD: sys.h,v 1.8 2003/10/31 08:42:24 otto Exp $ */
-/* $NetBSD: sys.h,v 1.8 2003/08/07 16:44:33 agc Exp $ */
+/* $OpenBSD: sys.h,v 1.9 2010/06/30 00:05:35 nicm Exp $ */
+/* $NetBSD: sys.h,v 1.13 2009/12/30 22:37:40 christos Exp $ */
/*-
* Copyright (c) 1992, 1993
@@ -49,6 +49,16 @@
# define __attribute__(A)
#endif
+#ifndef __BEGIN_DECLS
+# ifdef __cplusplus
+# define __BEGIN_DECLS extern "C" {
+# define __END_DECLS }
+# else
+# define __BEGIN_DECLS
+# define __END_DECLS
+# endif
+#endif
+
#ifndef public
# define public /* Externally visible functions/variables */
#endif
@@ -62,6 +72,10 @@
/* When we want to hide everything */
#endif
+#ifndef __arraycount
+# define __arraycount(a) (sizeof(a) / sizeof(*(a)))
+#endif
+
#ifndef _PTR_T
# define _PTR_T
typedef void *ptr_t;
@@ -92,6 +106,15 @@ char *fgetln(FILE *fp, size_t *len);
#define REGEX /* Use POSIX.2 regular expression functions */
#undef REGEXP /* Use UNIX V8 regular expression functions */
+#if defined(__sun)
+extern int tgetent(char *, const char *);
+extern int tgetflag(char *);
+extern int tgetnum(char *);
+extern int tputs(const char *, int, int (*)(int));
+extern char* tgoto(const char*, int, int);
+extern char* tgetstr(char*, char**);
+#endif
+
#ifdef notdef
# undef REGEX
# undef REGEXP