diff options
author | unknown <msvensson@pilot.(none)> | 2007-06-07 09:21:20 +0200 |
---|---|---|
committer | unknown <msvensson@pilot.(none)> | 2007-06-07 09:21:20 +0200 |
commit | fe8fdfcc156aa3865580fc8187dda0c9cf82aed1 (patch) | |
tree | 66e38bebf83e8471877f7e14dd72b63ec5ccdd51 | |
parent | befe04cd5c60212483c62c75c25eb6705cbf185f (diff) | |
parent | 1bf52d4735fded85e3412c1fff6f393c6fc50c36 (diff) | |
download | mariadb-git-fe8fdfcc156aa3865580fc8187dda0c9cf82aed1.tar.gz |
Merge pilot.(none):/data/msvensson/mysql/bug10218/my41-bug10218
into pilot.(none):/data/msvensson/mysql/mysql-4.1-maint
-rw-r--r-- | cmd-line-utils/libedit/el_term.h | 10 | ||||
-rw-r--r-- | configure.in | 13 |
2 files changed, 23 insertions, 0 deletions
diff --git a/cmd-line-utils/libedit/el_term.h b/cmd-line-utils/libedit/el_term.h index 9e5588ee96f..00ca48e38e2 100644 --- a/cmd-line-utils/libedit/el_term.h +++ b/cmd-line-utils/libedit/el_term.h @@ -90,6 +90,16 @@ extern char* tgoto(const char*, int, int); extern char* tgetstr(char*, char**); #endif + +#if !HAVE_DECL_TGOTO +/* + 'tgoto' is not declared in the system header files, this causes + problems on 64-bit systems. The function returns a 64 bit pointer + but caller see it as "int" and it's thus truncated to 32-bit +*/ +extern char* tgoto(const char*, int, int); +#endif + protected void term_move_to_line(EditLine *, int); protected void term_move_to_char(EditLine *, int); protected void term_clear_EOL(EditLine *, int); diff --git a/configure.in b/configure.in index b9f84086e28..dd3b449f9c8 100644 --- a/configure.in +++ b/configure.in @@ -1954,6 +1954,19 @@ else fi AC_SUBST(TERMCAP_LIB) +# Check if the termcap function 'tgoto' is already declared in +# system header files or if it need to be declared locally +AC_CHECK_DECLS(tgoto,,,[ +#ifdef HAVE_CURSES_H +# include <curses.h> +#elif HAVE_NCURSES_H +# include <ncurses.h> +#endif +#ifdef HAVE_TERM_H +# include <term.h> +#endif +]) + LIBEDIT_LOBJECTS="" AC_CHECK_FUNC(strunvis, ,[LIBEDIT_LOBJECTS="$LIBEDIT_LOBJECTS unvis.o"]) AC_CHECK_FUNC(strvis, ,[LIBEDIT_LOBJECTS="$LIBEDIT_LOBJECTS vis.o"]) |