[GLUE] Rsync SAMBA_3_0 SVN r25598 in order to create the v3-0-test branch.
[Samba.git] / source / lib / replace / system / readline.h
blob4a64ef13766a2be0457f90d34bdd2eece9c4f78b
1 #ifndef _system_readline_h
2 #define _system_readline_h
3 /*
4 Unix SMB/CIFS implementation.
6 readline wrappers
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 #ifdef HAVE_LIBREADLINE
24 # ifdef HAVE_READLINE_READLINE_H
25 # include <readline/readline.h>
26 # ifdef HAVE_READLINE_HISTORY_H
27 # include <readline/history.h>
28 # endif
29 # else
30 # ifdef HAVE_READLINE_H
31 # include <readline.h>
32 # ifdef HAVE_HISTORY_H
33 # include <history.h>
34 # endif
35 # else
36 # undef HAVE_LIBREADLINE
37 # endif
38 # endif
39 #endif
41 #ifdef HAVE_NEW_LIBREADLINE
42 # define RL_COMPLETION_CAST (rl_completion_func_t *)
43 #else
44 /* This type is missing from libreadline<4.0 (approximately) */
45 # define RL_COMPLETION_CAST
46 #endif /* HAVE_NEW_LIBREADLINE */
48 #endif